RFR: 8348570: CTW: Expose the code hidden by uncommon traps

Aleksey Shipilev shade at openjdk.org
Fri Jan 24 11:21:22 UTC 2025


On Fri, 24 Jan 2025 11:15:33 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:

> We have been looking at some related compiler behaviors, and realized that in the absence of profiling data, C2 routinely uncommon-traps a lot of code that is presumed to be never executed. This apparently is a norm in CTW tests: CTW runners never execute code, and so only the most basic java.base classes are having any profile. This seems to limit the scope of CTW testing.
> 
> I think we need to run CTW in the mode that exposes more code to the compiler optimizations.
> 
> Case in point: [JDK-8348572](https://bugs.openjdk.org/browse/JDK-8348572), which reliably fails with more aggressive compilation mode. We cannot integrate this PR until that bug is fixed. But we can discuss if this makes sense, and/or we want some other options included to expand CTW testing.

Impact on testing times:


$ time CONF=linux-x86_64-server-fastdebug make images test TEST=applications/ctw/modules

# Before
real 4m49.393s
user 81m2.500s
sys  13m2.067s

# After (UNRELIABLE until JDK-8348572 is fixed)
real 4m44.288s
user 82m3.063s
sys  13m20.228s

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

PR Comment: https://git.openjdk.org/jdk/pull/23296#issuecomment-2612277958


More information about the hotspot-compiler-dev mailing list