summaryrefslogtreecommitdiff
path: root/lib/CodeGen/RegisterPressure.cpp
diff options
context:
space:
mode:
authorAndrew Trick <atrick@apple.com>2012-05-24 22:10:57 +0000
committerAndrew Trick <atrick@apple.com>2012-05-24 22:10:57 +0000
commita7de4b99e47fc5061181ecdf7fd65e1b8441e2e7 (patch)
tree383221bd30f33a710d0467c1c2f675a75ce4c9e3 /lib/CodeGen/RegisterPressure.cpp
parent28a5ab2fb43dd8274cc389d01b041408a4505d82 (diff)
downloadllvm-a7de4b99e47fc5061181ecdf7fd65e1b8441e2e7.tar.gz
llvm-a7de4b99e47fc5061181ecdf7fd65e1b8441e2e7.tar.bz2
llvm-a7de4b99e47fc5061181ecdf7fd65e1b8441e2e7.tar.xz
regpressure: physreg livein/out fix
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@157422 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/RegisterPressure.cpp')
-rw-r--r--lib/CodeGen/RegisterPressure.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/RegisterPressure.cpp b/lib/CodeGen/RegisterPressure.cpp
index b30f76d05d..0bdb19a776 100644
--- a/lib/CodeGen/RegisterPressure.cpp
+++ b/lib/CodeGen/RegisterPressure.cpp
@@ -356,7 +356,7 @@ void RegPressureTracker::addLiveRegs(ArrayRef<unsigned> Regs) {
/// Add PhysReg to the live in set and increase max pressure.
void RegPressureTracker::discoverPhysLiveIn(unsigned Reg) {
assert(!LivePhysRegs.count(Reg) && "avoid bumping max pressure twice");
- if (findRegAlias(Reg, P.LiveInRegs, TRI) == P.LiveInRegs.end())
+ if (findRegAlias(Reg, P.LiveInRegs, TRI) != P.LiveInRegs.end())
return;
// At live in discovery, unconditionally increase the high water mark.
@@ -367,7 +367,7 @@ void RegPressureTracker::discoverPhysLiveIn(unsigned Reg) {
/// Add PhysReg to the live out set and increase max pressure.
void RegPressureTracker::discoverPhysLiveOut(unsigned Reg) {
assert(!LivePhysRegs.count(Reg) && "avoid bumping max pressure twice");
- if (findRegAlias(Reg, P.LiveOutRegs, TRI) == P.LiveOutRegs.end())
+ if (findRegAlias(Reg, P.LiveOutRegs, TRI) != P.LiveOutRegs.end())
return;
// At live out discovery, unconditionally increase the high water mark.