diff options
author | 2017-07-19 15:59:14 +0000 | |
---|---|---|
committer | 2017-07-19 15:59:14 +0000 | |
commit | 57fe2725629681c8a68f6ba5b58d87304ca3f0b1 (patch) | |
tree | 96b7ddbd95cb5a57839473b443c2dc48b3eb9154 /compiler/optimizing/optimizing_compiler.cc | |
parent | 42cd8e7ca4ed38a2cefd7a695c54c77036cb62e4 (diff) | |
parent | 01db5f78f627cc64f80b0c0a4eedd0a3dc8b46ca (diff) |
Merge "Pass the logger to the JIT compiler."
Diffstat (limited to 'compiler/optimizing/optimizing_compiler.cc')
-rw-r--r-- | compiler/optimizing/optimizing_compiler.cc | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/compiler/optimizing/optimizing_compiler.cc b/compiler/optimizing/optimizing_compiler.cc index 890ba674b5..b76a0df861 100644 --- a/compiler/optimizing/optimizing_compiler.cc +++ b/compiler/optimizing/optimizing_compiler.cc @@ -76,6 +76,7 @@ #include "jit/debugger_interface.h" #include "jit/jit.h" #include "jit/jit_code_cache.h" +#include "jit/jit_logger.h" #include "jni/quick/jni_compiler.h" #include "licm.h" #include "load_store_analysis.h" @@ -334,7 +335,11 @@ class OptimizingCompiler FINAL : public Compiler { } } - bool JitCompile(Thread* self, jit::JitCodeCache* code_cache, ArtMethod* method, bool osr) + bool JitCompile(Thread* self, + jit::JitCodeCache* code_cache, + ArtMethod* method, + bool osr, + jit::JitLogger* jit_logger) OVERRIDE REQUIRES_SHARED(Locks::mutator_lock_); @@ -1136,7 +1141,8 @@ bool CanEncodeInlinedMethodInStackMap(const DexFile& caller_dex_file, ArtMethod* bool OptimizingCompiler::JitCompile(Thread* self, jit::JitCodeCache* code_cache, ArtMethod* method, - bool osr) { + bool osr, + jit::JitLogger* jit_logger) { StackHandleScope<3> hs(self); Handle<mirror::ClassLoader> class_loader(hs.NewHandle( method->GetDeclaringClass()->GetClassLoader())); @@ -1272,6 +1278,9 @@ bool OptimizingCompiler::JitCompile(Thread* self, } Runtime::Current()->GetJit()->AddMemoryUsage(method, arena.BytesUsed()); + if (jit_logger != nullptr) { + jit_logger->WriteLog(code, code_allocator.GetSize(), method); + } return true; } |