<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - DW_AT_name for DW_TAG_label removes one leading underscore from the symbol name"
   href="https://bugs.llvm.org/show_bug.cgi?id=37470">37470</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>DW_AT_name for DW_TAG_label removes one leading underscore from the symbol name
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>libraries
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>trunk
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>enhancement
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>MC
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>dimitry@google.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>This is kind of confusing because there is no way to say when it was removed.
Also I was trying to find if it should be removed and it does not seem there is
anything saying that.

Here is the resulted dwarf for bionic _exit.S file:

$ readelf -wai
out/soong/.intermediates/bionic/libc/libc_syscalls/android_arm_armv8-a_cortex-a73_core_static/obj/bionic/libc/arch-arm/syscalls/_exit.o
Contents of the .debug_info section:

  Compilation Unit @ offset 0x0:
   Length:        0x168 (32-bit)
   Version:       4
   Abbrev Offset: 0x0
   Pointer Size:  4
 <0><b>: Abbrev Number: 1 (DW_TAG_compile_unit)
    <c>   DW_AT_stmt_list   : 0x0
    <10>   DW_AT_low_pc      : 0x0
    <14>   DW_AT_high_pc     : 0x20
    <18>   DW_AT_name        : bionic/libc/arch-arm/syscalls/_exit.S
    <3e>   DW_AT_comp_dir    : /proc/self/cwd
    <4d>   DW_AT_producer    : Android (4679922 based on r326829) clang version
7.0.1 (<a href="https://android.googlesource.com/toolchain/clang">https://android.googlesource.com/toolchain/clang</a>
32fb8450f65708b63c9a35046b2d1ee775e08733)
(<a href="https://android.googlesource.com/toolchain/llvm">https://android.googlesource.com/toolchain/llvm</a>
67f3e6a51d93777841e0fb6d07f71fdf343df239) (based on LLVM 7.0.1svn)
    <154>   DW_AT_language    : 32769   (MIPS assembler)
 <1><156>: Abbrev Number: 2 (DW_TAG_label)
    <157>   DW_AT_name        : exit
    <15c>   DW_AT_decl_file   : 0x1
    <160>   DW_AT_decl_line   : 0x14
    <164>   DW_AT_low_pc      : 0x0
    <168>   DW_AT_prototyped  : 0
 <2><169>: Abbrev Number: 3 (DW_TAG_unspecified_parameters)
 <2><16a>: Abbrev Number: 0
 <1><16b>: Abbrev Number: 0

Contents of the .debug_abbrev section:

  Number TAG (0x0)
   1      DW_TAG_compile_unit    [has children]
    DW_AT_stmt_list    DW_FORM_sec_offset
    DW_AT_low_pc       DW_FORM_addr
    DW_AT_high_pc      DW_FORM_addr
    DW_AT_name         DW_FORM_string
    DW_AT_comp_dir     DW_FORM_string
    DW_AT_producer     DW_FORM_string
    DW_AT_language     DW_FORM_data2
    DW_AT value: 0     DW_FORM value: 0
   2      DW_TAG_label    [has children]
    DW_AT_name         DW_FORM_string
    DW_AT_decl_file    DW_FORM_data4
    DW_AT_decl_line    DW_FORM_data4
    DW_AT_low_pc       DW_FORM_addr
    DW_AT_prototyped   DW_FORM_flag
    DW_AT value: 0     DW_FORM value: 0
   3      DW_TAG_unspecified_parameters    [no children]
    DW_AT value: 0     DW_FORM value: 0

The expected DW_AT_name here is "_exit" because this is the name used for the
exported symbol.</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>