diff options
author | Jeremy Morse <jeremy.morse@sony.com> | 2021-11-24 10:20:03 +0000 |
---|---|---|
committer | Jeremy Morse <jeremy.morse@sony.com> | 2021-11-24 10:34:48 +0000 |
commit | b8f68ad9cdb11d585acc6c38ad124b32efb6178a (patch) | |
tree | d4e46b155017a6233311b423d64a0eb389d0190f /lldb/packages/Python/lldbsuite/test/lldbutil.py | |
parent | d9af9c2c5a53c9ba6aa0255240a2a40e8bea27aa (diff) | |
download | llvm-b8f68ad9cdb11d585acc6c38ad124b32efb6178a.zip llvm-b8f68ad9cdb11d585acc6c38ad124b32efb6178a.tar.gz llvm-b8f68ad9cdb11d585acc6c38ad124b32efb6178a.tar.bz2 |
[DebugInfo][InstrRef] Avoid crash when values optimised out late in sdag
It appears that we can emit all the instructions for a function, including
debug instructions, and then optimise some of the values out late.
Specifically, in the attached test case, an argument gets optimised out
after DBG_VALUE / DBG_INSTR_REFs are created. This confuses
MachineFunction::finalizeDebugInstrRefs, which expects to be able to find a
defining instruction, and crashes instead.
Fix this by identifying when there's no defining instruction, and
translating that instead into a DBG_VALUE $noreg.
Differential Revision: https://reviews.llvm.org/D114476
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/lldbutil.py')
0 files changed, 0 insertions, 0 deletions