src/share/vm/opto/loopnode.cpp

changeset 9922
f7691a80458c
parent 9910
4373df7c4a92
child 9931
fd44df5e3bc3
child 9977
e649f2136368
equal deleted inserted replaced
9921:9cbafea410f5 9922:f7691a80458c
1 /* 1 /*
2 * Copyright (c) 1998, 2017, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 1998, 2020, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
1536 assert( phase->is_member( this, _head->in(2) ), "right edge is loop" ); 1536 assert( phase->is_member( this, _head->in(2) ), "right edge is loop" );
1537 1537
1538 // If I am a shared header (multiple backedges), peel off the many 1538 // If I am a shared header (multiple backedges), peel off the many
1539 // backedges into a private merge point and use the merge point as 1539 // backedges into a private merge point and use the merge point as
1540 // the one true backedge. 1540 // the one true backedge.
1541 if (_head->req() > 3 && !_irreducible) { 1541 if (_head->req() > 3) {
1542 // Merge the many backedges into a single backedge but leave 1542 // Merge the many backedges into a single backedge but leave
1543 // the hottest backedge as separate edge for the following peel. 1543 // the hottest backedge as separate edge for the following peel.
1544 merge_many_backedges( phase ); 1544 if (!_irreducible) {
1545 merge_many_backedges( phase );
1546 }
1547
1548 // When recursively beautify my children, split_fall_in can change
1549 // loop tree structure when I am an irreducible loop. Then the head
1550 // of my children has a req() not bigger than 3. Here we need to set
1551 // result to true to catch that case in order to tell the caller to
1552 // rebuild loop tree. See issue JDK-8244407 for details.
1545 result = true; 1553 result = true;
1546 } 1554 }
1547 1555
1548 // If I have one hot backedge, peel off myself loop. 1556 // If I have one hot backedge, peel off myself loop.
1549 // I better be the outermost loop. 1557 // I better be the outermost loop.

mercurial