RFR: 8320237 C2: late inlining of method handle invoke causes duplicate lines in PrintInlining output [v2]

Tobias Hartmann thartmann at openjdk.org
Tue Jan 16 16:24:22 UTC 2024


On Wed, 10 Jan 2024 16:37:44 GMT, Kangcheng Xu <kxu at openjdk.org> wrote:

>> This PR resolves [JDK-8320237](https://bugs.openjdk.org/browse/JDK-8320237)
>> 
>> The original behavior produces both a failure and success message upon late inlining which is confusing. The patch removes the failure message if inlining was successful. Huge thanks to @rwestrel for reporting and working out a solution.
>> 
>> Unit test `test/hotspot/jtreg/compiler/inlining/TestDuplicatedLateInliningOutput.java` is added and passing.
>
> Kangcheng Xu has updated the pull request incrementally with one additional commit since the last revision:
> 
>   fix VM crashes

Thanks for the explanation. `compiler/inlining/TestDuplicatedLateInliningOutput.java` still failed once with `-XX:+UseZGC -XX:+ZGenerational`:

java.lang.Exception: No inlining found
	at compiler.inlining.TestDuplicatedLateInliningOutput.lambda$test$1(TestDuplicatedLateInliningOutput.java:77)
	at java.base/java.util.OptionalInt.orElseThrow(OptionalInt.java:273)
	at compiler.inlining.TestDuplicatedLateInliningOutput.test(TestDuplicatedLateInliningOutput.java:77)
	at compiler.inlining.TestDuplicatedLateInliningOutput.main(TestDuplicatedLateInliningOutput.java:46)
	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
	at java.base/java.lang.reflect.Method.invoke(Method.java:580)
	at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:333)
	at java.base/java.lang.Thread.run(Thread.java:1575)

-------------

PR Comment: https://git.openjdk.org/jdk/pull/17147#issuecomment-1894076148


More information about the hotspot-compiler-dev mailing list