[all-commits] [llvm/llvm-project] 7d77bb: [DebugInfo][RemoveDIs] Add prototype storage class...

Jeremy Morse via All-commits all-commits at lists.llvm.org
Thu Nov 2 05:45:21 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 7d77bbef4ad9230f6f427649373fe46a668aa909
      https://github.com/llvm/llvm-project/commit/7d77bbef4ad9230f6f427649373fe46a668aa909
  Author: Jeremy Morse <jeremy.morse at sony.com>
  Date:   2023-11-02 (Thu, 02 Nov 2023)

  Changed paths:
    M llvm/include/llvm/IR/BasicBlock.h
    M llvm/include/llvm/IR/DebugInfoMetadata.h
    A llvm/include/llvm/IR/DebugProgramInstruction.h
    M llvm/include/llvm/IR/Function.h
    M llvm/include/llvm/IR/Instruction.h
    M llvm/include/llvm/IR/Metadata.h
    M llvm/include/llvm/IR/Module.h
    M llvm/lib/IR/BasicBlock.cpp
    M llvm/lib/IR/CMakeLists.txt
    M llvm/lib/IR/DebugInfoMetadata.cpp
    A llvm/lib/IR/DebugProgramInstruction.cpp
    M llvm/lib/IR/Function.cpp
    M llvm/lib/IR/LLVMContextImpl.cpp
    M llvm/lib/IR/LLVMContextImpl.h
    M llvm/lib/IR/Metadata.cpp
    M llvm/lib/IR/Module.cpp
    M llvm/lib/IR/Verifier.cpp
    M llvm/lib/Linker/IRMover.cpp
    M llvm/lib/Target/AMDGPU/AMDGPURewriteOutArguments.cpp
    M llvm/lib/Transforms/IPO/ArgumentPromotion.cpp
    M llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp
    M llvm/lib/Transforms/Utils/CloneFunction.cpp
    M llvm/unittests/IR/DebugInfoTest.cpp
    M llvm/unittests/Transforms/Utils/LocalTest.cpp
    M llvm/utils/gn/secondary/llvm/lib/IR/BUILD.gn

  Log Message:
  -----------
  [DebugInfo][RemoveDIs] Add prototype storage classes for "new" debug-info

This patch adds a variety of classes needed to record variable location
debug-info without using the existing intrinsic approach, see the rationale
at [0].

The two added files and corresponding unit tests are the majority of the
plumbing required for this, but at this point isn't accessible from the
rest of LLVM as we need to stage it into the repo gently. An overview is
that classes are added for recording variable information attached to Real
(TM) instructions, in the form of DPValues and DPMarker objects. The
metadata-uses of DPValues is plumbed into the metadata hierachy, and a
field added to class Instruction, which are all stimulated in the unit
tests. The next few patches in this series add utilities to convert to/from
this new debug-info format and add instruction/block utilities to have
debug-info automatically updated in the background when various operations
occur.

This patch was reviewed in Phab in D153990 and D154080, I've squashed them
together into this commit as there are dependencies between the two
patches, and there's little profit in landing them separately.

[0] https://discourse.llvm.org/t/rfc-instruction-api-changes-needed-to-eliminate-debug-intrinsics-from-ir/68939




More information about the All-commits mailing list