summaryrefslogtreecommitdiff
path: root/compiler/driver/compiler_options.h
diff options
context:
space:
mode:
author Santiago Aboy Solanes <solanes@google.com> 2024-02-02 09:21:03 +0000
committer Treehugger Robot <android-test-infra-autosubmit@system.gserviceaccount.com> 2024-02-06 12:35:32 +0000
commit089c5fc39d68b5670e20733f13a0bb472c71e27f (patch)
tree5df757fa7caeac87bb9fa8263665484b4f89c990 /compiler/driver/compiler_options.h
parent5592ceb65d8b33c1ebcd5e0b3f317a0c9f60f188 (diff)
CompilerOptions refactor after aosp/2808063
* Updated comments * Made constants constexpr * Renamed kBaselineMaxCodeUnits to include "Inline" Test: art/test/testrunner/testrunner.py --host --64 --optimizing -b Change-Id: I37569b3d9e5eecfd65a505a79945bbe5b290fbbf
Diffstat (limited to 'compiler/driver/compiler_options.h')
-rw-r--r--compiler/driver/compiler_options.h16
1 files changed, 9 insertions, 7 deletions
diff --git a/compiler/driver/compiler_options.h b/compiler/driver/compiler_options.h
index f659b12959..eaf9cc2fdb 100644
--- a/compiler/driver/compiler_options.h
+++ b/compiler/driver/compiler_options.h
@@ -60,14 +60,16 @@ enum class ProfileMethodsCheck : uint8_t {
class CompilerOptions final {
public:
- // Guide heuristics to determine whether to compile method if profile data not available.
- static const size_t kDefaultHugeMethodThreshold = 10000;
- static const bool kDefaultGenerateDebugInfo = false;
- static const bool kDefaultGenerateMiniDebugInfo = true;
- static const size_t kDefaultInlineMaxCodeUnits = 32;
- // We set a lower inlining threshold for baseline to reduce code size and compilation time.
- static const size_t kBaselineMaxCodeUnits = 8;
+ // Default values for parameters set via flags.
+ static constexpr bool kDefaultGenerateDebugInfo = false;
+ static constexpr bool kDefaultGenerateMiniDebugInfo = true;
+ static constexpr size_t kDefaultHugeMethodThreshold = 10000;
+ static constexpr size_t kDefaultInlineMaxCodeUnits = 32;
+ // Token to represent no value set for `inline_max_code_units_`.
static constexpr size_t kUnsetInlineMaxCodeUnits = -1;
+ // We set a lower inlining threshold for baseline to reduce code size and compilation time. This
+ // cannot be changed via flags.
+ static constexpr size_t kBaselineInlineMaxCodeUnits = 8;
enum class CompilerType : uint8_t {
kAotCompiler, // AOT compiler.