[llvm] 88c1242 - [llvm-exegesis] Remove Assembler Tests
Aiden Grossman via llvm-commits
llvm-commits at lists.llvm.org
Sat May 13 02:00:30 PDT 2023
Author: Aiden Grossman
Date: 2023-05-13T08:56:58Z
New Revision: 88c1242ed7e1d82d0f681b5627e42e80b60dc9fe
URL: https://github.com/llvm/llvm-project/commit/88c1242ed7e1d82d0f681b5627e42e80b60dc9fe
DIFF: https://github.com/llvm/llvm-project/commit/88c1242ed7e1d82d0f681b5627e42e80b60dc9fe.diff
LOG: [llvm-exegesis] Remove Assembler Tests
The Assembler tests have been disabled for years in tree and at this
point don't test anything other than common MC infrastructure that is
already tested in other parts of the tree. This patch removes them due
to the mentioned reasons.
Reviewed By: courbet
Differential Revision: https://reviews.llvm.org/D149819
Added:
Modified:
llvm/unittests/tools/llvm-exegesis/CMakeLists.txt
llvm/unittests/tools/llvm-exegesis/X86/CMakeLists.txt
Removed:
llvm/unittests/tools/llvm-exegesis/ARM/AssemblerTest.cpp
llvm/unittests/tools/llvm-exegesis/ARM/CMakeLists.txt
llvm/unittests/tools/llvm-exegesis/X86/AssemblerTest.cpp
################################################################################
diff --git a/llvm/unittests/tools/llvm-exegesis/ARM/AssemblerTest.cpp b/llvm/unittests/tools/llvm-exegesis/ARM/AssemblerTest.cpp
deleted file mode 100644
index 85fafa0c435f4..0000000000000
--- a/llvm/unittests/tools/llvm-exegesis/ARM/AssemblerTest.cpp
+++ /dev/null
@@ -1,48 +0,0 @@
-//===-- AssemblerTest.cpp ---------------------------------------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#include "../Common/AssemblerUtils.h"
-#include "ARMInstrInfo.h"
-
-namespace llvm {
-namespace exegesis {
-namespace {
-
-class ARMMachineFunctionGeneratorTest
- : public MachineFunctionGeneratorBaseTest {
-protected:
- ARMMachineFunctionGeneratorTest()
- : MachineFunctionGeneratorBaseTest("armv7-none-linux-gnueabi", "") {}
-
- static void SetUpTestCase() {
- LLVMInitializeARMTargetInfo();
- LLVMInitializeARMTargetMC();
- LLVMInitializeARMTarget();
- LLVMInitializeARMAsmPrinter();
- }
-};
-
-TEST_F(ARMMachineFunctionGeneratorTest, DISABLED_JitFunction) {
- Check({}, MCInst(), 0x1e, 0xff, 0x2f, 0xe1);
-}
-
-TEST_F(ARMMachineFunctionGeneratorTest, DISABLED_JitFunctionADDrr) {
- Check({{ARM::R0, APInt()}},
- MCInstBuilder(ARM::ADDrr)
- .addReg(ARM::R0)
- .addReg(ARM::R0)
- .addReg(ARM::R0)
- .addImm(ARMCC::AL)
- .addReg(0)
- .addReg(0),
- 0x00, 0x00, 0x80, 0xe0, 0x1e, 0xff, 0x2f, 0xe1);
-}
-
-} // namespace
-} // namespace exegesis
-} // namespace llvm
diff --git a/llvm/unittests/tools/llvm-exegesis/ARM/CMakeLists.txt b/llvm/unittests/tools/llvm-exegesis/ARM/CMakeLists.txt
deleted file mode 100644
index 097a20d542d72..0000000000000
--- a/llvm/unittests/tools/llvm-exegesis/ARM/CMakeLists.txt
+++ /dev/null
@@ -1,19 +0,0 @@
-add_llvm_exegesis_unittest_includes(
- ${LLVM_MAIN_SRC_DIR}/lib/Target/ARM
- ${LLVM_BINARY_DIR}/lib/Target/ARM
- ${LLVM_MAIN_SRC_DIR}/tools/llvm-exegesis/lib
- )
-
-add_llvm_exegesis_unittest_link_components(
- Core
- MC
- MCParser
- Object
- Support
- Symbolize
- ARM
- )
-
-add_llvm_exegesis_unittest_sources(
- AssemblerTest.cpp
- )
diff --git a/llvm/unittests/tools/llvm-exegesis/CMakeLists.txt b/llvm/unittests/tools/llvm-exegesis/CMakeLists.txt
index f3fb01768ea1a..fa81c332cd8c9 100644
--- a/llvm/unittests/tools/llvm-exegesis/CMakeLists.txt
+++ b/llvm/unittests/tools/llvm-exegesis/CMakeLists.txt
@@ -43,9 +43,6 @@ endfunction()
if(LLVM_TARGETS_TO_BUILD MATCHES "X86")
include(X86/CMakeLists.txt)
endif()
-if(LLVM_TARGETS_TO_BUILD MATCHES "ARM")
- include(ARM/CMakeLists.txt)
-endif()
if(LLVM_TARGETS_TO_BUILD MATCHES "AArch64")
include(AArch64/CMakeLists.txt)
endif()
diff --git a/llvm/unittests/tools/llvm-exegesis/X86/AssemblerTest.cpp b/llvm/unittests/tools/llvm-exegesis/X86/AssemblerTest.cpp
deleted file mode 100644
index a2c30e9f5c653..0000000000000
--- a/llvm/unittests/tools/llvm-exegesis/X86/AssemblerTest.cpp
+++ /dev/null
@@ -1,65 +0,0 @@
-//===-- AssemblerTest.cpp ---------------------------------------*- C++ -*-===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#include "../Common/AssemblerUtils.h"
-#include "X86InstrInfo.h"
-
-namespace llvm {
-namespace exegesis {
-
-void InitializeX86ExegesisTarget();
-
-namespace {
-
-using X86::EAX;
-using X86::MOV32ri;
-using X86::MOV64ri32;
-using X86::RAX;
-using X86::XOR32rr;
-
-class X86MachineFunctionGeneratorTest
- : public MachineFunctionGeneratorBaseTest {
-protected:
- X86MachineFunctionGeneratorTest()
- : MachineFunctionGeneratorBaseTest("x86_64-unknown-linux", "haswell") {}
-
- static void SetUpTestCase() {
- LLVMInitializeX86TargetInfo();
- LLVMInitializeX86TargetMC();
- LLVMInitializeX86Target();
- LLVMInitializeX86AsmPrinter();
- InitializeX86ExegesisTarget();
- }
-};
-
-TEST_F(X86MachineFunctionGeneratorTest, DISABLED_JitFunction) {
- Check({}, MCInst(), 0xc3);
-}
-
-TEST_F(X86MachineFunctionGeneratorTest, DISABLED_JitFunctionXOR32rr_X86) {
- Check({{EAX, APInt(32, 1)}},
- MCInstBuilder(XOR32rr).addReg(EAX).addReg(EAX).addReg(EAX),
- // mov eax, 1
- 0xb8, 0x01, 0x00, 0x00, 0x00,
- // xor eax, eax
- 0x31, 0xc0, 0xc3);
-}
-
-TEST_F(X86MachineFunctionGeneratorTest, DISABLED_JitFunctionMOV64ri) {
- Check({}, MCInstBuilder(MOV64ri32).addReg(RAX).addImm(42), 0x48, 0xc7, 0xc0,
- 0x2a, 0x00, 0x00, 0x00, 0xc3);
-}
-
-TEST_F(X86MachineFunctionGeneratorTest, DISABLED_JitFunctionMOV32ri) {
- Check({}, MCInstBuilder(MOV32ri).addReg(EAX).addImm(42), 0xb8, 0x2a, 0x00,
- 0x00, 0x00, 0xc3);
-}
-
-} // namespace
-} // namespace exegesis
-} // namespace llvm
diff --git a/llvm/unittests/tools/llvm-exegesis/X86/CMakeLists.txt b/llvm/unittests/tools/llvm-exegesis/X86/CMakeLists.txt
index 9ce547ddaadbd..2ac3a1ae4dea4 100644
--- a/llvm/unittests/tools/llvm-exegesis/X86/CMakeLists.txt
+++ b/llvm/unittests/tools/llvm-exegesis/X86/CMakeLists.txt
@@ -5,7 +5,6 @@ add_llvm_exegesis_unittest_includes(
)
add_llvm_exegesis_unittest_sources(
- AssemblerTest.cpp
BenchmarkResultTest.cpp
RegisterAliasingTest.cpp
SchedClassResolutionTest.cpp
More information about the llvm-commits
mailing list