diff options
| author | Richard Uhler <ruhler@google.com> | 2016-03-23 20:05:26 +0000 |
|---|---|---|
| committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2016-03-23 20:05:26 +0000 |
| commit | f33c605e6986ac274ee3798a3c1944c8a16fbf3f (patch) | |
| tree | 92f34f589af205af56189d221ded293234935c26 /compiler/driver/compiler_options.cc | |
| parent | 2e89e901b9f303549f3ba64e45d87292e9c986c8 (diff) | |
| parent | 29d38e77c553c6cf71fc4dafe2d22b4e3f814872 (diff) | |
Merge "Revert "Revert "Use compiler filter to determine oat file status."""
Diffstat (limited to 'compiler/driver/compiler_options.cc')
| -rw-r--r-- | compiler/driver/compiler_options.cc | 22 |
1 files changed, 2 insertions, 20 deletions
diff --git a/compiler/driver/compiler_options.cc b/compiler/driver/compiler_options.cc index f5969aa825..1bd4c3ad80 100644 --- a/compiler/driver/compiler_options.cc +++ b/compiler/driver/compiler_options.cc @@ -52,7 +52,7 @@ CompilerOptions::~CompilerOptions() { // because we don't want to include the PassManagerOptions definition from the header file. } -CompilerOptions::CompilerOptions(CompilerFilter compiler_filter, +CompilerOptions::CompilerOptions(CompilerFilter::Filter compiler_filter, size_t huge_method_threshold, size_t large_method_threshold, size_t small_method_threshold, @@ -147,25 +147,7 @@ void CompilerOptions::ParseDumpInitFailures(const StringPiece& option, bool CompilerOptions::ParseCompilerOption(const StringPiece& option, UsageFn Usage) { if (option.starts_with("--compiler-filter=")) { const char* compiler_filter_string = option.substr(strlen("--compiler-filter=")).data(); - if (strcmp(compiler_filter_string, "verify-none") == 0) { - compiler_filter_ = CompilerOptions::kVerifyNone; - } else if (strcmp(compiler_filter_string, "interpret-only") == 0) { - compiler_filter_ = CompilerOptions::kInterpretOnly; - } else if (strcmp(compiler_filter_string, "verify-at-runtime") == 0) { - compiler_filter_ = CompilerOptions::kVerifyAtRuntime; - } else if (strcmp(compiler_filter_string, "space") == 0) { - compiler_filter_ = CompilerOptions::kSpace; - } else if (strcmp(compiler_filter_string, "balanced") == 0) { - compiler_filter_ = CompilerOptions::kBalanced; - } else if (strcmp(compiler_filter_string, "speed") == 0) { - compiler_filter_ = CompilerOptions::kSpeed; - } else if (strcmp(compiler_filter_string, "everything") == 0) { - compiler_filter_ = CompilerOptions::kEverything; - } else if (strcmp(compiler_filter_string, "time") == 0) { - compiler_filter_ = CompilerOptions::kTime; - } else if (strcmp(compiler_filter_string, "verify-profile") == 0) { - compiler_filter_ = CompilerOptions::kVerifyProfile; - } else { + if (!CompilerFilter::ParseCompilerFilter(compiler_filter_string, &compiler_filter_)) { Usage("Unknown --compiler-filter value %s", compiler_filter_string); } } else if (option == "--compile-pic") { |
