[PATCH] D95518: [Debug-Info][XCOFF] support dwarf for XCOFF for assembly output
Jason Liu via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 4 09:23:43 PST 2021
jasonliu added inline comments.
================
Comment at: llvm/test/DebugInfo/XCOFF/empty.ll:9
+target datalayout = "E-m:a-p:32:32-i64:64-n32"
+
+; Function Attrs: noinline nounwind optnone
----------------
So I tried a simple program with this patch:
```
(gdb) list
1 int bar2() {return 1;}
2 int main() {
3 int c = 10;
4 return bar2()+c;
5 }
(gdb) b 3
Breakpoint 1 at 0x100004d8: file /gsa/tlbgsa/home/j/a/jasonli/defect/XCOFF/main.c, line 3.
(gdb) r
Starting program: /gsa/tlbgsa-h1/06/jasonli/defect/XCOFF/main
Breakpoint 1, main () at /gsa/tlbgsa/home/j/a/jasonli/defect/XCOFF/main.c:3
3 int c = 10;
(gdb) n
4 return bar2()+c;
(gdb) s
bar2 () at /gsa/tlbgsa/home/j/a/jasonli/defect/XCOFF/main.c:1
1 int bar2() {return 1;}
(gdb) n
0x100002fc in __start ()
```
It seems when we try the last "next", it skips the `main` function and goes directly into `__start()`. But gcc on AIX seems to be able to advance to `main` before goes to `__start()`.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D95518/new/
https://reviews.llvm.org/D95518
More information about the llvm-commits
mailing list