Mercurial > hg > truffle
comparison src/share/vm/opto/matcher.cpp @ 309:eaf496ad4a14
6732698: crash with dead code from compressed oops in gcm
Reviewed-by: rasbold
author | never |
---|---|
date | Thu, 28 Aug 2008 23:03:55 -0700 |
parents | 9c2ecc2ffb12 |
children | 194b8e3a2fc4 |
comparison
equal
deleted
inserted
replaced
308:756b58154237 | 309:eaf496ad4a14 |
---|---|
1448 mach->_opnds[0] = s->MachOperGenerator( _reduceOp[rule], C ); | 1448 mach->_opnds[0] = s->MachOperGenerator( _reduceOp[rule], C ); |
1449 assert( mach->_opnds[0] != NULL, "Missing result operand" ); | 1449 assert( mach->_opnds[0] != NULL, "Missing result operand" ); |
1450 Node *leaf = s->_leaf; | 1450 Node *leaf = s->_leaf; |
1451 // Check for instruction or instruction chain rule | 1451 // Check for instruction or instruction chain rule |
1452 if( rule >= _END_INST_CHAIN_RULE || rule < _BEGIN_INST_CHAIN_RULE ) { | 1452 if( rule >= _END_INST_CHAIN_RULE || rule < _BEGIN_INST_CHAIN_RULE ) { |
1453 assert(C->node_arena()->contains(s->_leaf) || !has_new_node(s->_leaf), | |
1454 "duplicating node that's already been matched"); | |
1453 // Instruction | 1455 // Instruction |
1454 mach->add_req( leaf->in(0) ); // Set initial control | 1456 mach->add_req( leaf->in(0) ); // Set initial control |
1455 // Reduce interior of complex instruction | 1457 // Reduce interior of complex instruction |
1456 ReduceInst_Interior( s, rule, mem, mach, 1 ); | 1458 ReduceInst_Interior( s, rule, mem, mach, 1 ); |
1457 } else { | 1459 } else { |
1870 continue; // for(int i = ...) | 1872 continue; // for(int i = ...) |
1871 } | 1873 } |
1872 | 1874 |
1873 // Clone addressing expressions as they are "free" in most instructions | 1875 // Clone addressing expressions as they are "free" in most instructions |
1874 if( mem_op && i == MemNode::Address && mop == Op_AddP ) { | 1876 if( mem_op && i == MemNode::Address && mop == Op_AddP ) { |
1877 if (m->in(AddPNode::Base)->Opcode() == Op_DecodeN) { | |
1878 // Bases used in addresses must be shared but since | |
1879 // they are shared through a DecodeN they may appear | |
1880 // to have a single use so force sharing here. | |
1881 set_shared(m->in(AddPNode::Base)->in(1)); | |
1882 } | |
1875 Node *off = m->in(AddPNode::Offset); | 1883 Node *off = m->in(AddPNode::Offset); |
1876 if( off->is_Con() ) { | 1884 if( off->is_Con() ) { |
1877 set_visited(m); // Flag as visited now | 1885 set_visited(m); // Flag as visited now |
1878 Node *adr = m->in(AddPNode::Address); | 1886 Node *adr = m->in(AddPNode::Address); |
1879 | 1887 |