8285633: Take better advantage of generic MethodType cache

Reviewed-by: jvernee
This commit is contained in:
Claes Redestad 2022-04-27 17:54:21 +00:00
parent 5b42747ba1
commit 6c79671e50
8 changed files with 118 additions and 23 deletions

View file

@ -323,7 +323,7 @@ abstract class MethodHandleImpl {
for (int pos : positions) {
ptypes[pos - 1] = newType;
}
midType = MethodType.makeImpl(midType.rtype(), ptypes, true);
midType = MethodType.methodType(midType.rtype(), ptypes, true);
}
LambdaForm form2;
if (positions.length > 1) {