[llvm-bugs] [Bug 27985] New: all DWARF DW_AT_name generation are wrong for ARM

via llvm-bugs llvm-bugs at lists.llvm.org
Thu Jun 2 17:04:17 PDT 2016


https://llvm.org/bugs/show_bug.cgi?id=27985

            Bug ID: 27985
           Summary: all DWARF DW_AT_name generation are wrong for ARM
           Product: tools
           Version: trunk
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P
         Component: llvm-as
          Assignee: unassignedbugs at nondot.org
          Reporter: yinma at codeaurora.org
                CC: llvm-bugs at lists.llvm.org
    Classification: Unclassified

Use any hello world .c , such as

int foo(char* ccc) {
  char aaa[10];
  aaa[1] = ccc[2];
  return aaa[1];
}

clang  -c -target arm -O0 -g t.c
dwarfdump -i t.o

We can see 
.debug_info

COMPILE_UNIT<header overall offset = 0x00000000>:
< 0><0x0000000b>  DW_TAG_compile_unit
                    DW_AT_producer              "clang version 3.9.0
(http://llvm.org/git/clang.git 3d996e269b2a4c446a67d89d9d8b1c510168169b)
(http://llvm.org/git/llvm.git c27d8b42ef187b39e289d916599f694cc9796302)"
                    DW_AT_language              DW_LANG_C99
                    DW_AT_name                  "clang version 3.9.0
(http://llvm.org/git/clang.git 3d996e269b2a4c446a67d89d9d8b1c510168169b)
(http://llvm.org/git/llvm.git c27d8b42ef187b39e289d916599f694cc9796302)"
                    DW_AT_stmt_list             0x00000000
                    DW_AT_comp_dir              "clang version 3.9.0
(http://llvm.org/git/clang.git 3d996e269b2a4c446a67d89d9d8b1c510168169b)
(http://llvm.org/git/llvm.git c27d8b42ef187b39e289d916599f694cc9796302)"
                    DW_AT_low_pc                0x00000000
                    DW_AT_high_pc               <offset-from-lowpc>36

LOCAL_SYMBOLS:
< 1><0x00000026>    DW_TAG_subprogram
                      DW_AT_low_pc                0x00000000
                      DW_AT_high_pc               <offset-from-lowpc>36
                      DW_AT_frame_base            len 0x0001: 5d: DW_OP_reg13
                      DW_AT_name                  "clang version 3.9.0
(http://llvm.org/git/clang.git 3d996e269b2a4c446a67d89d9d8b1c510168169b)
(http://llvm.org/git/llvm.git c27d8b42ef187b39e289d916599f694cc9796302)"
                      DW_AT_decl_file             0x00000001 clang version
3.9.0 (http://llvm.org/git/clang.git 3d996e269b2a4c446a67d89d9d8b1c510168169b)
(http://llvm.org/git/llvm.git c27d8b42ef187b39e289d916599f694cc9796302)/t.c
                      DW_AT_decl_line             0x00000001
                      DW_AT_prototyped            yes(1)
                      DW_AT_type                  <0x00000058>
                      DW_AT_external              yes(1)

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20160603/75bfcd82/attachment.html>


More information about the llvm-bugs mailing list