src/share/vm/opto/output.cpp
Index
Unified diffs
Context diffs
Sdiffs
Wdiffs
Patch
New
Old
Previous File
Next File
*** old/src/share/vm/opto/output.cpp Tue Jul 26 19:27:02 2011
--- new/src/share/vm/opto/output.cpp Tue Jul 26 19:27:01 2011
*** 393,403 ****
--- 393,403 ----
}
}
}
min_offset_from_last_call += inst_size;
// Remember end of call offset
! if (nj->is_MachCall() && nj->as_MachCall()->is_safepoint_node()) {
! if (nj->is_MachCall() && !nj->is_MachCallLeaf()) {
min_offset_from_last_call = 0;
}
}
// During short branch replacement, we store the relative (to blk_starts)
*** 445,455 ****
--- 445,455 ----
if( nj->is_Mach() && nj->as_Mach()->may_be_short_branch() ) {
MachNode *mach = nj->as_Mach();
// This requires the TRUE branch target be in succs[0]
uint bnum = b->non_connector_successor(0)->_pre_order;
uintptr_t target = blk_starts[bnum];
! if( mach->is_pc_relative() ) {
! if( mach->is_Branch() ) {
int offset = target-(blk_starts[i] + jmp_end[i]);
if (_matcher->is_short_branch_offset(mach->rule(), offset)) {
// We've got a winner. Replace this branch.
MachNode* replacement = mach->short_branch_version(this);
b->_nodes.map(j, replacement);
*** 506,516 ****
--- 506,516 ----
}
}
adr += nj->size(_regalloc);
// Remember end of call offset
! if (nj->is_MachCall() && nj->as_MachCall()->is_safepoint_node()) {
! if (nj->is_MachCall() && !nj->is_MachCallLeaf()) {
last_call_adr = adr;
}
}
if ( i != _cfg->_num_blocks-1) {
*** 1293,1303 ****
--- 1293,1303 ----
mcall->method_set((intptr_t)mcall->entry_point());
// Save the return address
call_returns[b->_pre_order] = current_offset + mcall->ret_addr_offset();
! if (!mcall->is_safepoint_node()) {
! if (mcall->is_MachCallLeaf()) {
is_mcall = false;
is_sfn = false;
}
}
*** 1563,1574 ****
--- 1563,1574 ----
// Get the offset of the return from the call
uint call_return = call_returns[b->_pre_order];
#ifdef ASSERT
assert( call_return > 0, "no call seen for this basic block" );
! while( b->_nodes[--j]->Opcode() == Op_MachProj ) ;
! assert( b->_nodes[j]->is_Call(), "CatchProj must follow call" );
! while( b->_nodes[--j]->is_MachProj() ) ;
! assert( b->_nodes[j]->is_MachCall(), "CatchProj must follow call" );
#endif
// last instruction is a CatchNode, find it's CatchProjNodes
int nof_succs = b->_num_succs;
// allocate space
GrowableArray<intptr_t> handler_bcis(nof_succs);
*** 2348,2359 ****
--- 2348,2359 ----
Node *last = bb->_nodes[_bb_end];
if( last->is_Catch() ||
// Exclude unreachable path case when Halt node is in a separate block.
(_bb_end > 1 && last->is_Mach() && last->as_Mach()->ideal_Opcode() == Op_Halt) ) {
// There must be a prior call. Skip it.
! while( !bb->_nodes[--_bb_end]->is_Call() ) {
! assert( bb->_nodes[_bb_end]->is_Proj(), "skipping projections after expected call" );
! while( !bb->_nodes[--_bb_end]->is_MachCall() ) {
! assert( bb->_nodes[_bb_end]->is_MachProj(), "skipping projections after expected call" );
}
} else if( last->is_MachNullCheck() ) {
// Backup so the last null-checked memory instruction is
// outside the schedulable range. Skip over the nullcheck,
// projection, and the memory nodes.
*** 2661,2671 ****
--- 2661,2671 ----
Node* end_node = (_bb_end-1 >= _bb_start) ? b->_nodes[last_safept] : NULL;
Node* last_safept_node = end_node;
for( uint i = _bb_end-1; i >= _bb_start; i-- ) {
Node *n = b->_nodes[i];
int is_def = n->outcnt(); // def if some uses prior to adding precedence edges
! if( n->Opcode() == Op_MachProj && n->ideal_reg() == MachProjNode::fat_proj ) {
! if( n->is_MachProj() && n->ideal_reg() == MachProjNode::fat_proj ) {
// Fat-proj kills a slew of registers
// This can add edges to 'n' and obscure whether or not it was a def,
// hence the is_def flag.
fat_proj_seen = true;
RegMask rm = n->out_RegMask();// Make local copy
*** 2683,2693 ****
--- 2683,2693 ----
// Check each register used by this instruction for a following DEF/KILL
// that must occur afterward and requires an anti-dependence edge.
for( uint j=0; j<n->req(); j++ ) {
Node *def = n->in(j);
if( def ) {
! assert( def->Opcode() != Op_MachProj || def->ideal_reg() != MachProjNode::fat_proj, "" );
! assert( !def->is_MachProj() || def->ideal_reg() != MachProjNode::fat_proj, "" );
anti_do_use( b, n, _regalloc->get_reg_first(def) );
anti_do_use( b, n, _regalloc->get_reg_second(def) );
}
}
// Do not allow defs of new derived values to float above GC
src/share/vm/opto/output.cpp
Index
Unified diffs
Context diffs
Sdiffs
Wdiffs
Patch
New
Old
Previous File
Next File