[llvm] r335233 - [CodeGen] Avoid handling DBG_VALUE in LiveRegUnits::stepBackward
Krzysztof Parzyszek via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 21 06:38:43 PDT 2018
Author: kparzysz
Date: Thu Jun 21 06:38:43 2018
New Revision: 335233
URL: http://llvm.org/viewvc/llvm-project?rev=335233&view=rev
Log:
[CodeGen] Avoid handling DBG_VALUE in LiveRegUnits::stepBackward
Patch by Jesper Antonsson.
Differential Revision: https://reviews.llvm.org/D48420
Modified:
llvm/trunk/lib/CodeGen/LiveRegUnits.cpp
Modified: llvm/trunk/lib/CodeGen/LiveRegUnits.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/LiveRegUnits.cpp?rev=335233&r1=335232&r2=335233&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/LiveRegUnits.cpp (original)
+++ llvm/trunk/lib/CodeGen/LiveRegUnits.cpp Thu Jun 21 06:38:43 2018
@@ -46,7 +46,7 @@ void LiveRegUnits::stepBackward(const Ma
// Remove defined registers and regmask kills from the set.
for (ConstMIBundleOperands O(MI); O.isValid(); ++O) {
if (O->isReg()) {
- if (!O->isDef())
+ if (!O->isDef() || O->isDebug())
continue;
unsigned Reg = O->getReg();
if (!TargetRegisterInfo::isPhysicalRegister(Reg))
@@ -58,7 +58,7 @@ void LiveRegUnits::stepBackward(const Ma
// Add uses to the set.
for (ConstMIBundleOperands O(MI); O.isValid(); ++O) {
- if (!O->isReg() || !O->readsReg())
+ if (!O->isReg() || !O->readsReg() || O->isDebug())
continue;
unsigned Reg = O->getReg();
if (!TargetRegisterInfo::isPhysicalRegister(Reg))
More information about the llvm-commits
mailing list