[PATCH] D133926: [DebugInfo] Allow non-stack_value variadic expressions and use in DBG_INSTR_REF

Stephen Tozer via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 16 07:09:35 PDT 2023


StephenTozer added a comment.

In D133926#4591953 <https://reviews.llvm.org/D133926#4591953>, @fdeazeve wrote:

> Sorry to bump this review, but I'm currently investigating a couple of bugs which I believe are a result of this patch.
>
> One thing that seems off here is that now the definition of `isEntryValue` is incorrect:
>
>   bool DIExpression::isEntryValue() const {
>     return getNumElements() > 0 && getElement(0) == dwarf::DW_OP_LLVM_entry_value;
>   }
>
> Also note that the `CodeGen/AsmPrinter/DwarfExpression.cpp` code for `DwarfExpression::addExpression` doesn't expect an EntryValue as anything but the first operand of the op list.
>
> Still investigating how to handle those, but figured I'd give you a heads up in case you have ideas

I'll take a quick look - off the top of my head, there should be an interface to treat `!DIExpression(DW_OP_LLVM_arg, 0, <ops>)` identically to `!DIExpression(<ops>)`, and if it either doesn't exist or is only applicable to specific cases then it should be created/generalized.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D133926/new/

https://reviews.llvm.org/D133926



More information about the llvm-commits mailing list