Start parallelizing dex2oat.

This is enough to perform type resolution and verification in parallel.

There appears to be a bug in InitCpu --- if you start enough threads
at once, the CHECK at the end starts to fail, with self_check == NULL; I've
commented it out for now, but this will cause test failures until it's fixed.

Change-Id: I4919682520bc01d3262c6b3d00c7bd2c2860a52e
diff --git a/src/runtime.h b/src/runtime.h
index dda5823..8a86c3c 100644
--- a/src/runtime.h
+++ b/src/runtime.h
@@ -66,6 +66,7 @@
     std::vector<std::string> images_;
     bool check_jni_;
     std::string jni_trace_;
+    bool is_compiler_;
     bool is_zygote_;
     size_t heap_initial_size_;
     size_t heap_maximum_size_;
@@ -87,6 +88,10 @@
   // Creates and initializes a new runtime.
   static Runtime* Create(const Options& options, bool ignore_unrecognized);
 
+  bool IsCompiler() const {
+    return is_compiler_;
+  }
+
   bool IsZygote() const {
     return is_zygote_;
   }
@@ -238,6 +243,7 @@
   void StartDaemonThreads();
   void StartSignalCatcher();
 
+  bool is_compiler_;
   bool is_zygote_;
 
   // The host prefix is used during cross compilation. It is removed