summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
diff options
context:
space:
mode:
authorMatthias Braun <matze@braunis.de>2017-06-27 00:58:48 +0000
committerMatthias Braun <matze@braunis.de>2017-06-27 00:58:48 +0000
commite2ae00198231f8242a73a67ea9579ad2b8d172ca (patch)
tree165917e179b9fa803772376bb16a5f10e535b0ef /llvm/lib/CodeGen
parent604c003f5ffbc52604a03253fd57b2f3a361f4f9 (diff)
downloadbcm5719-llvm-e2ae00198231f8242a73a67ea9579ad2b8d172ca.tar.gz
bcm5719-llvm-e2ae00198231f8242a73a67ea9579ad2b8d172ca.zip
ScheduleDAGInstrs: Fix fixupKills() adding too many kill flags.
Remove invalid shortcut in fixupKills(): A register needs to be marked live even when we are not adding a kill flag. This is because a partially live register must not get a kill flags, but it still needs to be fully marked live when walking backwards. llvm-svn: 306352
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r--llvm/lib/CodeGen/ScheduleDAGInstrs.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp b/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp
index 7dd66d799be..0f70b0e9ca0 100644
--- a/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp
+++ b/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp
@@ -1089,7 +1089,7 @@ static void toggleKills(const MachineRegisterInfo &MRI, LivePhysRegs &LiveRegs,
// Things that are available after the instruction are killed by it.
bool IsKill = LiveRegs.available(MRI, Reg);
MO.setIsKill(IsKill);
- if (IsKill && addToLiveRegs)
+ if (addToLiveRegs)
LiveRegs.addReg(Reg);
}
}
OpenPOWER on IntegriCloud