add -forceDither option to bench (it is tristate)
update neon optimizations from motorola



git-svn-id: http://skia.googlecode.com/svn/trunk@391 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/bench/benchmain.cpp b/bench/benchmain.cpp
index 8ccb373..23a0c85 100644
--- a/bench/benchmain.cpp
+++ b/bench/benchmain.cpp
@@ -193,6 +193,7 @@
     int forceAlpha = 0xFF;
     bool forceAA = true;
     bool forceFilter = false;
+    SkTriState::State forceDither = SkTriState::kDefault;
     bool doScale = false;
     bool doRotate = false;
     bool doClip = false;
@@ -243,6 +244,13 @@
                 log_error("missing arg for -forceFilter\n");
                 return -1;
             }
+        } else if (strcmp(*argv, "-forceDither") == 0) {
+            bool tmp;
+            if (!parse_bool_arg(++argv, stop, &tmp)) {
+                log_error("missing arg for -forceDither\n");
+                return -1;
+            }
+            forceDither = tmp ? SkTriState::kTrue : SkTriState::kFalse;
         } else if (strcmp(*argv, "-forceBlend") == 0) {
             bool wantAlpha = false;
             if (!parse_bool_arg(++argv, stop, &wantAlpha)) {
@@ -303,6 +311,7 @@
         bench->setForceAlpha(forceAlpha);
         bench->setForceAA(forceAA);
         bench->setForceFilter(forceFilter);
+        bench->setDither(forceDither);
 
         // only run benchmarks if their name contains matchStr
         if (matchStr && strstr(bench->getName(), matchStr) == NULL) {