ART: IRT refactor

IRT creation might fail. Add a path that allows to bypass the aborts
and instead signal validity. Hide this path with a private constructor,
rewrite users to use a static Create method.

Bug: 20110201

Change-Id: I440499c3372cd7557eb970b70ce2c4543da520e4
diff --git a/runtime/thread.cc b/runtime/thread.cc
index d1b0464..89fc00e 100644
--- a/runtime/thread.cc
+++ b/runtime/thread.cc
@@ -377,7 +377,11 @@
 
   tls32_.thin_lock_thread_id = thread_list->AllocThreadId(this);
 
-  tlsPtr_.jni_env = new JNIEnvExt(this, java_vm);
+  tlsPtr_.jni_env = JNIEnvExt::Create(this, java_vm);
+  if (tlsPtr_.jni_env == nullptr) {
+    return false;
+  }
+
   thread_list->Register(this);
   return true;
 }