< prev index next >

src/share/vm/opto/lcm.cpp

Print this page




 822     // Children of projections are now all ready
 823     for (DUIterator_Fast jmax, j = n->fast_outs(jmax); j < jmax; j++) {
 824       Node* m = n->fast_out(j); // Get user
 825       if(get_block_for_node(m) != block) {
 826         continue;
 827       }
 828       if( m->is_Phi() ) continue;
 829       int m_cnt = ready_cnt.at(m->_idx) - 1;
 830       ready_cnt.at_put(m->_idx, m_cnt);
 831       if( m_cnt == 0 )
 832         worklist.push(m);
 833     }
 834 
 835   }
 836 
 837   // Act as if the call defines the Frame Pointer.
 838   // Certainly the FP is alive and well after the call.
 839   regs.Insert(_matcher.c_frame_pointer());
 840 
 841   // Set all registers killed and not already defined by the call.
 842   uint r_cnt = mcall->tf()->range()->cnt();
 843   int op = mcall->ideal_Opcode();
 844   MachProjNode *proj = new MachProjNode( mcall, r_cnt+1, RegMask::Empty, MachProjNode::fat_proj );
 845   map_node_to_block(proj, block);
 846   block->insert_node(proj, node_cnt++);
 847 
 848   // Select the right register save policy.
 849   const char *save_policy = NULL;
 850   switch (op) {
 851     case Op_CallRuntime:
 852     case Op_CallLeaf:
 853     case Op_CallLeafNoFP:
 854       // Calling C code so use C calling convention
 855       save_policy = _matcher._c_reg_save_policy;
 856       break;
 857 
 858     case Op_CallStaticJava:
 859     case Op_CallDynamicJava:
 860       // Calling Java code so use Java calling convention
 861       save_policy = _matcher._register_save_policy;
 862       break;




 822     // Children of projections are now all ready
 823     for (DUIterator_Fast jmax, j = n->fast_outs(jmax); j < jmax; j++) {
 824       Node* m = n->fast_out(j); // Get user
 825       if(get_block_for_node(m) != block) {
 826         continue;
 827       }
 828       if( m->is_Phi() ) continue;
 829       int m_cnt = ready_cnt.at(m->_idx) - 1;
 830       ready_cnt.at_put(m->_idx, m_cnt);
 831       if( m_cnt == 0 )
 832         worklist.push(m);
 833     }
 834 
 835   }
 836 
 837   // Act as if the call defines the Frame Pointer.
 838   // Certainly the FP is alive and well after the call.
 839   regs.Insert(_matcher.c_frame_pointer());
 840 
 841   // Set all registers killed and not already defined by the call.
 842   uint r_cnt = mcall->tf()->range_cc()->cnt();
 843   int op = mcall->ideal_Opcode();
 844   MachProjNode *proj = new MachProjNode( mcall, r_cnt+1, RegMask::Empty, MachProjNode::fat_proj );
 845   map_node_to_block(proj, block);
 846   block->insert_node(proj, node_cnt++);
 847 
 848   // Select the right register save policy.
 849   const char *save_policy = NULL;
 850   switch (op) {
 851     case Op_CallRuntime:
 852     case Op_CallLeaf:
 853     case Op_CallLeafNoFP:
 854       // Calling C code so use C calling convention
 855       save_policy = _matcher._c_reg_save_policy;
 856       break;
 857 
 858     case Op_CallStaticJava:
 859     case Op_CallDynamicJava:
 860       // Calling Java code so use Java calling convention
 861       save_policy = _matcher._register_save_policy;
 862       break;


< prev index next >