[all-commits] [llvm/llvm-project] 98a021: [DebugInfo] Attempt to preserve more information d...

Stephen Tozer via All-commits all-commits at lists.llvm.org
Fri Dec 3 07:31:03 PST 2021

  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 98a021fcbfe104f98c7b67c35af4bbbccc3c1b8f
  Author: Stephen Tozer <stephen.tozer at sony.com>
  Date:   2021-12-03 (Fri, 03 Dec 2021)

  Changed paths:
    M llvm/include/llvm/CodeGen/MachineSSAUpdater.h
    M llvm/lib/CodeGen/MachineSSAUpdater.cpp
    M llvm/lib/CodeGen/TailDuplicator.cpp
    M llvm/test/CodeGen/X86/tail-dup-debugvalue.mir

  Log Message:
  [DebugInfo] Attempt to preserve more information during tail duplication

Prior to this patch, tail duplication handled debug info poorly -
specifically, debug instructions would be dropped instead of being set
undef, potentially extending the lifetimes of prior debug values that
should be killed. The pass was also very aggressive with dropping debug
info, dropping debug info even when the SSA value it referred to was
still present. This patch attempts to handle debug info more carefully,
checking to see whether each affected debug value can still be live,
setting it undef if not.

Reviewed By: jmorse

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

More information about the All-commits mailing list