RFR: 8330157: C2: Add a stress flag for bailouts [v7]
Daniel Skantz
duke at openjdk.org
Mon Jul 1 10:08:23 UTC 2024
On Mon, 1 Jul 2024 07:04:25 GMT, Emanuel Peter <epeter at openjdk.org> wrote:
>> test/hotspot/jtreg/testlibrary/ctw/src/sun/hotspot/tools/ctw/CtwRunner.java line 307:
>>
>>> 305: "-XX:+StressIncrementalInlining",
>>> 306: "-XX:+StressBailout",
>>> 307: "-XX:StressBailoutProbability=100_000_000",
>>
>> This value allows us to compile any given method with high probability.
>> The largest number of `failing()` checks that I have seen so far is 10**6.
>>
>> I am not sure if this could hide an infinite compilation due to an unrelated bug.
>> If we want to guard against edge cases, we could do an additional check against
>> the stress seed, for example disabling this stress mode if `!(_stress_seed % 10)`.
>
> Or you somehow randomly enable/disable the `StressBailout` flag? Stuffing too much special-logic into the internals could be quite confusing for the flag-user.
We can do that perhaps in `initialize_stress_seed` and rename the method, but the `StressBailoutMean` interface could still become less intuitive.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/19646#discussion_r1660801626
More information about the hotspot-compiler-dev
mailing list