From a59af8aeaad8fe7d68d8f8de63eab9cf85b6ab31 Mon Sep 17 00:00:00 2001 From: Nicolas Geoffray Date: Wed, 27 Nov 2019 17:42:32 +0000 Subject: JIT baseline: trigger optimized compilation on hotness threshold. - Add a new hotness count in the ProfilingInfo to not conflict with interpreter hotness which may use it for OSR. - Add a baseline flag in the OatQuickMethodHeader to identify baseline compiled methods. - Add a -Xusetieredjit flag to experiment and test. Bug: 119800099 Test: test.py with Xusetieredjit to true Change-Id: I8512853f869f1312e3edc60bf64413dee9143c52 --- compiler/optimizing/nodes.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'compiler/optimizing/nodes.h') diff --git a/compiler/optimizing/nodes.h b/compiler/optimizing/nodes.h index 09ae6fab84..043338466f 100644 --- a/compiler/optimizing/nodes.h +++ b/compiler/optimizing/nodes.h @@ -322,6 +322,7 @@ class HGraph : public ArenaObject { bool debuggable = false, bool osr = false, bool is_shared_jit_code = false, + bool baseline = false, int start_instruction_id = 0) : allocator_(allocator), arena_stack_(arena_stack), @@ -358,6 +359,7 @@ class HGraph : public ArenaObject { art_method_(nullptr), inexact_object_rti_(ReferenceTypeInfo::CreateInvalid()), osr_(osr), + baseline_(baseline), cha_single_implementation_list_(allocator->Adapter(kArenaAllocCHA)), is_shared_jit_code_(is_shared_jit_code) { blocks_.reserve(kDefaultNumberOfBlocks); @@ -589,6 +591,8 @@ class HGraph : public ArenaObject { bool IsCompilingOsr() const { return osr_; } + bool IsCompilingBaseline() const { return baseline_; } + bool IsCompilingForSharedJitCode() const { return is_shared_jit_code_; } @@ -786,6 +790,10 @@ class HGraph : public ArenaObject { // compiled code entries which the interpreter can directly jump to. const bool osr_; + // Whether we are compiling baseline (not running optimizations). This affects + // the code being generated. + const bool baseline_; + // List of methods that are assumed to have single implementation. ArenaSet cha_single_implementation_list_; -- cgit v1.2.3-59-g8ed1b