[Bug 1118523] New: gsplit-dwarf warning with dwarf4, not working with dwarf5
http://bugzilla.suse.com/show_bug.cgi?id=1118523 Bug ID: 1118523 Summary: gsplit-dwarf warning with dwarf4, not working with dwarf5 Classification: openSUSE Product: openSUSE Tumbleweed Version: Current Hardware: Other OS: Other Status: NEW Severity: Normal Priority: P5 - None Component: Development Assignee: bnc-team-screening@forge.provo.novell.com Reporter: tdevries@suse.com QA Contact: qa-bugs@suse.de Found By: --- Blocker: --- Consider this test-case: ... $ cat test-split-dwarf.sh #!/bin/bash if [ "$cc" = "" ]; then cc=gcc fi src=$HOME/hello.c exec=a.out srcbase=$(basename $src) obj=${srcbase%.c}.o dwo=${srcbase%.c}.dwo rm -f $exec $obj $dwo cflags="-g -gsplit-dwarf" ldflags="-Wl,--gdb-index -fuse-ld=gold" cflags="$cflags $*" set -x $cc $src -c $cflags $cc $obj $cflags $ldflags gdb -batch ./a.out -ex "break main" -ex run ... In leap 15.0 with gcc-7, we manage to find the line number with dwarf4: $ cc=gcc-7 ./test-split-dwarf.sh -gdwarf-4 + gcc-7 /home/vries/hello.c -c -g -gsplit-dwarf -gdwarf-4 + gcc-7 hello.o -g -gsplit-dwarf -gdwarf-4 -Wl,--gdb-index -fuse-ld=gold + gdb -batch ./a.out -ex 'break main' -ex run Breakpoint 1 at 0x40057b: file /home/vries/hello.c, line 6. Breakpoint 1, main () at /home/vries/hello.c:6 6 printf ("hello\n"); ... but not with dwarf5: ... $ cc=gcc-7 ./test-split-dwarf.sh -gdwarf-5 + gcc-7 /home/vries/hello.c -c -g -gsplit-dwarf -gdwarf-5 + gcc-7 hello.o -g -gsplit-dwarf -gdwarf-5 -Wl,--gdb-index -fuse-ld=gold + gdb -batch ./a.out -ex 'break main' -ex run Breakpoint 1 at 0x40057b Breakpoint 1, 0x000000000040057b in main () ... With tumbleweed and dwarf4, gdb seems to have issues with the generated dwarf (though still managing to find the line number): ... delia:/leap-home/vries/gcc_versions/devel # cc=gcc-7 ./test-split-dwarf.sh -gdwarf-4 + gcc-7 /root/hello.c -c -g -gsplit-dwarf -gdwarf-4 + gcc-7 hello.o -g -gsplit-dwarf -gdwarf-4 -Wl,--gdb-index -fuse-ld=gold + gdb -batch ./a.out -ex 'break main' -ex run BFD: /data/gcc_versions/devel/hello.dwo: unable to initialize decompress status for section .debug_info.dwo BFD: /data/gcc_versions/devel/hello.dwo: unable to initialize decompress status for section .debug_info.dwo BFD: /data/gcc_versions/devel/hello.dwo: unable to initialize decompress status for section .debug_info.dwo BFD: /data/gcc_versions/devel/hello.dwo: unable to initialize decompress status for section .debug_info.dwo warning: Could not find DWO CU hello.dwo(0xa2c9c5f62347eb28) referenced by CU at offset 0x9ff [in module /data/gcc_versions/devel/a.out] Breakpoint 1 at 0x40057b: file /root/hello.c, line 6. Missing separate debuginfo for /lib64/ld-linux-x86-64.so.2 Try: zypper install -C "debuginfo(build-id)=d1f6bf237ba196265561924d1baaf522e036281f" Missing separate debuginfo for /lib64/libc.so.6 Try: zypper install -C "debuginfo(build-id)=5926416cd74d1dfe53d37374041bca37ee80c598" Breakpoint 1, main () at /root/hello.c:6 6 printf ("hello\n"); ... That's still the case for gcc-9: ... $ cc=gcc-9 ./test-split-dwarf.sh -gdwarf-4 + gcc-9 /root/hello.c -c -g -gsplit-dwarf -gdwarf-4 + gcc-9 hello.o -g -gsplit-dwarf -gdwarf-4 -Wl,--gdb-index -fuse-ld=gold + gdb -batch ./a.out -ex 'break main' -ex run BFD: /data/gcc_versions/devel/hello.dwo: unable to initialize decompress status for section .debug_info.dwo BFD: /data/gcc_versions/devel/hello.dwo: unable to initialize decompress status for section .debug_info.dwo BFD: /data/gcc_versions/devel/hello.dwo: unable to initialize decompress status for section .debug_info.dwo BFD: /data/gcc_versions/devel/hello.dwo: unable to initialize decompress status for section .debug_info.dwo warning: Could not find DWO CU hello.dwo(0x75ed107fa50d0cf2) referenced by CU at offset 0x9ff [in module /data/gcc_versions/devel/a.out] Breakpoint 1 at 0x400576: file /root/hello.c, line 6. Missing separate debuginfo for /lib64/ld-linux-x86-64.so.2 Try: zypper install -C "debuginfo(build-id)=d1f6bf237ba196265561924d1baaf522e036281f" Missing separate debuginfo for /lib64/libc.so.6 Try: zypper install -C "debuginfo(build-id)=5926416cd74d1dfe53d37374041bca37ee80c598" Breakpoint 1, main () at /root/hello.c:6 6 printf ("hello\n"); ... and for dwarf5, we still don't find the line number info: ... $ cc=gcc-9 ./test-split-dwarf.sh -gdwarf-5 + gcc-9 /root/hello.c -c -g -gsplit-dwarf -gdwarf-5 + gcc-9 hello.o -g -gsplit-dwarf -gdwarf-5 -Wl,--gdb-index -fuse-ld=gold + gdb -batch ./a.out -ex 'break main' -ex run Breakpoint 1 at 0x400576 Missing separate debuginfo for /lib64/ld-linux-x86-64.so.2 Try: zypper install -C "debuginfo(build-id)=d1f6bf237ba196265561924d1baaf522e036281f" Missing separate debuginfo for /lib64/libc.so.6 Try: zypper install -C "debuginfo(build-id)=5926416cd74d1dfe53d37374041bca37ee80c598" Breakpoint 1, 0x0000000000400576 in main () ... -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.suse.com/show_bug.cgi?id=1118523
Zejin Xu
http://bugzilla.suse.com/show_bug.cgi?id=1118523
Stefan Fent
http://bugzilla.suse.com/show_bug.cgi?id=1118523
Richard Biener
participants (1)
-
bugzilla_noreply@novell.com