diff options
author | 2020-07-01 13:40:19 +0100 | |
---|---|---|
committer | 2020-07-10 10:57:04 +0000 | |
commit | 8070443ce4b31a6787c22490f18f838f8f6ed4be (patch) | |
tree | ca9952b599e81570b60a0b1d403316de45d3f340 /compiler/utils/assembler_test_base.h | |
parent | 60690e495c3d6ead778bc25c44e925c5fd66173f (diff) |
Switch to LLVM prebuilt tools for ART gtests
It is also necessary to adjust the expected output of some tests.
Bug: 147817558
Test: m test-art-host-gtest
Change-Id: Ib517169614470193e0c55f566adb72a526ae6902
Diffstat (limited to 'compiler/utils/assembler_test_base.h')
-rw-r--r-- | compiler/utils/assembler_test_base.h | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/compiler/utils/assembler_test_base.h b/compiler/utils/assembler_test_base.h index 1567367b67..736a292667 100644 --- a/compiler/utils/assembler_test_base.h +++ b/compiler/utils/assembler_test_base.h @@ -135,22 +135,24 @@ class AssemblerTestBase : public testing::Test { } virtual std::vector<std::string> GetAssemblerCommand() { - switch (GetIsa()) { + InstructionSet isa = GetIsa(); + switch (isa) { case InstructionSet::kX86: - return {FindTool("as"), "--32"}; + return {FindTool("clang"), "--compile", "-target", "i386-linux-gnu"}; case InstructionSet::kX86_64: - return {FindTool("as"), "--64"}; + return {FindTool("clang"), "--compile", "-target", "x86_64-linux-gnu"}; default: - return {FindTool("as")}; + LOG(FATAL) << "Unknown instruction set: " << isa; + UNREACHABLE(); } } virtual std::vector<std::string> GetDisassemblerCommand() { switch (GetIsa()) { case InstructionSet::kThumb2: - return {FindTool("objdump"), "--disassemble", "-M", "force-thumb"}; + return {FindTool("llvm-objdump"), "--disassemble", "-triple", "thumbv7a-linux-gnueabi"}; default: - return {FindTool("objdump"), "--disassemble", "--no-show-raw-insn"}; + return {FindTool("llvm-objdump"), "--disassemble", "--no-show-raw-insn"}; } } |