@@ -371,14 +371,6 @@ static LambdaForm create(int arity, Name[] names, boolean forceInline, Kind kind
371
371
return create (arity , names , DEFAULT_RESULT , forceInline , DEFAULT_CUSTOMIZED , kind );
372
372
}
373
373
374
- private static LambdaForm createBlankForType (MethodType mt ) {
375
- // Make a dummy blank lambda form.
376
- // It is used as a template for managing the invocation of similar forms that are non-empty.
377
- // Called only from getPreparedForm.
378
- LambdaForm form = new LambdaForm (0 , 0 , DEFAULT_FORCE_INLINE , DEFAULT_CUSTOMIZED , new Name [0 ], Kind .GENERIC );
379
- return form ;
380
- }
381
-
382
374
private static int fixResult (int result , Name [] names ) {
383
375
if (result == LAST_RESULT )
384
376
result = names .length - 1 ; // might still be void
@@ -785,14 +777,15 @@ public void prepare() {
785
777
return ;
786
778
}
787
779
MethodType mtype = methodType ();
788
- LambdaForm prep = mtype .form ().cachedLambdaForm (MethodTypeForm .LF_INTERPRET );
789
- if (prep == null ) {
780
+ MethodTypeForm form = mtype .form ();
781
+
782
+ MemberName entry = form .cachedInterpretEntry ();
783
+ if (entry == null ) {
790
784
assert (isValidSignature (basicTypeSignature ()));
791
- prep = LambdaForm .createBlankForType (mtype );
792
- prep .vmentry = InvokerBytecodeGenerator .generateLambdaFormInterpreterEntryPoint (mtype );
793
- prep = mtype .form ().setCachedLambdaForm (MethodTypeForm .LF_INTERPRET , prep );
785
+ entry = InvokerBytecodeGenerator .generateLambdaFormInterpreterEntryPoint (mtype );
786
+ entry = form .setCachedInterpretEntry (entry );
794
787
}
795
- this .vmentry = prep . vmentry ;
788
+ this .vmentry = entry ;
796
789
// TO DO: Maybe add invokeGeneric, invokeWithArguments
797
790
}
798
791
0 commit comments