[llvm-bugs] [Bug 35318] New: dbg.addr location lists are wrong

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Nov 15 10:11:04 PST 2017


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

            Bug ID: 35318
           Summary: dbg.addr location lists are wrong
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: DebugInfo
          Assignee: unassignedbugs at nondot.org
          Reporter: aprantl at apple.com
                CC: llvm-bugs at lists.llvm.org

$ cat /tmp/test.c
int main(int argc, char **argv) {
  printf(argv[0]);
  int i = argc;
  ++i;
  ++i;
  return i;
}
$ clang --version
clang version 6.0.0 (trunk 318314) (llvm/trunk 318312)
$ clang -mllvm -use-dbg-addr -o /tmp/test /tmp/test.c -g
$ dwarfdump /tmp/test.dSYM

0x0000002a:     TAG_subprogram [2] *
                 AT_low_pc( 0x0000000100000f40 )
                 AT_high_pc( 0x0000004a )
                 AT_frame_base( rbp )
                 AT_name( "main" )
...

0x0000005f:         TAG_variable [4]  
                     AT_location( 0x00000000
                        0x0000000100000f84 - 0x0000000100000f8a: rbp-20 )
                     AT_name( "i" )
                     AT_decl_file( "/private/tmp/test.c" )
                     AT_decl_line( 3 )
                     AT_type( {0x0000006f} ( int ) )

-- 
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/20171115/14dba6a1/attachment-0001.html>


More information about the llvm-bugs mailing list