diff options
| author | Saleem Abdulrasool <compnerd@compnerd.org> | 2015-05-12 23:36:18 +0000 |
|---|---|---|
| committer | Saleem Abdulrasool <compnerd@compnerd.org> | 2015-05-12 23:36:18 +0000 |
| commit | ee13fbe848024543a34625f3229ca16c24cbcc5b (patch) | |
| tree | 1873712057809309e99529db02b2039817b92b09 /llvm/lib/CodeGen | |
| parent | 942fba95e297dc0a7158589d4f1d5a3250e06b20 (diff) | |
| download | bcm5719-llvm-ee13fbe848024543a34625f3229ca16c24cbcc5b.tar.gz bcm5719-llvm-ee13fbe848024543a34625f3229ca16c24cbcc5b.zip | |
CodeGen: ignore DEBUG_VALUE nodes in KILL tagging
DEBUG_VALUE nodes do not take part in code generation. Ignore them when
performing KILL updates. Addresses PR23486.
llvm-svn: 237211
Diffstat (limited to 'llvm/lib/CodeGen')
| -rw-r--r-- | llvm/lib/CodeGen/ScheduleDAGInstrs.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp b/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp index 583ed38f313..b4a34be759c 100644 --- a/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp +++ b/llvm/lib/CodeGen/ScheduleDAGInstrs.cpp @@ -1115,6 +1115,12 @@ static void toggleBundleKillFlag(MachineInstr *MI, unsigned Reg, if (!MO->isReg() || MO->isDef() || Reg != MO->getReg()) continue; + // DEBUG_VALUE nodes do not contribute to code generation and should + // always be ignored. Failure to do so may result in trying to modify + // KILL flags on DEBUG_VALUE nodes, which is distressing. + if (MO->isDebug()) + continue; + // If the register has the internal flag then it could be killing an // internal def of the register. In this case, just skip. We only want // to toggle the flag on operands visible outside the bundle. |

