mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-28 00:07:22 +00:00
Give SplitAnalysis a VRM member to access VirtRegMap::getOriginal().
llvm-svn: 126005
This commit is contained in:
parent
4652f152e4
commit
e2833bf683
@ -1266,7 +1266,7 @@ bool RAGreedy::runOnMachineFunction(MachineFunction &mf) {
|
||||
Bundles = &getAnalysis<EdgeBundles>();
|
||||
SpillPlacer = &getAnalysis<SpillPlacement>();
|
||||
|
||||
SA.reset(new SplitAnalysis(*MF, *LIS, *Loops));
|
||||
SA.reset(new SplitAnalysis(*VRM, *LIS, *Loops));
|
||||
|
||||
allocatePhysRegs();
|
||||
addMBBLiveIns(MF);
|
||||
|
@ -37,13 +37,14 @@ AllowSplit("spiller-splits-edges",
|
||||
// Split Analysis
|
||||
//===----------------------------------------------------------------------===//
|
||||
|
||||
SplitAnalysis::SplitAnalysis(const MachineFunction &mf,
|
||||
SplitAnalysis::SplitAnalysis(const VirtRegMap &vrm,
|
||||
const LiveIntervals &lis,
|
||||
const MachineLoopInfo &mli)
|
||||
: MF(mf),
|
||||
: MF(vrm.getMachineFunction()),
|
||||
VRM(vrm),
|
||||
LIS(lis),
|
||||
Loops(mli),
|
||||
TII(*mf.getTarget().getInstrInfo()),
|
||||
TII(*MF.getTarget().getInstrInfo()),
|
||||
CurLI(0) {}
|
||||
|
||||
void SplitAnalysis::clear() {
|
||||
|
@ -43,6 +43,7 @@ typedef DomTreeNodeBase<MachineBasicBlock> MachineDomTreeNode;
|
||||
class SplitAnalysis {
|
||||
public:
|
||||
const MachineFunction &MF;
|
||||
const VirtRegMap &VRM;
|
||||
const LiveIntervals &LIS;
|
||||
const MachineLoopInfo &Loops;
|
||||
const TargetInstrInfo &TII;
|
||||
@ -105,7 +106,7 @@ private:
|
||||
bool canAnalyzeBranch(const MachineBasicBlock *MBB);
|
||||
|
||||
public:
|
||||
SplitAnalysis(const MachineFunction &mf, const LiveIntervals &lis,
|
||||
SplitAnalysis(const VirtRegMap &vrm, const LiveIntervals &lis,
|
||||
const MachineLoopInfo &mli);
|
||||
|
||||
/// analyze - set CurLI to the specified interval, and analyze how it may be
|
||||
|
Loading…
x
Reference in New Issue
Block a user