diff options
author | David Srbecky <dsrbecky@google.com> | 2020-05-11 23:30:29 +0000 |
---|---|---|
committer | David Srbecky <dsrbecky@google.com> | 2020-05-15 18:06:16 +0100 |
commit | 883c1346b87537ed93f7d4fd88bbbb041c14d320 (patch) | |
tree | efb8205d15d677d3e3fdf90f0ae09c4a2eba9a4f /compiler/optimizing/codegen_test_utils.h | |
parent | 612809740453427ce4c9211062794dde3823ab6d (diff) |
Revert^2 "Remove test_per_src from ART tests."
Second attempt at this, which fixes the asan failures.
Remove test_per_src since it is not supported by atest.
Replace it with gtest_isolate which is transparent to atest,
and which still allows us to run tests in parallel.
The size of test binaries halves (from 1GB to 0.5GB).
Test run-time on host is unchanged.
Test run-time on target is 4x faster (tested on walleye).
Added a gtest_main.cc with the gtest isolated main function,
and ART-specific initialization.
Bug: 147819342
Test: m test-art-host-gtest
Test: art/tools/run-gtests.sh
Test: art/test/testrunner/run_build_test_target.py art-gtest-asan
Change-Id: I515c911bb7d44285495802fc66cd732fc8e6d8df
Diffstat (limited to 'compiler/optimizing/codegen_test_utils.h')
-rw-r--r-- | compiler/optimizing/codegen_test_utils.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/compiler/optimizing/codegen_test_utils.h b/compiler/optimizing/codegen_test_utils.h index 9fbd7d6fc0..9d15f1f294 100644 --- a/compiler/optimizing/codegen_test_utils.h +++ b/compiler/optimizing/codegen_test_utils.h @@ -313,25 +313,25 @@ static void RunCode(CodegenTargetConfig target_config, } #ifdef ART_ENABLE_CODEGEN_arm -CodeGenerator* create_codegen_arm_vixl32(HGraph* graph, const CompilerOptions& compiler_options) { +inline CodeGenerator* create_codegen_arm_vixl32(HGraph* graph, const CompilerOptions& compiler_options) { return new (graph->GetAllocator()) TestCodeGeneratorARMVIXL(graph, compiler_options); } #endif #ifdef ART_ENABLE_CODEGEN_arm64 -CodeGenerator* create_codegen_arm64(HGraph* graph, const CompilerOptions& compiler_options) { +inline CodeGenerator* create_codegen_arm64(HGraph* graph, const CompilerOptions& compiler_options) { return new (graph->GetAllocator()) TestCodeGeneratorARM64(graph, compiler_options); } #endif #ifdef ART_ENABLE_CODEGEN_x86 -CodeGenerator* create_codegen_x86(HGraph* graph, const CompilerOptions& compiler_options) { +inline CodeGenerator* create_codegen_x86(HGraph* graph, const CompilerOptions& compiler_options) { return new (graph->GetAllocator()) TestCodeGeneratorX86(graph, compiler_options); } #endif #ifdef ART_ENABLE_CODEGEN_x86_64 -CodeGenerator* create_codegen_x86_64(HGraph* graph, const CompilerOptions& compiler_options) { +inline CodeGenerator* create_codegen_x86_64(HGraph* graph, const CompilerOptions& compiler_options) { return new (graph->GetAllocator()) x86_64::CodeGeneratorX86_64(graph, compiler_options); } #endif |