src/share/vm/opto/matcher.cpp

changeset 9725
34799214056c
parent 9513
e044997c2eda
child 9756
2be326848943
equal deleted inserted replaced
9724:bfff0a0ccb0e 9725:34799214056c
2041 } 2041 }
2042 if (is_visited(n)) { // Visited already? 2042 if (is_visited(n)) { // Visited already?
2043 // Node is shared and has no reason to clone. Flag it as shared. 2043 // Node is shared and has no reason to clone. Flag it as shared.
2044 // This causes it to match into a register for the sharing. 2044 // This causes it to match into a register for the sharing.
2045 set_shared(n); // Flag as shared and 2045 set_shared(n); // Flag as shared and
2046 if (n->is_DecodeNarrowPtr()) {
2047 // Oop field/array element loads must be shared but since
2048 // they are shared through a DecodeN they may appear to have
2049 // a single use so force sharing here.
2050 set_shared(n->in(1));
2051 }
2046 mstack.pop(); // remove node from stack 2052 mstack.pop(); // remove node from stack
2047 continue; 2053 continue;
2048 } 2054 }
2049 nstate = Visit; // Not already visited; so visit now 2055 nstate = Visit; // Not already visited; so visit now
2050 } 2056 }
2163 if( _must_clone[mop] ) { 2169 if( _must_clone[mop] ) {
2164 mstack.push(m, Visit); 2170 mstack.push(m, Visit);
2165 continue; // for(int i = ...) 2171 continue; // for(int i = ...)
2166 } 2172 }
2167 2173
2168 if( mop == Op_AddP && m->in(AddPNode::Base)->is_DecodeNarrowPtr()) {
2169 // Bases used in addresses must be shared but since
2170 // they are shared through a DecodeN they may appear
2171 // to have a single use so force sharing here.
2172 set_shared(m->in(AddPNode::Base)->in(1));
2173 }
2174
2175 // if 'n' and 'm' are part of a graph for BMI instruction, clone this node. 2174 // if 'n' and 'm' are part of a graph for BMI instruction, clone this node.
2176 #ifdef X86 2175 #ifdef X86
2177 if (UseBMI1Instructions && is_bmi_pattern(n, m)) { 2176 if (UseBMI1Instructions && is_bmi_pattern(n, m)) {
2178 mstack.push(m, Visit); 2177 mstack.push(m, Visit);
2179 continue; 2178 continue;

mercurial