This is the mail archive of the
binutils@sourceware.cygnus.com
mailing list for the binutils project.
Possible problem debug sections default addresses on powerpc-linux-gnu
- To: binutils at sourceware dot cygnus dot com
- Subject: Possible problem debug sections default addresses on powerpc-linux-gnu
- From: Franz Sirl <Franz dot Sirl-kernel at lauterbach dot com>
- Date: Wed, 12 Apr 2000 00:23:09 +0200
Hi,
while loading a vmlinux kernel file with debugging information, I got a warning
about some debug section addresses not being 0. I tracked this down to the
linkerscript "vmlinux.lds" used during kernel builds, which doesn't mention any
debug sections like .stab at all. After adding the debug section entries from
elf.sc to vmlinux.lds the warning went away.
readelf -a shows the following differences:
--- old Wed Apr 12 00:31:56 2000
+++ new Wed Apr 12 00:32:02 2000
@@ -32,9 +32,9 @@
[ 8] .text.init PROGBITS c00da000 0ea000 00847c 00 AX 0 0 4
[ 9] .data.init PROGBITS c00e247c 0f247c 000a08 00 WA 0 0 4
[10] .bss NOBITS c00e3000 0f3000 01864c 00 WA 0 0 16
- [11] .stab PROGBITS c00fb64c 0f3000 233db4 0c 13 0 4
- [12] .comment PROGBITS c0441cc0 326db4 002f49 00 0 0 1
- [13] .stabstr STRTAB c032f400 329cfd 1128c0 00 0 0 1
+ [11] .stab PROGBITS 00000000 0f3000 233db4 0c 12 0 4
+ [12] .stabstr STRTAB 00000000 326db4 1128c0 00 0 0 1
+ [13] .comment PROGBITS 00000000 439674 002f49 00 0 0 1
[14] .shstrtab STRTAB 00000000 43c5bd 000098 00 0 0 1
[15] .symtab SYMTAB 00000000 43c900 0166a0 10 16 909 4
[16] .strtab STRTAB 00000000 452fa0 0155b7 00 0 0 1
@@ -67,9 +67,9 @@
8: c00da000 0 SECTION LOCAL DEFAULT 8
9: c00e247c 0 SECTION LOCAL DEFAULT 9
10: c00e3000 0 SECTION LOCAL DEFAULT 10
- 11: c00fb64c 0 SECTION LOCAL DEFAULT 11
- 12: c0441cc0 0 SECTION LOCAL DEFAULT 12
- 13: c032f400 0 SECTION LOCAL DEFAULT 13
+ 11: 00000000 0 SECTION LOCAL DEFAULT 11
+ 12: 00000000 0 SECTION LOCAL DEFAULT 12
+ 13: 00000000 0 SECTION LOCAL DEFAULT 13
14: 00000000 0 SECTION LOCAL DEFAULT 14
15: 00000000 0 SECTION LOCAL DEFAULT 15
16: 00000000 0 SECTION LOCAL DEFAULT 16
The change is quite obvious. My question is whether this is expected behaviour
or if the linker should be changed to provide correct values for the debug
section addresses, even though they are not mentioned in the linkerscript.
In any case I will send a patch to fix the omission in the vmlinux.lds script
to the kernel developers.
Franz.