[PATCH] D99900: [llvm] [testsuite] Fix invalid DW_AT_location DWARF expression in unattached-global.ll

David Blaikie via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 7 13:45:35 PDT 2021


dblaikie added a comment.

In D99900#2675024 <https://reviews.llvm.org/D99900#2675024>, @jankratochvil wrote:

> In D99900#2672711 <https://reviews.llvm.org/D99900#2672711>, @dblaikie wrote:
>
>> @aprantl @JDevlieghere do you folks want to update the verifier in any way to make this sort of thing invalid?
>
> Before implementing it into `DWARFExpression::verify` I see two issues:
>
> - IIUC the verifier would be run by `llvm-dwarfdump --verify` which is currently not being run.
> - The goal of this testcase is to omit `DW_AT_location` when producing the binary. Therefore the invalid DWARF expression would not be written out at all. So it could not be verified as incorrect by `llvm-dwarfdump`.

Sorry, I didn't mean dwarfdump verify (though that could be useful too), but the IR verifier (lib/IR/Verifier.cpp). If we're going to say that this IR is not good/supported by the backends, one thing we can do is make it invalid according to the verifier.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D99900



More information about the llvm-commits mailing list