diff options
-rw-r--r-- | compiler/optimizing/optimizing_compiler.cc | 5 | ||||
-rw-r--r-- | test/Android.run-test.mk | 3 | ||||
-rwxr-xr-x | test/run-test | 4 |
3 files changed, 6 insertions, 6 deletions
diff --git a/compiler/optimizing/optimizing_compiler.cc b/compiler/optimizing/optimizing_compiler.cc index 475d98c..e47b4f6 100644 --- a/compiler/optimizing/optimizing_compiler.cc +++ b/compiler/optimizing/optimizing_compiler.cc @@ -222,7 +222,8 @@ static const int kMaximumCompilationTimeBeforeWarning = 100; /* ms */ OptimizingCompiler::OptimizingCompiler(CompilerDriver* driver) : Compiler(driver, kMaximumCompilationTimeBeforeWarning), run_optimizations_( - driver->GetCompilerOptions().GetCompilerFilter() != CompilerOptions::kTime), + (driver->GetCompilerOptions().GetCompilerFilter() != CompilerOptions::kTime) + && !driver->GetCompilerOptions().GetDebuggable()), compilation_stats_() {} void OptimizingCompiler::Init() { @@ -463,7 +464,7 @@ CompiledMethod* OptimizingCompiler::Compile(const DexFile::CodeItem* code_item, // For testing purposes, we put a special marker on method names that should be compiled // with this compiler. This makes sure we're not regressing. bool shouldCompile = method_name.find("$opt$") != std::string::npos; - bool shouldOptimize = method_name.find("$opt$reg$") != std::string::npos; + bool shouldOptimize = method_name.find("$opt$reg$") != std::string::npos && run_optimizations_; std::unique_ptr<CodeGenerator> codegen( CodeGenerator::Create(graph, diff --git a/test/Android.run-test.mk b/test/Android.run-test.mk index f84e0fb..9755efb 100644 --- a/test/Android.run-test.mk +++ b/test/Android.run-test.mk @@ -382,9 +382,6 @@ TEST_ART_BROKEN_OPTIMIZING_NONDEBUGGABLE_RUN_TESTS := # Tests that should fail when the optimizing compiler compiles them debuggable. TEST_ART_BROKEN_OPTIMIZING_DEBUGGABLE_RUN_TESTS := \ - 441-checker-inliner \ - 446-checker-inliner2 \ - 447-checker-inliner3 \ ifneq (,$(filter optimizing,$(COMPILER_TYPES))) ART_TEST_KNOWN_BROKEN += $(call all-run-test-names,$(TARGET_TYPES),$(RUN_TYPES),$(PREBUILD_TYPES), \ diff --git a/test/run-test b/test/run-test index 2950af1..2f7a5ac 100755 --- a/test/run-test +++ b/test/run-test @@ -80,6 +80,7 @@ lib="libartd.so" run_args="--quiet" build_args="" +debuggable="no" prebuild_mode="yes" target_mode="yes" dev_mode="no" @@ -149,6 +150,7 @@ while true; do shift; elif [ "x$1" = "x--debuggable" ]; then run_args="${run_args} -Xcompiler-option --debuggable" + debuggable="yes" shift; elif [ "x$1" = "x--no-prebuild" ]; then run_args="${run_args} --no-prebuild" @@ -523,7 +525,7 @@ if [[ "$TEST_NAME" =~ ^[0-9]+-checker- ]]; then # if Checker is not invoked and the test only runs the program. build_args="${build_args} --dx-option --no-optimize" - if [ "$runtime" = "art" -a "$image_suffix" = "-optimizing" -a "$target_mode" = "no" ]; then + if [ "$runtime" = "art" -a "$image_suffix" = "-optimizing" -a "$target_mode" = "no" -a "$debuggable" = "no"]; then run_checker="yes" run_args="${run_args} -Xcompiler-option --dump-cfg=$tmp_dir/$cfg_output \ -Xcompiler-option -j1" |