RFR: 8339299: C1 will miss type profile when inline final method [v5]

Leonid Mesnik lmesnik at openjdk.org
Mon Sep 16 15:14:08 UTC 2024


On Tue, 10 Sep 2024 08:35:25 GMT, kuaiwei <duke at openjdk.org> wrote:

>> I found sometimes C1 will miss type profile and I tried to write a test to demonstrate it.
>> It will happen with these conditions
>> 1 It's a virtual call and the callee is a final method. So c1 will think it's static bound.
>> 2 The interpreter never touch the callsite, so interpreter does not add type profile.
>> 3 In c1 compilation, it will be inlined based on CHA.
>> 4 In c2 compilation, the CHA is broken, but type profile is missing, so c2 can not inline it.
>
> kuaiwei has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Modify test case to use createTestJavaProcessBuilder

Tes looks good.

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

Marked as reviewed by lmesnik (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/20786#pullrequestreview-2306965681


More information about the hotspot-compiler-dev mailing list