[all-commits] [llvm/llvm-project] 35f4ef: [SelectionDAG][DebugInfo] Handle entry_value dbg.v...

Felipe de Azevedo Piovezan via All-commits all-commits at lists.llvm.org
Thu Aug 24 06:34:21 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 35f4ef1feeeb007a0e57fa2cbc64502ee8863e4d
      https://github.com/llvm/llvm-project/commit/35f4ef1feeeb007a0e57fa2cbc64502ee8863e4d
  Author: Felipe de Azevedo Piovezan <fpiovezan at apple.com>
  Date:   2023-08-24 (Thu, 24 Aug 2023)

  Changed paths:
    M llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
    M llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h
    A llvm/test/CodeGen/AArch64/dbg-value-swift-async-non-entry-block.ll

  Log Message:
  -----------
  [SelectionDAG][DebugInfo] Handle entry_value dbg.value DIExprs earlier

When SelectiondDAG converts dbg.value intrinsics, it first ensures we have
already generated code for the value operator of the intrinsic. The rationale
being that if we haven't had the need to generate code for this value, it won't
be a debug value that causes the generation.

For example, if the first use the physical register of an argument is a
dbg.value, we are going to hit this code path.  However, this is irrelevant for
entry value expressions: by definition we are not interested in the _current_
value of the physical register, but rather on its value at the start of the
function. To deal with this, this patch changes lowering to handle this case as
early as possible.

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




More information about the All-commits mailing list