touch-packages team mailing list archive
-
touch-packages team
-
Mailing list archive
-
Message #15539
[Bug 1365664] Re: gdb source test suites are failing in Ubuntu14.10
I see what is going on, but don't know how to fix it yet.
Gdb must be checking for program headers that are marked load or
segments that are marked allocate (not exactly sure what yet). The
.symtab and .strtab are not, because normally they are not loaded into
memory.
The problem is bfd_elf_get_elf_syms tries to bfd_seek too far, and
fails. The VDSO looks like:
[Nr] Name Type Address Off Size ES Flg Lk Inf Al
[ 0] NULL 0000000000000000 000000 000000 00 0 0 0
[ 1] .hash HASH 0000000000000120 000120 00004c 04 A 2 0 8
[ 2] .dynsym DYNSYM 0000000000000170 000170 000150 18 A 3 2 8
[ 3] .dynstr STRTAB 00000000000002c0 0002c0 00010d 00 A 0 0 1
[ 4] .gnu.version VERSYM 00000000000003ce 0003ce 00001c 02 A 2 0 2
[ 5] .gnu.version_d VERDEF 00000000000003f0 0003f0 000038 00 A 3 2 8
[ 6] .note NOTE 0000000000000428 000428 00003c 00 A 0 0 4
[ 7] .text PROGBITS 0000000000000470 000470 000324 00 AX 0 0 8
[ 8] .dynamic DYNAMIC 0000000000000798 000798 000100 10 WA 3 0 8
[ 9] .eh_frame_hdr PROGBITS 0000000000000898 000898 00006c 00 A 0 0 4
[10] .eh_frame PROGBITS 0000000000000908 000908 000538 00 A 0 0 8
[11] .got PROGBITS 0000000000000e40 000e40 000008 08 WA 0 0 8
[12] .debug_aranges PROGBITS 0000000000000000 000e50 0000f0 00 0 0 16
[13] .debug_info PROGBITS 0000000000000000 000f40 00034c 00 0 0 1
[14] .debug_abbrev PROGBITS 0000000000000000 00128c 000064 00 0 0 1
[15] .debug_line PROGBITS 0000000000000000 0012f0 000313 00 0 0 1
[16] .rela.dyn RELA 0000000000000e40 000e40 000000 18 A 2 0 8
[17] .shstrtab STRTAB 0000000000000000 001603 0000be 00 0 0 1
[18] .symtab SYMTAB 0000000000000000 001bc8 000318 18 19 21 8
[19] .strtab STRTAB 0000000000000000 001ee0 000127 00 0 0 1
strace output:
open("/proc/19509/mem", O_RDONLY|O_CLOEXEC) = 10
pread64(10, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\25\0\1\0\0\0p\4\0\0\0\0\0\0"..., 64, 70367535824896) = 64
close(10) = 0
open("/proc/19509/mem", O_RDONLY|O_CLOEXEC) = 10
pread64(10, "\1\0\0\0\5\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 224, 70367535824960) = 224
close(10) = 0
open("/proc/19509/mem", O_RDONLY|O_CLOEXEC) = 10
pread64(10, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0\25\0\1\0\0\0p\4\0\0\0\0\0\0"..., 7112, 70367535824896) = 7112
close(10) = 0
We read up to 7112 (0x1bc8), right up to before the symtab. Not sure it
reads to there and not the limit of the program load header or all
section headers marked allocate.
--
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to gdb in Ubuntu.
https://bugs.launchpad.net/bugs/1365664
Title:
gdb source test suites are failing in Ubuntu14.10
Status in “gdb” package in Ubuntu:
Confirmed
Bug description:
---Problem Description---
gdb source test suites are failing in Ubuntu14.10
Machine Type = P8
---Steps to Reproduce---
Install a P8 system with Power KVM and then install Ubuntu 14.10 guest.
Then try to build and execute the gdb source test suites as below.
root@ubuntu:~# apt-get source gdb
root@ubuntu:~# cd gdb-7.8/
root@ubuntu:~/gdb-7.8# dpkg-buildpackage -b 2>&1 | tee gdblog
=== gdb Summary ===
# of expected passes 25009
# of unexpected failures 287
# of unexpected successes 2
# of expected failures 66
# of unknown successes 1
# of known failures 59
# of unresolved testcases 3
# of untested testcases 19
# of unsupported tests 100
---uname output---
Linux ubuntu 3.16.0-11-generic #16-Ubuntu SMP Mon Aug 25 20:02:00 UTC 2014 ppc64le ppc64le ppc64le GNU/Linux
I've retested gdb from Ubuntu 14.04 (gdb-7.7-0ubuntu3.1) in the Ubuntu 14.10 VM provided by Pavaman and the number of failures curiously increased to 250 (in comparison to less than 140 on 14.04), which leads me to believe that there is something in the environment of Ubuntu 14.10 compromising gdb functionality in several testcases.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gdb/+bug/1365664/+subscriptions