Use native target build to reduce dependences.

Change-Id: I912e8ceb713fa7cebbdb7cbc340298d32a3ea388
diff --git a/src/compiler_llvm/compiler_llvm.cc b/src/compiler_llvm/compiler_llvm.cc
index db4ad0a..635fde3 100644
--- a/src/compiler_llvm/compiler_llvm.cc
+++ b/src/compiler_llvm/compiler_llvm.cc
@@ -54,12 +54,18 @@
   // Initialize LLVM target-specific options.
   art::compiler_llvm::InitialBackendOptions();
 
-  // Initialize LLVM target, MC subsystem, asm printer, and asm parser
+  // Initialize LLVM target, MC subsystem, asm printer, and asm parser.
+#if defined(ART_TARGET)
+  // Don't initialize all targets on device. Just initialize the device's native target
+  llvm::InitializeNativeTarget();
+  llvm::InitializeNativeTargetAsmPrinter();
+  llvm::InitializeNativeTargetAsmParser();
+#else
   llvm::InitializeAllTargets();
   llvm::InitializeAllTargetMCs();
   llvm::InitializeAllAsmPrinters();
   llvm::InitializeAllAsmParsers();
-  // TODO: Maybe we don't have to initialize "all" targets.
+#endif
 
   // Initialize LLVM optimization passes
   llvm::PassRegistry &registry = *llvm::PassRegistry::getPassRegistry();