RFR: 8339299: C1 will miss type profile when inline final method
kuaiwei
duke at openjdk.org
Fri Aug 30 07:31:51 UTC 2024
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.
-------------
Commit messages:
- 8339299: C1 will miss type profile when inline final method
Changes: https://git.openjdk.org/jdk/pull/20786/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=20786&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8339299
Stats: 149 lines in 3 files changed: 147 ins; 0 del; 2 mod
Patch: https://git.openjdk.org/jdk/pull/20786.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/20786/head:pull/20786
PR: https://git.openjdk.org/jdk/pull/20786
More information about the hotspot-compiler-dev
mailing list