8179953: [ppc] TLABWasteIncrement not loaded correctly
authorgoetz
Tue, 09 May 2017 16:48:31 +0200
changeset 46487 f8e5223d1501
parent 46486 314aa24e62d6
child 46488 01c282163d38
child 46489 40abcea5a9d5
8179953: [ppc] TLABWasteIncrement not loaded correctly Summary: Also fix TestOptionWithRanges to show the bug. Reviewed-by: dholmes, shade
hotspot/src/cpu/ppc/vm/templateTable_ppc_64.cpp
hotspot/test/runtime/CommandLine/OptionsValidation/common/optionsvalidation/JVMOption.java
hotspot/test/runtime/CommandLine/OptionsValidation/common/optionsvalidation/JVMOptionsUtils.java
--- a/hotspot/src/cpu/ppc/vm/templateTable_ppc_64.cpp	Fri Apr 28 14:34:24 2017 +0200
+++ b/hotspot/src/cpu/ppc/vm/templateTable_ppc_64.cpp	Tue May 09 16:48:31 2017 +0200
@@ -3720,7 +3720,7 @@
       __ bge(CCR0, Lslow_case);
 
       // Increment waste limit to prevent getting stuck on this slow path.
-      __ addi(RtlabWasteLimitValue, RtlabWasteLimitValue, (int)ThreadLocalAllocBuffer::refill_waste_limit_increment());
+      __ add_const_optimized(RtlabWasteLimitValue, RtlabWasteLimitValue, ThreadLocalAllocBuffer::refill_waste_limit_increment());
       __ std(RtlabWasteLimitValue, in_bytes(JavaThread::tlab_refill_waste_limit_offset()), R16_thread);
     }
     // else: No allocation in the shared eden. // fallthru: __ b(Lslow_case);
--- a/hotspot/test/runtime/CommandLine/OptionsValidation/common/optionsvalidation/JVMOption.java	Fri Apr 28 14:34:24 2017 +0200
+++ b/hotspot/test/runtime/CommandLine/OptionsValidation/common/optionsvalidation/JVMOption.java	Tue May 09 16:48:31 2017 +0200
@@ -383,7 +383,11 @@
             runJava.add(VMType);
         }
 
-        if (GCType != null) {
+        if (GCType != null &&
+            !(prepend.contains("-XX:+UseConcMarkSweepGC") ||
+              prepend.contains("-XX:+UseSerialGC") ||
+              prepend.contains("-XX:+UseParallelGC") ||
+              prepend.contains("-XX:+UseG1GC"))) {
             runJava.add(GCType);
         }
 
--- a/hotspot/test/runtime/CommandLine/OptionsValidation/common/optionsvalidation/JVMOptionsUtils.java	Fri Apr 28 14:34:24 2017 +0200
+++ b/hotspot/test/runtime/CommandLine/OptionsValidation/common/optionsvalidation/JVMOptionsUtils.java	Tue May 09 16:48:31 2017 +0200
@@ -242,6 +242,9 @@
                 option.addPrepend("-XX:SharedArchiveFile=TestOptionsWithRanges.jsa");
                 option.addPrepend("-Xshare:dump");
                 break;
+            case "TLABWasteIncrement":
+                option.addPrepend("-XX:+UseParallelGC");
+                break;
             default:
                 /* Do nothing */
                 break;