diff options
author | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2010-12-17 23:16:35 +0000 |
---|---|---|
committer | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2010-12-17 23:16:35 +0000 |
commit | 2e98ee31b3c013dff3cbffa2a2b8a885ec18b2cb (patch) | |
tree | a7a09087207c755c6057b0b01a3ede9ee41331bb /llvm/lib/CodeGen/RegAllocGreedy.cpp | |
parent | 1740e00104f99109be0733d7caa044f58d8f8de1 (diff) | |
download | bcm5719-llvm-2e98ee31b3c013dff3cbffa2a2b8a885ec18b2cb.tar.gz bcm5719-llvm-2e98ee31b3c013dff3cbffa2a2b8a885ec18b2cb.zip |
Make the -verify-regalloc command line option available to base classes as
RegAllocBase::VerifyEnabled.
Run the machine code verifier in a few interesting places during RegAllocGreedy.
llvm-svn: 122107
Diffstat (limited to 'llvm/lib/CodeGen/RegAllocGreedy.cpp')
-rw-r--r-- | llvm/lib/CodeGen/RegAllocGreedy.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/RegAllocGreedy.cpp b/llvm/lib/CodeGen/RegAllocGreedy.cpp index d8c1b3d4da5..8dbb56809bf 100644 --- a/llvm/lib/CodeGen/RegAllocGreedy.cpp +++ b/llvm/lib/CodeGen/RegAllocGreedy.cpp @@ -328,6 +328,9 @@ unsigned RAGreedy::trySplit(LiveInterval &VirtReg, AllocationOrder &Order, SplitEditor(*SA, *LIS, *VRM, *DomTree, LREdit) .splitAroundLoop(Loop->getLoop()); + if (VerifyEnabled) + MF->verify(this); + // We have new split regs, don't assign anything. return 0; } @@ -400,6 +403,9 @@ bool RAGreedy::runOnMachineFunction(MachineFunction &mf) { << ((Value*)mf.getFunction())->getName() << '\n'); MF = &mf; + if (VerifyEnabled) + MF->verify(this); + RegAllocBase::init(getAnalysis<VirtRegMap>(), getAnalysis<LiveIntervals>()); DomTree = &getAnalysis<MachineDominatorTree>(); ReservedRegs = TRI->getReservedRegs(*MF); |