RFR: 8144484: assert(no_dead_loop) failed: dead loop detected
Vladimir Kozlov
vladimir.kozlov at oracle.com
Wed Feb 1 08:19:48 UTC 2017
Sorry, I don't like this fix.
Based on your evaluation one control path is dead (top) and it will be optimized out later. It was unfortunate that Phi
node was processed first. Change graph (split through MergeMem) is dangerous in this state of graph.
I would suggest to bailout early:
1886 if (progress == NULL && can_reshape && type() == Type::MEMORY) {
1887 // see if this phi should be sliced
1888 uint merge_width = 0;
1889 bool saw_self = false;
1890 for( uint i=1; i<req(); ++i ) {// For all paths in
1891 Node *ii = in(i);
+ // TOP inputs should not be counted as safe inputs because if the
+ // Phi references itself through all other inputs then splitting the
+ // Phi through memory merges would create dead loop at later stage.
+ if (ii == top) {
+ return top; // Delay optimization until graph is cleaned.
+ }
1892 if (ii->is_MergeMem()) {
1893 MergeMemNode* n = ii->as_MergeMem();
Thanks,
Vladimir
On 1/31/17 11:38 PM, Tobias Hartmann wrote:
> Hi Rahul,
>
> On 31.01.2017 19:55, Rahul Raghavan wrote:
>> Please see updated <webrev.01> -
>> http://cr.openjdk.java.net/~rraghavan/8144484/webrev.01/
>
> Looks good to me!
>
> Best regards,
> Tobias
>
More information about the hotspot-compiler-dev
mailing list