[DEBUGINFO] Reposting r352642: Handle restore instructions in LiveDebugValues
authorWolfgang Pieb <Wolfgang.Pieb@sony.com>
Mon, 4 Feb 2019 20:42:45 +0000 (20:42 +0000)
committerWolfgang Pieb <Wolfgang.Pieb@sony.com>
Mon, 4 Feb 2019 20:42:45 +0000 (20:42 +0000)
commit90d856cd5f4c4bfe415105f6bfc66f05457a334d
tree22d5f7196beed92b2db40456b05d30d86d00ed99
parent690a20467b6684edb49f6f23a594e4649e8626a6
[DEBUGINFO] Reposting r352642: Handle restore instructions in LiveDebugValues

The LiveDebugValues pass recognizes spills but not restores, which can
cause large gaps in location information for some variables, depending
on control flow. This patch make LiveDebugValues recognize restores and
generate appropriate DBG_VALUE instructions.

This patch was posted previously with r352642 and reverted in r352666 due
to buildbot errors. A missing return statement was the cause for the
failures.

Reviewers: aprantl, NicolaPrica

Differential Revision: https://reviews.llvm.org/D57271

llvm-svn: 353089
llvm/include/llvm/CodeGen/MachineInstr.h
llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
llvm/lib/CodeGen/LiveDebugValues.cpp
llvm/lib/CodeGen/MachineInstr.cpp
llvm/test/DebugInfo/MIR/X86/live-debug-values-restore.mir [new file with mode: 0644]