changeset 58:b508dbc99189

Revert the options preset.
author shade
date Thu, 03 Oct 2013 15:11:10 +0400
parents 69bc1543d446
children 52dc3f38237c
files harness/src/main/java/org/openjdk/jcstress/Options.java
diffstat 1 files changed, 30 insertions(+), 30 deletions(-) [+]
line wrap: on
line diff
--- a/harness/src/main/java/org/openjdk/jcstress/Options.java	Thu Oct 03 15:09:47 2013 +0400
+++ b/harness/src/main/java/org/openjdk/jcstress/Options.java	Thu Oct 03 15:11:10 2013 +0400
@@ -147,36 +147,6 @@
             return false;
         }
 
-        mode = orDefault(modeStr.value(set), "default");
-        if (this.mode.equalsIgnoreCase("sanity")) {
-            this.time = 50;
-            this.iters = 1;
-            this.forks = 0;
-        } else
-        if (this.mode.equalsIgnoreCase("quick")) {
-            this.time = 300;
-            this.iters = 5;
-            this.forks = 0;
-        } else
-        if (this.mode.equalsIgnoreCase("default")) {
-            // do nothing
-        } else
-        if (this.mode.equalsIgnoreCase("tough")) {
-            this.time = 5000;
-            this.iters = 10;
-            this.forks = 10;
-        } else
-        if (this.mode.equalsIgnoreCase("stress")) {
-            this.time = 1000;
-            this.iters = 5;
-            this.forks = 100;
-        } else {
-            System.err.println("Unknown test mode: " + this.mode);
-            System.err.println();
-            parser.printHelpOn(System.err);
-            return false;
-        }
-
         this.resultDir = orDefault(set.valueOf(result), "results/");
         if (!resultDir.endsWith("/")) {
             resultDir += "/";
@@ -223,6 +193,36 @@
         this.userYield = set.has(shouldYield);
         this.shouldYield = orDefault(set.valueOf(shouldYield), forceYield);
 
+        mode = orDefault(modeStr.value(set), "default");
+        if (this.mode.equalsIgnoreCase("sanity")) {
+            this.time = 50;
+            this.iters = 1;
+            this.forks = 0;
+        } else
+        if (this.mode.equalsIgnoreCase("quick")) {
+            this.time = 300;
+            this.iters = 5;
+            this.forks = 0;
+        } else
+        if (this.mode.equalsIgnoreCase("default")) {
+            // do nothing
+        } else
+        if (this.mode.equalsIgnoreCase("tough")) {
+            this.time = 5000;
+            this.iters = 10;
+            this.forks = 10;
+        } else
+        if (this.mode.equalsIgnoreCase("stress")) {
+            this.time = 1000;
+            this.iters = 5;
+            this.forks = 100;
+        } else {
+            System.err.println("Unknown test mode: " + this.mode);
+            System.err.println();
+            parser.printHelpOn(System.err);
+            return false;
+        }
+
         return true;
     }