From cac31ad4c43a24a959a4d3652b8b46538bdc8c53 Mon Sep 17 00:00:00 2001 From: Andreas Gampe Date: Mon, 6 Nov 2017 20:01:17 -0800 Subject: ART: Add compiler option for code deduplication Add --deduplicate-code and --no-deduplicate-code to ease in experiments with deduplication, e.g., profiling. Add dex2oat test. Test: m test-art-host Change-Id: Ib6c7fe082f43c5f76c8463cc563e2503c9a50480 --- compiler/driver/compiler_options.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'compiler/driver/compiler_options.h') diff --git a/compiler/driver/compiler_options.h b/compiler/driver/compiler_options.h index 12de9be60b..ab2a681468 100644 --- a/compiler/driver/compiler_options.h +++ b/compiler/driver/compiler_options.h @@ -254,6 +254,10 @@ class CompilerOptions FINAL { return force_determinism_; } + bool DeduplicateCode() const { + return deduplicate_code_; + } + RegisterAllocator::Strategy GetRegisterAllocationStrategy() const { return register_allocation_strategy_; } @@ -319,6 +323,9 @@ class CompilerOptions FINAL { // outcomes. bool force_determinism_; + // Whether code should be deduplicated. + bool deduplicate_code_; + RegisterAllocator::Strategy register_allocation_strategy_; // If not null, specifies optimization passes which will be run instead of defaults. -- cgit v1.2.3-59-g8ed1b