RFR: 8303627: compiler/loopopts/TestUnreachableInnerLoop.java failed with -XX:LoopMaxUnroll=4
Vladimir Kozlov
kvn at openjdk.org
Mon Mar 6 20:41:12 UTC 2023
On Mon, 6 Mar 2023 02:42:21 GMT, SUN Guoyun <duke at openjdk.org> wrote:
> This test failed with VM_OPTIONS=-XX:LoopMaxUnroll=4 and CONF=fastdebug on X86_64, AArch64 LoongArch64 architecture.
>
> <pre><code class="shell">
> # A fatal error has been detected by the Java Runtime Environment:
> #
> # Internal Error (/home/sunguoyun/jdk-ls/src/hotspot/share/opto/block.cpp:1359), pid=31328, tid=31344
> # assert(n->is_Root() || n->is_Region() || n->is_Phi() || n->is_MachMerge() || def_block->dominates(block)) failed: uses must be dominated by definitions
> #
> </code></pre>
> This PR fix the issue, Please help review it.
>
> Thanks.
src/hotspot/share/opto/block.hpp line 195:
> 193: if (dom_diff > 0) return false;
> 194: for (; dom_diff < 0; dom_diff++) that = that->_idom;
> 195: return (this == that) || (this != that && this->_dom_depth == that->_dom_depth);
I don't think this is correct. `this` should be reachable from `that` for this method return `true`.
Imaging you compare `B53->dominates(B61)` from your example.
-------------
PR: https://git.openjdk.org/jdk/pull/12874
More information about the hotspot-compiler-dev
mailing list