[llvm] r251848 - [PPC64LE] Properly initialize instr-info in PPCVSXSwapRemoval pass
Bill Schmidt via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 2 14:43:57 PST 2015
Author: wschmidt
Date: Mon Nov 2 16:43:57 2015
New Revision: 251848
URL: http://llvm.org/viewvc/llvm-project?rev=251848&view=rev
Log:
[PPC64LE] Properly initialize instr-info in PPCVSXSwapRemoval pass
Replace some hacky code with the proper way to get at this data.
No functional change.
Modified:
llvm/trunk/lib/Target/PowerPC/PPCVSXSwapRemoval.cpp
Modified: llvm/trunk/lib/Target/PowerPC/PPCVSXSwapRemoval.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/PowerPC/PPCVSXSwapRemoval.cpp?rev=251848&r1=251847&r2=251848&view=diff
==============================================================================
--- llvm/trunk/lib/Target/PowerPC/PPCVSXSwapRemoval.cpp (original)
+++ llvm/trunk/lib/Target/PowerPC/PPCVSXSwapRemoval.cpp Mon Nov 2 16:43:57 2015
@@ -220,7 +220,7 @@ public:
void PPCVSXSwapRemoval::initialize(MachineFunction &MFParm) {
MF = &MFParm;
MRI = &MF->getRegInfo();
- TII = static_cast<const PPCInstrInfo*>(MF->getSubtarget().getInstrInfo());
+ TII = MF->getSubtarget<PPCSubtarget>().getInstrInfo();
// An initial vector size of 256 appears to work well in practice.
// Small/medium functions with vector content tend not to incur a
More information about the llvm-commits
mailing list