Avoid std::string allocations for finding an array class.

Introduce ClassLinker::FindArrayClass which performs an array class lookup
given the element/component class. This has a 16 element cache of recently
looked up arrays.
Pass the current thread to ClassLinker Find .. Class routines to avoid calls
to Thread::Current().
Avoid some uses of FindClass in the debugger where WellKnownClasses is a
faster and more compacting GC friendly alternative.

Change-Id: I60e231820b349543a7edb3ceb9cf1ce92db3c843
diff --git a/compiler/image_writer.cc b/compiler/image_writer.cc
index 58f66b9..c8447be 100644
--- a/compiler/image_writer.cc
+++ b/compiler/image_writer.cc
@@ -401,7 +401,8 @@
   Runtime* runtime = Runtime::Current();
   ClassLinker* class_linker = runtime->GetClassLinker();
   Thread* self = Thread::Current();
-  SirtRef<Class> object_array_class(self, class_linker->FindSystemClass("[Ljava/lang/Object;"));
+  SirtRef<Class> object_array_class(self, class_linker->FindSystemClass(self,
+                                                                        "[Ljava/lang/Object;"));
 
   // build an Object[] of all the DexCaches used in the source_space_
   ObjectArray<Object>* dex_caches = ObjectArray<Object>::Alloc(self, object_array_class.get(),