[PATCH] D126835: Round up zero-sized symbols to 1 byte in `.debug_aranges` (without breaking other logic).

Alexander Yermolovich via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 22 10:33:37 PDT 2022


ayermolo added a comment.

In D126835#3602110 <https://reviews.llvm.org/D126835#3602110>, @dblaikie wrote:

> In D126835#3601856 <https://reviews.llvm.org/D126835#3601856>, @ayermolo wrote:
>
>> In D126835#3600910 <https://reviews.llvm.org/D126835#3600910>, @dblaikie wrote:
>>
>>> In D126835#3600547 <https://reviews.llvm.org/D126835#3600547>, @ayermolo wrote:
>>>
>>>> In D126835#3600524 <https://reviews.llvm.org/D126835#3600524>, @dblaikie wrote:
>>>>
>>>>> Looks like this would be another issue with zero-length symbols: https://reviews.llvm.org/D127897 (just cross-referencing/collating)
>>>>
>>>> Well it's an issue right now even without this change.
>>>
>>> Sorry, what I meant is: This issue (D126835 <https://reviews.llvm.org/D126835>) and the other (D127897 <https://reviews.llvm.org/D127897>) would probably both be better-off solved by changing the compiler/LLVM to never produce zero-length entries.
>>
>> Oh I see.
>> Some more context. Debug info that D127897 <https://reviews.llvm.org/D127897> is handling is coming from GCC.
>
> Oh, that surprises me - could you provide repro steps?



  int conv32(const void* ptr) { return *(const int *) ptr; }
  
  int foo(const void* ptr) {
    return conv32(ptr) + 2;
  }

gcc -g -gstrict-dwarf -gz=none -O3 helper.cpp -c
Version  11.2.1


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D126835



More information about the llvm-commits mailing list