aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/MachineInstrBundle.cpp
diff options
context:
space:
mode:
authorBjorn Pettersson <bjorn.a.pettersson@ericsson.com>2018-08-25 10:02:03 +0000
committerBjorn Pettersson <bjorn.a.pettersson@ericsson.com>2018-08-25 10:02:03 +0000
commit8483004723f862684dadc97d0f26885487425a34 (patch)
tree748e8711a58e4153251e5e94dc02f0a71d1e747b /llvm/lib/CodeGen/MachineInstrBundle.cpp
parent353f67a741daa97e94bd402f6394c6d89fd8a987 (diff)
downloadllvm-8483004723f862684dadc97d0f26885487425a34.zip
llvm-8483004723f862684dadc97d0f26885487425a34.tar.gz
llvm-8483004723f862684dadc97d0f26885487425a34.tar.bz2
[LiveDebugVariables] Avoid faulty addDefsFromCopies in computeIntervals
Summary: When computeIntervals is looking through COPY instruction to extend the location mapping for a debug variable it did not handle subregisters correctly. For example DBG_VALUE debug-use %0.sub_8bit_hi, ... %1:gr16 = COPY %0 was transformed into DBG_VALUE debug-use %0.sub_8bit_hi, ... %1:gr16 = COPY %0 DBG_VALUE debug-use %1, ... So the subregister index was missing in the added DBG_VALUE. As long as the subreg refered to the least significant bits of the superreg, then I guess we could get the correct result in a debugger even when referring to the superreg. But as in the example above when the subreg refers to other parts of the superreg, then debuginfo would be incorrect. I'm not sure exactly how to fix this properly, so this patch just avoids looking through the COPY when there is a subreg involved (for more info, see the FIXME added in the code). Reviewers: rnk, aprantl Reviewed By: aprantl Subscribers: JDevlieghere, llvm-commits Tags: #debug-info Differential Revision: https://reviews.llvm.org/D50788 llvm-svn: 340679
Diffstat (limited to 'llvm/lib/CodeGen/MachineInstrBundle.cpp')
0 files changed, 0 insertions, 0 deletions