[llvm] e80605e - [X86] Remove WaitInsert::TTI member. NFCI.
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Thu Sep 10 03:45:19 PDT 2020
Author: Simon Pilgrim
Date: 2020-09-10T11:45:08+01:00
New Revision: e80605e2421f1fe09eb6f64f46dc65766c2d5184
URL: https://github.com/llvm/llvm-project/commit/e80605e2421f1fe09eb6f64f46dc65766c2d5184
DIFF: https://github.com/llvm/llvm-project/commit/e80605e2421f1fe09eb6f64f46dc65766c2d5184.diff
LOG: [X86] Remove WaitInsert::TTI member. NFCI.
This is only ever set/used inside WaitInsert::runOnMachineFunction so don't bother storing it in the class.
Added:
Modified:
llvm/lib/Target/X86/X86InsertWait.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Target/X86/X86InsertWait.cpp b/llvm/lib/Target/X86/X86InsertWait.cpp
index a82d98d88b30..56d2709f5937 100644
--- a/llvm/lib/Target/X86/X86InsertWait.cpp
+++ b/llvm/lib/Target/X86/X86InsertWait.cpp
@@ -27,7 +27,6 @@
#include "llvm/CodeGen/MachineInstr.h"
#include "llvm/CodeGen/MachineInstrBuilder.h"
#include "llvm/CodeGen/MachineOperand.h"
-#include "llvm/CodeGen/TargetInstrInfo.h"
#include "llvm/IR/DebugLoc.h"
#include "llvm/Support/Debug.h"
@@ -48,9 +47,6 @@ class WaitInsert : public MachineFunctionPass {
StringRef getPassName() const override {
return "X86 insert wait instruction";
}
-
-private:
- const TargetInstrInfo *TII; // Machine instruction info.
};
} // namespace
@@ -119,7 +115,7 @@ bool WaitInsert::runOnMachineFunction(MachineFunction &MF) {
return false;
const X86Subtarget &ST = MF.getSubtarget<X86Subtarget>();
- TII = ST.getInstrInfo();
+ const X86InstrInfo *TII = ST.getInstrInfo();
bool Changed = false;
for (MachineBasicBlock &MBB : MF) {
More information about the llvm-commits
mailing list