diff src/share/vm/opto/cfgnode.cpp @ 400:cc80376deb0c

6667595: Set probability FAIR for pre-, post- loops and ALWAYS for main loop Summary: Fix loop's probability. Add optimizations to avoid spilling. Change InlineSmallCode to product flag. Reviewed-by: never
author kvn
date Thu, 02 Oct 2008 08:37:44 -0700
parents 36ccc817fca4
children 35ae4dd6c27c
line wrap: on
line diff
--- a/src/share/vm/opto/cfgnode.cpp	Tue Sep 30 15:53:55 2008 -0700
+++ b/src/share/vm/opto/cfgnode.cpp	Thu Oct 02 08:37:44 2008 -0700
@@ -1817,6 +1817,12 @@
   return progress;              // Return any progress
 }
 
+//------------------------------is_tripcount-----------------------------------
+bool PhiNode::is_tripcount() const {
+  return (in(0) != NULL && in(0)->is_CountedLoop() &&
+          in(0)->as_CountedLoop()->phi() == this);
+}
+
 //------------------------------out_RegMask------------------------------------
 const RegMask &PhiNode::in_RegMask(uint i) const {
   return i ? out_RegMask() : RegMask::Empty;
@@ -1832,9 +1838,7 @@
 #ifndef PRODUCT
 void PhiNode::dump_spec(outputStream *st) const {
   TypeNode::dump_spec(st);
-  if (in(0) != NULL &&
-      in(0)->is_CountedLoop() &&
-      in(0)->as_CountedLoop()->phi() == this) {
+  if (is_tripcount()) {
     st->print(" #tripcount");
   }
 }