https://sourceware.org/bugzilla/show_bug.cgi?id=20882
--- Comment #2 from H.J. Lu <hjl.tools at gmail dot com> ---
Gold keeps all debug info even if they aren't needed:
[hjl@gnu-6 pr20882]$ cat t1.s
.text
.globl main
.type main, @function
main:
ret
.section .debug_info,"",@progbits
.long t.c.4903c230+2
[hjl@gnu-6 pr20882]$ cat t2.s
.section .debug_info,"",@progbits
.hidden t.c.4903c230
.globl t.c.4903c230
t.c.4903c230:
.long 0x28
[hjl@gnu-6 pr20882]$ cat t3.s
.section .debug_info,"",@progbits
.hidden t.c.4903c231
.globl t.c.4903c231
t.c.4903c231:
.long 0x29
[hjl@gnu-6 pr20882]$ make y
as -o t1.o t1.s
as -o t2.o t2.s
as -o t3.o t3.s
ld.gold --entry=main -o y t1.o t2.o t3.o
[hjl@gnu-6 pr20882]$ readelf -x .debug_info y
Hex dump of section '.debug_info':
0x00000000 06000000 28000000 29000000 ....(...)...
[hjl@gnu-6 pr20882]$
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
bug-binutils mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/bug-binutils