summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm-exegesis/lib/X86.cpp
diff options
context:
space:
mode:
authorClement Courbet <courbet@google.com>2018-04-04 08:22:54 +0000
committerClement Courbet <courbet@google.com>2018-04-04 08:22:54 +0000
commit7949b3b1dcbdbd815dd28122871761f742b08278 (patch)
tree1adcd98e14a5ef1947a83f250bff3b6eac0af7c0 /llvm/tools/llvm-exegesis/lib/X86.cpp
parent7287b2c1ec669791df8b1c704e2457338f6bee47 (diff)
downloadbcm5719-llvm-7949b3b1dcbdbd815dd28122871761f742b08278.tar.gz
bcm5719-llvm-7949b3b1dcbdbd815dd28122871761f742b08278.zip
Revert r329156 "Add llvm-exegesis tool."
Breaks a bunch of bots. llvm-svn: 329157
Diffstat (limited to 'llvm/tools/llvm-exegesis/lib/X86.cpp')
-rw-r--r--llvm/tools/llvm-exegesis/lib/X86.cpp38
1 files changed, 0 insertions, 38 deletions
diff --git a/llvm/tools/llvm-exegesis/lib/X86.cpp b/llvm/tools/llvm-exegesis/lib/X86.cpp
deleted file mode 100644
index c9afece4a9f..00000000000
--- a/llvm/tools/llvm-exegesis/lib/X86.cpp
+++ /dev/null
@@ -1,38 +0,0 @@
-//===-- X86.cpp --------------------------------------------------*- C++-*-===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is distributed under the University of Illinois Open Source
-// License. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-#include "X86.h"
-
-namespace exegesis {
-
-static llvm::Error makeError(llvm::Twine Msg) {
- return llvm::make_error<llvm::StringError>(Msg,
- llvm::inconvertibleErrorCode());
-}
-
-X86Filter::~X86Filter() = default;
-
-// Test whether we can generate a snippet for this instruction.
-llvm::Error X86Filter::shouldRun(const LLVMState &State,
- const unsigned Opcode) const {
- const auto &InstrInfo = State.getInstrInfo();
- const llvm::MCInstrDesc &InstrDesc = InstrInfo.get(Opcode);
- if (InstrDesc.isBranch() || InstrDesc.isIndirectBranch())
- return makeError("Unsupported opcode: isBranch/isIndirectBranch");
- if (InstrDesc.isCall() || InstrDesc.isReturn())
- return makeError("Unsupported opcode: isCall/isReturn");
- const auto OpcodeName = InstrInfo.getName(Opcode);
- if (OpcodeName.startswith("POPF") || OpcodeName.startswith("PUSHF") ||
- OpcodeName.startswith("ADJCALLSTACK")) {
- return makeError("Unsupported opcode: Push/Pop/AdjCallStack");
- }
- return llvm::ErrorSuccess();
-}
-
-} // namespace exegesis
OpenPOWER on IntegriCloud