[clang] Do not print locations in anonymous tag names. (PR #159592)
Shubham Sandeep Rastogi via cfe-commits
cfe-commits at lists.llvm.org
Fri Sep 19 11:16:52 PDT 2025
rastogishubham wrote:
Hi @dwblaikie
> Also - maybe compare to GCC's naming? (could be nice to converge, but I'm not sure that's possible/might be in tension with matching demangling)
We actually did compare to what GCC does, and you can see with this [compiler explorer link](https://godbolt.org/z/b6K43oazb) that GCC doesn't add the location to the DW_AT_name cc @Michael137 for the example (thanks for providing that!)
> Oh, and did you hit some particular problem with this varied naming situation? It's not immediately obvious to me that this would be a problem
Yes, we had an issue with dsymutil, we saw varifiction error in the DWARFVerifier when trying to verify the contents of the Accelerator tables. Since dsymutil does type uniquing similar to LTO.
> Any chance we could use a naming that matches/is similar to the mangling? Including the lambda numbering - could help ensure the names are unique-ish?
Correct me if I am wrong, but if we use the mangling, whats the difference between the DW_AT_name and the DW_AT_linkage_name?
https://github.com/llvm/llvm-project/pull/159592
More information about the cfe-commits
mailing list