diff options
| author | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2009-11-07 01:58:40 +0000 |
|---|---|---|
| committer | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2009-11-07 01:58:40 +0000 |
| commit | 3de23e6f6cf337451a0934159da494d645b93133 (patch) | |
| tree | e37b7e58258130f06e5f359cc760e4c24287d30e /include | |
| parent | 12d53dba36905d20b02cf7c4cdae057ae4a5a5e1 (diff) | |
| download | external_llvm-3de23e6f6cf337451a0934159da494d645b93133.zip external_llvm-3de23e6f6cf337451a0934159da494d645b93133.tar.gz external_llvm-3de23e6f6cf337451a0934159da494d645b93133.tar.bz2 | |
Fix inverted conflict test in -early-coalesce.
A non-identity copy cannot be coalesced when the phi join destination register
is live at the copy site.
Also verify the condition that the PHI join source register is only used in
the PHI join. Otherwise the coalescing is invalid.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86322 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
| -rw-r--r-- | include/llvm/CodeGen/LiveIntervalAnalysis.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/include/llvm/CodeGen/LiveIntervalAnalysis.h b/include/llvm/CodeGen/LiveIntervalAnalysis.h index efb4a03..d71f960 100644 --- a/include/llvm/CodeGen/LiveIntervalAnalysis.h +++ b/include/llvm/CodeGen/LiveIntervalAnalysis.h @@ -290,9 +290,10 @@ namespace llvm { /// computeIntervals - Compute live intervals. void computeIntervals(); - bool isProfitableToCoalesce(LiveInterval &DstInt, LiveInterval &SrcInt, - SmallVector<MachineInstr*,16> &IdentCopies, - SmallVector<MachineInstr*,16> &OtherCopies); + bool isSafeAndProfitableToCoalesce(LiveInterval &DstInt, + LiveInterval &SrcInt, + SmallVector<MachineInstr*,16> &IdentCopies, + SmallVector<MachineInstr*,16> &OtherCopies); void performEarlyCoalescing(); |
