changeset 4578:cf6a8e400e0f

Merge
author kvn
date Thu, 20 Jun 2013 23:26:12 -0700
parents b964a67d19df fde31393d1ce
children 0b260439fc78
files
diffstat 2 files changed, 15 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/vm/opto/reg_split.cpp	Thu Jun 20 17:23:52 2013 -0700
+++ b/src/share/vm/opto/reg_split.cpp	Thu Jun 20 23:26:12 2013 -0700
@@ -51,6 +51,15 @@
 
 static const char out_of_nodes[] = "out of nodes during split";
 
+static bool contains_no_live_range_input(const Node* def) {
+  for (uint i = 1; i < def->req(); ++i) {
+    if (def->in(i) != NULL && def->in_RegMask(i).is_NotEmpty()) {
+      return false;
+    }
+  }
+  return true;
+}
+
 //------------------------------get_spillcopy_wide-----------------------------
 // Get a SpillCopy node with wide-enough masks.  Use the 'wide-mask', the
 // wide ideal-register spill-mask if possible.  If the 'wide-mask' does
@@ -1289,7 +1298,7 @@
       Node *def = Reaches[pidx][slidx];
       assert( def, "must have reaching def" );
       // If input up/down sense and reg-pressure DISagree
-      if( def->rematerialize() ) {
+      if (def->rematerialize() && contains_no_live_range_input(def)) {
         // Place the rematerialized node above any MSCs created during
         // phi node splitting.  end_idx points at the insertion point
         // so look at the node before it.
--- a/src/share/vm/runtime/arguments.cpp	Thu Jun 20 17:23:52 2013 -0700
+++ b/src/share/vm/runtime/arguments.cpp	Thu Jun 20 23:26:12 2013 -0700
@@ -1609,8 +1609,12 @@
 void Arguments::set_aggressive_opts_flags() {
 #ifdef COMPILER2
   if (AggressiveOpts || !FLAG_IS_DEFAULT(AutoBoxCacheMax)) {
+    // EliminateAutoBox code is broken in C2
     if (FLAG_IS_DEFAULT(EliminateAutoBox)) {
-      FLAG_SET_DEFAULT(EliminateAutoBox, true);
+      // FLAG_SET_DEFAULT(EliminateAutoBox, true);
+    }
+    if (EliminateAutoBox) {
+      FLAG_SET_DEFAULT(EliminateAutoBox, false);
     }
     if (FLAG_IS_DEFAULT(AutoBoxCacheMax)) {
       FLAG_SET_DEFAULT(AutoBoxCacheMax, 20000);