hotspot/src/share/vm/opto/node.cpp
changeset 360 21d113ecbf6a
parent 238 803c80713999
child 366 449c27706bac
--- a/hotspot/src/share/vm/opto/node.cpp	Fri Apr 11 09:56:35 2008 -0400
+++ b/hotspot/src/share/vm/opto/node.cpp	Sun Apr 13 17:43:42 2008 -0400
@@ -1169,6 +1169,12 @@
   return ((ConPNode*)this)->type()->is_ptr()->get_con();
 }
 
+// Get a narrow oop constant from a ConNNode.
+intptr_t Node::get_narrowcon() const {
+  assert( Opcode() == Op_ConN, "" );
+  return ((ConNNode*)this)->type()->is_narrowoop()->get_con();
+}
+
 // Get a long constant from a ConNode.
 // Return a default value if there is no apparent constant here.
 const TypeLong* Node::find_long_type() const {