RFR: 8366897: RBTreeTest.IntrusiveCustomVerifyTest and RBTreeTest.CustomVerify tests fail on non-debug builds

Albert Mingkun Yang ayang at openjdk.org
Thu Sep 4 17:51:42 UTC 2025


On Thu, 4 Sep 2025 14:04:39 GMT, Casper Norrbin <cnorrbin at openjdk.org> wrote:

> #26981 introduced the possibility to supply the red-black tree with a custom verifier, however the call to this verifier was inside an assert, meaning it wasn't called for all builds. This results in two gtests failing.
> 
> This fix moves the call outside the assert, and then checks the result instead.
> 
> Testing:
> - Local gtest testing
> - Oracle tier 1

Since `extra_verifier` may have side-effect, it must be invoked outside the `assert` macro.

How about `assert(verifier(...` a few below? Does that require similar fixup?

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

Marked as reviewed by ayang (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/27097#pullrequestreview-3186433683


More information about the hotspot-dev mailing list