[all-commits] [llvm/llvm-project] ee5059: [DebugInfo] MachineSink: Insert undef DBG_VALUEs w...

Jeremy Morse via All-commits all-commits at lists.llvm.org
Mon Oct 28 05:20:00 PDT 2019


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: ee50590e1684c197bc4336984795e48bf53c7a4e
      https://github.com/llvm/llvm-project/commit/ee50590e1684c197bc4336984795e48bf53c7a4e
  Author: Jeremy Morse <jeremy.morse at sony.com>
  Date:   2019-10-28 (Mon, 28 Oct 2019)

  Changed paths:
    M llvm/lib/CodeGen/MachineSink.cpp
    M llvm/test/DebugInfo/MIR/X86/postra-subreg-sink.mir
    A llvm/test/DebugInfo/MIR/X86/sink-leaves-undef.mir

  Log Message:
  -----------
  [DebugInfo] MachineSink: Insert undef DBG_VALUEs when sinking instructions

When we sink DBG_VALUEs between blocks, we simply move the DBG_VALUE
instruction to below the sunk instruction. However, we should also mark
the variable as being undef at the original location, to terminate any
earlier variable location. This patch does that -- plus, if the
instruction being sunk is a copy, it attempts to propagate the copy
through the DBG_VALUE, replacing the destination with the source.

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




More information about the All-commits mailing list