Fix on-device compile.

Change-Id: I4687672f6f82d155f76201c92c44c95f9f32a2ad
diff --git a/src/compiler_llvm/compilation_unit.cc b/src/compiler_llvm/compilation_unit.cc
index 166d2f6..a1d66f1 100644
--- a/src/compiler_llvm/compilation_unit.cc
+++ b/src/compiler_llvm/compilation_unit.cc
@@ -205,7 +205,8 @@
 };
 
 bool CompilationUnit::Materialize() {
-  const std::string tmp_file("/tmp/art-llvm-XXXXXX");
+  std::string tmp_file = GetArtCacheOrDie();
+  tmp_file += "/art-llvm-XXXXXX";
 
   // Prepare the input
   ScopedTempFile input(tmp_file);