Fix CreateLinearAlloc bug
Should have been using IsAotCompiler since the JIT has IsCompiler
as true but no low 4 GB arena pool.
Fixes 64 bit JIT tests.
Change-Id: Idc4d3e66c573eacd31ae85c66f8493b418d221d7
diff --git a/runtime/runtime.cc b/runtime/runtime.cc
index fe97394..8cba1a9 100644
--- a/runtime/runtime.cc
+++ b/runtime/runtime.cc
@@ -944,7 +944,7 @@
// can't be trimmed as easily.
const bool use_malloc = IsAotCompiler();
arena_pool_.reset(new ArenaPool(use_malloc, false));
- if (IsCompiler() && Is64BitInstructionSet(kRuntimeISA)) {
+ if (IsAotCompiler() && Is64BitInstructionSet(kRuntimeISA)) {
// 4gb, no malloc. Explanation in header.
low_4gb_arena_pool_.reset(new ArenaPool(false, true));
}
@@ -1790,7 +1790,7 @@
}
LinearAlloc* Runtime::CreateLinearAlloc() {
- return (IsCompiler() && Is64BitInstructionSet(kRuntimeISA))
+ return (IsAotCompiler() && Is64BitInstructionSet(kRuntimeISA))
? new LinearAlloc(low_4gb_arena_pool_.get())
: new LinearAlloc(arena_pool_.get());
}