[PATCH] D43427: [RegAllocFast] Salvage debug values when killing operands (WIP)

Vedant Kumar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Feb 16 19:00:40 PST 2018


vsk created this revision.
vsk added reviewers: aprantl, MatzeB, thegameg.
vsk added a project: debug-info.
Herald added a subscriber: qcolombet.

Teach the fast register allocator to update DBG_VALUE instructions when
it reloads a vreg.

Specifically, when regalloc finds that it can kill a machine operand, go
point the DBG_VALUE uses of that operand to a replacement vreg. Update
LiveDbgValuesMap as needed.

This is a work-in-progress patch. I've never touched this part of llvm
so I'd like to get some review feedback about the general approach I've
taken. This patch also needs more testing. I've run stage2 builds of opt
at `-O0 -g` and `-Os -g` with this patch applied without issue. However
the test case doesn't cover all of the source changes.


https://reviews.llvm.org/D43427

Files:
  include/llvm/CodeGen/MachineRegisterInfo.h
  lib/CodeGen/MachineRegisterInfo.cpp
  lib/CodeGen/RegAllocFast.cpp
  test/CodeGen/X86/salvage-dbg-val-regallocfast.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D43427.134783.patch
Type: text/x-patch
Size: 12400 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180217/c2cc8157/attachment.bin>


More information about the llvm-commits mailing list