[llvm-bugs] [Bug 46653] New: DebugInfo: arm64 progologue line number incorrecly set to "0"

via llvm-bugs llvm-bugs at lists.llvm.org
Thu Jul 9 01:04:29 PDT 2020


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

            Bug ID: 46653
           Summary: DebugInfo: arm64 progologue line number incorrecly set
                    to "0"
           Product: libraries
           Version: trunk
          Hardware: All
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Backend: AArch64
          Assignee: unassignedbugs at nondot.org
          Reporter: jaydeepchauhan1494 at gmail.com
                CC: arnaud.degrandmaison at arm.com,
                    llvm-bugs at lists.llvm.org, smithp352 at googlemail.com,
                    Ties.Stuij at arm.com

Consider below testcase for further discussion

$ cat check.c

#include<stdio.h>

int main()
{
   printf("Hello\n");
   return 0;
}


$clang  -target arm64 -g -c check.c
$./llvm-dwarfdump --debug-line check.o
...
...
Address            Line   Column File   ISA Discriminator Flags
------------------ ------ ------ ------ --- ------------- -------------
0x0000000000000000      4      0      1   0             0  is_stmt
0x0000000000000014      0      0      1   0             0  is_stmt prologue_end
0x0000000000000020      5      4      1   0             0  is_stmt
0x0000000000000028      6      4      1   0             0  is_stmt
0x0000000000000038      6      4      1   0             0  is_stmt end_sequence

In LLVM geneated executables prologue_end in line table is set to zero ,because
of that
when we put break point on main it will show line number of main function
location at line zero incorrectly.

And in gcc it is working fine. 

$aarch64-linux-gnu-gcc-8.3.0 -g -c check.c -o check_gcc.o
$./llvm-dwarfdump --debug-line check_gcc.o
Address            Line   Column File   ISA Discriminator Flags
------------------ ------ ------ ------ --- ------------- -------------
0x0000000000000000      4      1      1   0             0  is_stmt
0x0000000000000008      5      4      1   0             0  is_stmt
0x0000000000000014      6     11      1   0             0  is_stmt
0x0000000000000018      7      1      1   0             0  is_stmt
0x0000000000000020      7      1      1   0             0  is_stmt end_sequence

-- 
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/20200709/93151025/attachment.html>


More information about the llvm-bugs mailing list