8059455: LambdaForm.prepare() does unnecessary work for cached LambdaForms
Reviewed-by: psandoz
This commit is contained in:
parent
476d962701
commit
7840b0e7c1
@ -631,7 +631,7 @@ class LambdaForm {
|
||||
* as a sort of pre-invocation linkage step.)
|
||||
*/
|
||||
public void prepare() {
|
||||
if (COMPILE_THRESHOLD == 0) {
|
||||
if (COMPILE_THRESHOLD == 0 && !isCompiled) {
|
||||
compileToBytecode();
|
||||
}
|
||||
if (this.vmentry != null) {
|
||||
@ -645,11 +645,11 @@ class LambdaForm {
|
||||
|
||||
/** Generate optimizable bytecode for this form. */
|
||||
MemberName compileToBytecode() {
|
||||
MethodType invokerType = methodType();
|
||||
assert(vmentry == null || vmentry.getMethodType().basicType().equals(invokerType));
|
||||
if (vmentry != null && isCompiled) {
|
||||
return vmentry; // already compiled somehow
|
||||
}
|
||||
MethodType invokerType = methodType();
|
||||
assert(vmentry == null || vmentry.getMethodType().basicType().equals(invokerType));
|
||||
try {
|
||||
vmentry = InvokerBytecodeGenerator.generateCustomizedCode(this, invokerType);
|
||||
if (TRACE_INTERPRETER)
|
||||
|
Loading…
Reference in New Issue
Block a user