[PATCH] D112636: [DWARF] Adjust DW_AT_name/DW_AT_linkage_name checks

David Blaikie via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 27 14:46:55 PDT 2021


dblaikie accepted this revision.
dblaikie added a comment.
This revision is now accepted and ready to land.

I'd be OK with this patch as-is, but if you're up for some other cleanup some tests might be able to be changed to not use `-v`, and those that can't could probably be a bit more standardized/made more consistent by dropping the sometimes-present trailing `)` (since it's unmatched anyway (being consumed by the regex) I think it reduces readability) and including a space between the tag name and the regex in all these cases/consistently.



================
Comment at: llvm/test/DebugInfo/Generic/PR20038.ll:4
 
 ; RUN: %llc_dwarf -O0 -filetype=obj -dwarf-linkage-names=All < %s | llvm-dwarfdump -v -debug-info - | FileCheck %s
 
----------------
Some tests may be simplified by removing `-v` if the test isn't trying to test particular forms/encodings - that way you wouldn't need the `{{.*}}` either, since the non-verbose form doesn't print the encoding information (you'd need to add `()` around the string instead, possibly, though).


================
Comment at: llvm/test/DebugInfo/Generic/containing-type-extension.ll:8
 ; CHECK: DW_AT_containing_type [DW_FORM_ref4]
-; CHECK: DW_AT_name {{.*}}= "vtable")
+; CHECK: DW_AT_name {{.*}}"vtable")
 
----------------
Could you drop trailing `)` from cases like this too?


================
Comment at: llvm/test/DebugInfo/Generic/namespace.ll:19
 ; CHECK: [[FOO:0x[0-9a-f]*]]:{{ *}}DW_TAG_structure_type
-; CHECK-NEXT: DW_AT_name{{.*}}= "foo"
+; CHECK-NEXT: DW_AT_name{{.*}}"foo"
 ; CHECK-NEXT: DW_AT_declaration
----------------
Might be worth standardizing on including a space between `DW_AT_name` and the `{{...` part.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D112636



More information about the llvm-commits mailing list