diff options
author | 2019-06-06 16:20:54 +0100 | |
---|---|---|
committer | 2019-06-10 07:32:49 +0000 | |
commit | 7f7539b8ed0a31de1d1b6e1f0b730d55e37666a6 (patch) | |
tree | d1611f06e3e468ff61c4d4bc349777b85b3a2e16 /compiler/jit/jit_compiler.cc | |
parent | 93adcb53c77f4f04dfebd30b94e8ea9936aa8abb (diff) |
Pass the memory region to allocate into to the compiler / allocation.
Test: test.py
Bug: 119800099
Change-Id: Ie3cba5abe3dd4f8756af5ecfd6c26320de314fe8
Diffstat (limited to 'compiler/jit/jit_compiler.cc')
-rw-r--r-- | compiler/jit/jit_compiler.cc | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/compiler/jit/jit_compiler.cc b/compiler/jit/jit_compiler.cc index b42e9f2592..f19de4e576 100644 --- a/compiler/jit/jit_compiler.cc +++ b/compiler/jit/jit_compiler.cc @@ -129,11 +129,11 @@ extern "C" void jit_unload(void* handle) { } extern "C" bool jit_compile_method( - void* handle, ArtMethod* method, Thread* self, bool baseline, bool osr) + void* handle, JitMemoryRegion* region, ArtMethod* method, Thread* self, bool baseline, bool osr) REQUIRES_SHARED(Locks::mutator_lock_) { auto* jit_compiler = reinterpret_cast<JitCompiler*>(handle); DCHECK(jit_compiler != nullptr); - return jit_compiler->CompileMethod(self, method, baseline, osr); + return jit_compiler->CompileMethod(self, region, method, baseline, osr); } extern "C" void jit_types_loaded(void* handle, mirror::Class** types, size_t count) @@ -181,7 +181,8 @@ JitCompiler::~JitCompiler() { } } -bool JitCompiler::CompileMethod(Thread* self, ArtMethod* method, bool baseline, bool osr) { +bool JitCompiler::CompileMethod( + Thread* self, JitMemoryRegion* region, ArtMethod* method, bool baseline, bool osr) { SCOPED_TRACE << "JIT compiling " << method->PrettyMethod(); DCHECK(!method->IsProxyMethod()); @@ -198,7 +199,8 @@ bool JitCompiler::CompileMethod(Thread* self, ArtMethod* method, bool baseline, TimingLogger::ScopedTiming t2("Compiling", &logger); JitCodeCache* const code_cache = runtime->GetJit()->GetCodeCache(); uint64_t start_ns = NanoTime(); - success = compiler_->JitCompile(self, code_cache, method, baseline, osr, jit_logger_.get()); + success = compiler_->JitCompile( + self, code_cache, region, method, baseline, osr, jit_logger_.get()); uint64_t duration_ns = NanoTime() - start_ns; VLOG(jit) << "Compilation of " << method->PrettyMethod() |