diff options
| author | Evan Cheng <evan.cheng@apple.com> | 2008-08-30 09:09:33 +0000 |
|---|---|---|
| committer | Evan Cheng <evan.cheng@apple.com> | 2008-08-30 09:09:33 +0000 |
| commit | a3771d5bd9134a6f0c9115b20bf0e1875703b954 (patch) | |
| tree | 0fa49610895e34681610222e45742d1c20ff29fa /llvm/lib/CodeGen/SimpleRegisterCoalescing.h | |
| parent | 542ac629713189bb5b541492b8b95d5061b9a7c0 (diff) | |
| download | bcm5719-llvm-a3771d5bd9134a6f0c9115b20bf0e1875703b954.tar.gz bcm5719-llvm-a3771d5bd9134a6f0c9115b20bf0e1875703b954.zip | |
Re-apply 55467 with fix. If copy is being replaced by remat'ed def, transfer the implicit defs onto the remat'ed instruction.
llvm-svn: 55564
Diffstat (limited to 'llvm/lib/CodeGen/SimpleRegisterCoalescing.h')
| -rw-r--r-- | llvm/lib/CodeGen/SimpleRegisterCoalescing.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/SimpleRegisterCoalescing.h b/llvm/lib/CodeGen/SimpleRegisterCoalescing.h index bb21515a354..62738952aa2 100644 --- a/llvm/lib/CodeGen/SimpleRegisterCoalescing.h +++ b/llvm/lib/CodeGen/SimpleRegisterCoalescing.h @@ -96,6 +96,10 @@ namespace llvm { /// SmallPtrSet<MachineInstr*, 32> JoinedCopies; + /// ReMatCopies - Keep track of copies eliminated due to remat. + /// + SmallPtrSet<MachineInstr*, 32> ReMatCopies; + public: static char ID; // Pass identifcation, replacement for typeid SimpleRegisterCoalescing() : MachineFunctionPass((intptr_t)&ID) {} @@ -194,6 +198,9 @@ namespace llvm { bool RemoveCopyByCommutingDef(LiveInterval &IntA, LiveInterval &IntB, MachineInstr *CopyMI); + bool ReMaterializeTrivialDef(LiveInterval &SrcInt, unsigned DstReg, + MachineInstr *CopyMI); + /// TurnCopyIntoImpDef - If source of the specified copy is an implicit def, /// turn the copy into an implicit def. bool TurnCopyIntoImpDef(MachineBasicBlock::iterator &I, |

