src/share/vm/opto/cfgnode.cpp
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File 6667595 Sdiff src/share/vm/opto

src/share/vm/opto/cfgnode.cpp

Print this page




1800         } else {
1801           assert(ii->is_Phi(), "sanity");
1802           if (ii->as_Phi() == this) {
1803             new_ii = new_phi;
1804           } else {
1805             new_ii = new (phase->C, 2) EncodePNode(ii, in_decodeN->bottom_type());
1806             igvn->register_new_node_with_optimizer(new_ii);
1807           }
1808         }
1809         new_phi->set_req(i, new_ii);
1810       }
1811       igvn->register_new_node_with_optimizer(new_phi, this);
1812       progress = new (phase->C, 2) DecodeNNode(new_phi, bottom_type());
1813     }
1814   }
1815 #endif
1816 
1817   return progress;              // Return any progress
1818 }
1819 






1820 //------------------------------out_RegMask------------------------------------
1821 const RegMask &PhiNode::in_RegMask(uint i) const {
1822   return i ? out_RegMask() : RegMask::Empty;
1823 }
1824 
1825 const RegMask &PhiNode::out_RegMask() const {
1826   uint ideal_reg = Matcher::base2reg[_type->base()];
1827   assert( ideal_reg != Node::NotAMachineReg, "invalid type at Phi" );
1828   if( ideal_reg == 0 ) return RegMask::Empty;
1829   return *(Compile::current()->matcher()->idealreg2spillmask[ideal_reg]);
1830 }
1831 
1832 #ifndef PRODUCT
1833 void PhiNode::dump_spec(outputStream *st) const {
1834   TypeNode::dump_spec(st);
1835   if (in(0) != NULL &&
1836       in(0)->is_CountedLoop() &&
1837       in(0)->as_CountedLoop()->phi() == this) {
1838     st->print(" #tripcount");
1839   }
1840 }
1841 #endif
1842 
1843 
1844 //=============================================================================
1845 const Type *GotoNode::Value( PhaseTransform *phase ) const {
1846   // If the input is reachable, then we are executed.
1847   // If the input is not reachable, then we are not executed.
1848   return phase->type(in(0));
1849 }
1850 
1851 Node *GotoNode::Identity( PhaseTransform *phase ) {
1852   return in(0);                // Simple copy of incoming control
1853 }
1854 
1855 const RegMask &GotoNode::out_RegMask() const {
1856   return RegMask::Empty;
1857 }




1800         } else {
1801           assert(ii->is_Phi(), "sanity");
1802           if (ii->as_Phi() == this) {
1803             new_ii = new_phi;
1804           } else {
1805             new_ii = new (phase->C, 2) EncodePNode(ii, in_decodeN->bottom_type());
1806             igvn->register_new_node_with_optimizer(new_ii);
1807           }
1808         }
1809         new_phi->set_req(i, new_ii);
1810       }
1811       igvn->register_new_node_with_optimizer(new_phi, this);
1812       progress = new (phase->C, 2) DecodeNNode(new_phi, bottom_type());
1813     }
1814   }
1815 #endif
1816 
1817   return progress;              // Return any progress
1818 }
1819 
1820 //------------------------------is_tripcount-----------------------------------
1821 bool PhiNode::is_tripcount() const {
1822   return (in(0) != NULL && in(0)->is_CountedLoop() &&
1823           in(0)->as_CountedLoop()->phi() == this);
1824 }
1825 
1826 //------------------------------out_RegMask------------------------------------
1827 const RegMask &PhiNode::in_RegMask(uint i) const {
1828   return i ? out_RegMask() : RegMask::Empty;
1829 }
1830 
1831 const RegMask &PhiNode::out_RegMask() const {
1832   uint ideal_reg = Matcher::base2reg[_type->base()];
1833   assert( ideal_reg != Node::NotAMachineReg, "invalid type at Phi" );
1834   if( ideal_reg == 0 ) return RegMask::Empty;
1835   return *(Compile::current()->matcher()->idealreg2spillmask[ideal_reg]);
1836 }
1837 
1838 #ifndef PRODUCT
1839 void PhiNode::dump_spec(outputStream *st) const {
1840   TypeNode::dump_spec(st);
1841   if (is_tripcount()) {


1842     st->print(" #tripcount");
1843   }
1844 }
1845 #endif
1846 
1847 
1848 //=============================================================================
1849 const Type *GotoNode::Value( PhaseTransform *phase ) const {
1850   // If the input is reachable, then we are executed.
1851   // If the input is not reachable, then we are not executed.
1852   return phase->type(in(0));
1853 }
1854 
1855 Node *GotoNode::Identity( PhaseTransform *phase ) {
1856   return in(0);                // Simple copy of incoming control
1857 }
1858 
1859 const RegMask &GotoNode::out_RegMask() const {
1860   return RegMask::Empty;
1861 }


src/share/vm/opto/cfgnode.cpp
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File