1
0
mirror of https://git.yoctoproject.org/poky synced 2026-05-08 05:09:24 +00:00

valgrind: fix debug info reading error when do memcheck on ppc targets

following is the error message:
        --2263-- WARNING: Serious error when reading debug info
        --2263-- When reading debug info from /lib/ld-2.13.so:
        --2263-- Can't make sense of .got section mapping
        --2263-- WARNING: Serious error when reading debug info
        --2263-- When reading debug info from /home/root/lzh:
        --2263-- Can't make sense of .data section mapping
        --2263-- WARNING: Serious error when reading debug info
        --2263-- When reading debug info from /usr/lib/valgrind/vgpreload_core-ppc32-linux.so:
        --2263-- Can't make sense of .data section mapping
        --2263-- WARNING: Serious error when reading debug info
        --2263-- When reading debug info from /usr/lib/valgrind/vgpreload_memcheck-ppc32-linux.so:
        --2263-- Can't make sense of .data section mapping
        --2263-- WARNING: Serious error when reading debug info
        --2263-- When reading debug info from /lib/libc-2.13.so:
        --2263-- Can't make sense of .data section mapping

(From OE-Core rev: 14626cc76210ed6fe40316a311f24147ed8de8be)

Signed-off-by: Zhenhua Luo <b19537@freescale.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Zhenhua Luo
2012-09-12 16:20:46 +08:00
committed by Richard Purdie
parent fdf87242d9
commit b7a81c5b51
2 changed files with 37 additions and 1 deletions
@@ -0,0 +1,33 @@
Upstream-Status: Pending
fix debug info reading error when do memcheck on ppc targets
following is the error message:
--2263-- WARNING: Serious error when reading debug info
--2263-- When reading debug info from /lib/ld-2.13.so:
--2263-- Can't make sense of .got section mapping
--2263-- WARNING: Serious error when reading debug info
--2263-- When reading debug info from /home/root/lzh:
--2263-- Can't make sense of .data section mapping
--2263-- WARNING: Serious error when reading debug info
--2263-- When reading debug info from /usr/lib/valgrind/vgpreload_core-ppc32-linux.so:
--2263-- Can't make sense of .data section mapping
--2263-- WARNING: Serious error when reading debug info
--2263-- When reading debug info from /usr/lib/valgrind/vgpreload_memcheck-ppc32-linux.so:
--2263-- Can't make sense of .data section mapping
--2263-- WARNING: Serious error when reading debug info
--2263-- When reading debug info from /lib/libc-2.13.so:
--2263-- Can't make sense of .data section mapping
Signed-off-by: Zhenhua Luo <b19537@freescale.com>
--- a/coregrind/m_debuginfo/readelf.c 2012-09-11 21:45:36.696462313 -0500
+++ b/coregrind/m_debuginfo/readelf.c 2012-09-11 21:45:49.913463615 -0500
@@ -1539,7 +1539,7 @@
&& phdr->p_offset < di->fsm.rw_map_foff + di->fsm.rw_map_size
&& phdr->p_offset + phdr->p_filesz
<= di->fsm.rw_map_foff + di->fsm.rw_map_size
- && (phdr->p_flags & (PF_R | PF_W | PF_X)) == (PF_R | PF_W)) {
+ && (phdr->p_flags & (PF_R | PF_W | PF_X)) >= (PF_R | PF_W)) {
if (n_rw == N_RX_RW_AREAS) {
ML_(symerr)(di, True,
"N_RX_RW_AREAS is too low; "
@@ -9,7 +9,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=c46082167a314d785d012a244748d803 \
X11DEPENDS = "virtual/libx11"
DEPENDS = "${@base_contains('DISTRO_FEATURES', 'x11', '${X11DEPENDS}', '', d)}"
PR = "r5"
PR = "r6"
SRC_URI = "http://www.valgrind.org/downloads/valgrind-${PV}.tar.bz2 \
file://fix_issue_caused_by_ccache.patch \
@@ -21,6 +21,9 @@ SRC_URI = "http://www.valgrind.org/downloads/valgrind-${PV}.tar.bz2 \
file://configure-with-glibc-2.16.patch \
"
SRC_URI_append_powerpc = " file://valgrind-3.7.0-fix-error-of-reading-debug-info.patch"
SRC_URI_append_powerpc64 = "file://valgrind-3.7.0-fix-error-of-reading-debug-info.patch"
SRC_URI[md5sum] = "a855fda56edf05614f099dca316d1775"
SRC_URI[sha256sum] = "5d62c0330f1481fe2c593249192fa68ff454c19c34343978cc9ce91aa324cbf6"