RFR: 8271471: [IR Framework] Rare occurrence of "<!-- safepoint while printing -->" in PrintIdeal/PrintOptoAssembly can let tests fail [v4]

Christian Hagedorn chagedorn at openjdk.java.net
Tue Aug 10 12:04:56 UTC 2021


On Tue, 10 Aug 2021 11:31:06 GMT, Tobias Hartmann <thartmann at openjdk.org> wrote:

> Looks good to me. I'm just wondering if we need all that `notAllBailedOut`/`noneBailedOut` complexity for handling scenarios. 

I think we need the `notAllBailedOut()` function to verify that there was not a scenario without a bailout (i.e. missed to throw an exception). The code of `notAllBailedOut()` could be simplified to use `anyMatch` instead.

> Given that safepoints during printing are rare, couldn't we simply skip verification of the exception message if one scenario hit a bailout?

Yes, that's probably easier. We can also first check if the expected message was even mismatched in `TestScenarios` before actually doing the `tty` message check. I changed that by turning `noneBailedOut` into `anyBailedOut` which uses `anyMatch`.

But yes, I agree that it's some complexity for a rather rare case. I pushed an updated with these changes.

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

PR: https://git.openjdk.java.net/jdk/pull/4932


More information about the hotspot-compiler-dev mailing list