Debian Bug report logs - #854194
valgrind: segfaults on MIPS Cavium Octeon boards

version graph

Package: valgrind; Maintainer for valgrind is Alessandro Ghedini <ghedo@debian.org>; Source for valgrind is src:valgrind (PTS, buildd, popcon).

Reported by: Adrian Bunk <bunk@debian.org>

Date: Sat, 4 Feb 2017 22:42:01 UTC

Severity: important

Tags: fixed-upstream

Found in version valgrind/1:3.12.0~svn20160714-1

Fixed in version valgrind/1:3.13.0-1

Done: Alessandro Ghedini <ghedo@debian.org>

Bug is archived. No further changes may be made.

Forwarded to https://bugs.kde.org/show_bug.cgi?id=376142

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, debian-mips@lists.debian.org, Alessandro Ghedini <ghedo@debian.org>:
Bug#854194; Package valgrind. (Sat, 04 Feb 2017 22:42:04 GMT) (full text, mbox, link).


Acknowledgement sent to Adrian Bunk <bunk@debian.org>:
New Bug report received and forwarded. Copy sent to debian-mips@lists.debian.org, Alessandro Ghedini <ghedo@debian.org>. (Sat, 04 Feb 2017 22:42:04 GMT) (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: Adrian Bunk <bunk@debian.org>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: valgrind segfaults on mipsel
Date: Sun, 05 Feb 2017 00:39:49 +0200
Package: valgrind
Version: 1:3.12.0~svn20160714-1+b1
Severity: serious

Seen with both 1:3.12.0~svn20160714-1+b1 and 1:3.12.0-1.1:

(sid_mipsel-dchroot)bunk@eller:~$ valgrind /usr/bin/hello 
==32333== Memcheck, a memory error detector
==32333== Copyright (C) 2002-2015, and GNU GPL'd, by Julian Seward et al.
==32333== Using Valgrind-3.12.0 and LibVEX; rerun with -h for copyright info
==32333== Command: /usr/bin/hello
==32333== 
Segmentation fault
(sid_mipsel-dchroot)bunk@eller:~$ gdb /usr/bin/valgrind.bin 
GNU gdb (Debian 7.12-6) 7.12.0.20161007-git
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "mipsel-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/bin/valgrind.bin...Reading symbols from /usr/lib/debug//usr/bin/valgrind.bin...done.
done.
(gdb) run /usr/bin/hello
Starting program: /usr/bin/valgrind.bin /usr/bin/hello
process 32540 is executing new program: /usr/lib/valgrind/memcheck-mips32-linux
==32540== Memcheck, a memory error detector
==32540== Copyright (C) 2002-2015, and GNU GPL'd, by Julian Seward et al.
==32540== Using Valgrind-3.12.0 and LibVEX; rerun with -h for copyright info
==32540== Command: /usr/bin/hello
==32540== 
warning: GDB can't find the start of the function at 0x433a2f74.

    GDB is unable to find the start of the function at 0x433a2f74
and thus can't determine the size of that function's stack frame.
This means that GDB may be unable to access that stack frame, or
the frames below it.
    This problem is most likely caused by an invalid program counter or
stack pointer.
    However, if you think GDB should simply search farther back
from 0x433a2f74 for code which looks like the beginning of a
function, you can increase the range of the search using the `set
heuristic-fence-post' command.

Program received signal SIGSEGV, Segmentation fault.
0x433a2f74 in ?? ()
(gdb)



Reply sent to YunQiang Su <wzssyqa@gmail.com>:
You have taken responsibility. (Tue, 07 Feb 2017 09:24:10 GMT) (full text, mbox, link).


Notification sent to Adrian Bunk <bunk@debian.org>:
Bug acknowledged by developer. (Tue, 07 Feb 2017 09:24:10 GMT) (full text, mbox, link).


Message #10 received at 854194-close@bugs.debian.org (full text, mbox, reply):

From: YunQiang Su <wzssyqa@gmail.com>
To: 854194-close@bugs.debian.org
Subject: Re: valgrind segfaults on mipsel
Date: Tue, 7 Feb 2017 17:20:44 +0800
On Sun, 05 Feb 2017 00:39:49 +0200 Adrian Bunk <bunk@debian.org> wrote:
> Package: valgrind
> Version: 1:3.12.0~svn20160714-1+b1
> Severity: serious
>

It seems that 1:3.12.0-1.1 doesn't have this problem.
I also test it on Loongson 3A.

root@thor:/# valgrind /usr/bin/hello
==2085== Memcheck, a memory error detector
==2085== Copyright (C) 2002-2015, and GNU GPL'd, by Julian Seward et al.
==2085== Using Valgrind-3.12.0 and LibVEX; rerun with -h for copyright info
==2085== Command: /usr/bin/hello
==2085==

VEX: Unsupported baseline
     Found: Loongson-baseline
Cannot continue. Good-bye

vex storage: T total 0 bytes allocated
vex storage: P total 0 bytes allocated

valgrind: the 'impossible' happened:
   LibVEX called failure_exit().

host stacktrace:
==2085==    at 0x38086EFC: show_sched_status_wrk (m_libcassert.c:343)
==2085==    by 0x380870C8: report_and_quit (m_libcassert.c:419)
==2085==    by 0x38087338: panic (m_libcassert.c:495)
==2085==    by 0x38087338: vgPlain_core_panic_at (m_libcassert.c:500)
==2085==    by 0x3808737C: vgPlain_core_panic (m_libcassert.c:505)
==2085==    by 0x380AAC9C: failure_exit (m_translate.c:740)
==2085==    by 0x3818D5E4: vfatal (main_util.c:552)
==2085==    by 0x38189AF8: invalid_hwcaps (main_main.c:1789)
==2085==    by 0x38189DC0: check_hwcaps (main_main.c:1991)
==2085==    by 0x3818A63C: LibVEX_Translate (main_main.c:592)
==2085==    by 0x380ADE8C: vgPlain_translate (m_translate.c:1770)
==2085==    by 0x380F3F60: handle_tt_miss (scheduler.c:1048)
==2085==    by 0x380F3F60: vgPlain_scheduler (scheduler.c:1409)
==2085==    by 0x38109CC0: thread_wrapper (syswrap-linux.c:103)
==2085==    by 0x38109CC0: run_a_thread_NORETURN (syswrap-linux.c:156)
==2085==    by 0x3810A54C: vgPlain_main_thread_wrapper_NORETURN
(syswrap-linux.c:417)

sched status:
  running_tid=1

Thread 1: status = VgTs_Runnable (lwpid 2085)
==2085==    at 0x4000D00: __start (in /lib/mipsel-linux-gnu/ld-2.24.so)
==2085==    by 0x7EBBF648: ???


Note: see also the FAQ in the source distribution.
It contains workarounds to several common problems.
In particular, if Valgrind aborted or crashed after
identifying problems in your program, there's a good chance
that fixing those problems will prevent Valgrind aborting or
crashing, especially if it happened in m_mallocfree.c.

If that doesn't help, please report this bug to: www.valgrind.org

In the bug report, send all the above text, the valgrind
version, and what OS and version you are using.  Thanks.



> Seen with both 1:3.12.0~svn20160714-1+b1 and 1:3.12.0-1.1:
>
> (sid_mipsel-dchroot)bunk@eller:~$ valgrind /usr/bin/hello
> ==32333== Memcheck, a memory error detector
> ==32333== Copyright (C) 2002-2015, and GNU GPL'd, by Julian Seward et al.
> ==32333== Using Valgrind-3.12.0 and LibVEX; rerun with -h for copyright info
> ==32333== Command: /usr/bin/hello
> ==32333==
> Segmentation fault
> (sid_mipsel-dchroot)bunk@eller:~$ gdb /usr/bin/valgrind.bin
> GNU gdb (Debian 7.12-6) 7.12.0.20161007-git
> Copyright (C) 2016 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
> and "show warranty" for details.
> This GDB was configured as "mipsel-linux-gnu".
> Type "show configuration" for configuration details.
> For bug reporting instructions, please see:
> <http://www.gnu.org/software/gdb/bugs/>.
> Find the GDB manual and other documentation resources online at:
> <http://www.gnu.org/software/gdb/documentation/>.
> For help, type "help".
> Type "apropos word" to search for commands related to "word"...
> Reading symbols from /usr/bin/valgrind.bin...Reading symbols from /usr/lib/debug//usr/bin/valgrind.bin...done.
> done.
> (gdb) run /usr/bin/hello
> Starting program: /usr/bin/valgrind.bin /usr/bin/hello
> process 32540 is executing new program: /usr/lib/valgrind/memcheck-mips32-linux
> ==32540== Memcheck, a memory error detector
> ==32540== Copyright (C) 2002-2015, and GNU GPL'd, by Julian Seward et al.
> ==32540== Using Valgrind-3.12.0 and LibVEX; rerun with -h for copyright info
> ==32540== Command: /usr/bin/hello
> ==32540==
> warning: GDB can't find the start of the function at 0x433a2f74.
>
>     GDB is unable to find the start of the function at 0x433a2f74
> and thus can't determine the size of that function's stack frame.
> This means that GDB may be unable to access that stack frame, or
> the frames below it.
>     This problem is most likely caused by an invalid program counter or
> stack pointer.
>     However, if you think GDB should simply search farther back
> from 0x433a2f74 for code which looks like the beginning of a
> function, you can increase the range of the search using the `set
> heuristic-fence-post' command.
>
> Program received signal SIGSEGV, Segmentation fault.
> 0x433a2f74 in ?? ()
> (gdb)
>
>



Information forwarded to debian-bugs-dist@lists.debian.org, Alessandro Ghedini <ghedo@debian.org>:
Bug#854194; Package valgrind. (Tue, 07 Feb 2017 13:06:02 GMT) (full text, mbox, link).


Acknowledgement sent to James Cowgill <jcowgill@debian.org>:
Extra info received and forwarded to list. Copy sent to Alessandro Ghedini <ghedo@debian.org>. (Tue, 07 Feb 2017 13:06:02 GMT) (full text, mbox, link).


Message #15 received at 854194@bugs.debian.org (full text, mbox, reply):

From: James Cowgill <jcowgill@debian.org>
To: Adrian Bunk <bunk@debian.org>, YunQiang Su <wzssyqa@gmail.com>
Cc: 854194@bugs.debian.org, "debian-mips@lists.debian.org" <debian-mips@lists.debian.org>
Subject: Bug#854194: valgrind: segfaults on MIPS Cavium Octeon boards
Date: Tue, 7 Feb 2017 13:03:38 +0000
[Message part 1 (text/plain, inline)]
Control: reopen -1
Control: retitle -1 valgrind: segfaults on MIPS Cavium Octeon boards
Control: severity -1 important

Hi,

On Tue, 7 Feb 2017 17:20:44 +0800 YunQiang Su <wzssyqa@gmail.com> wrote:
> On Sun, 05 Feb 2017 00:39:49 +0200 Adrian Bunk <bunk@debian.org> wrote:
> > Package: valgrind
> > Version: 1:3.12.0~svn20160714-1+b1
> > Severity: serious
> >
> 
> It seems that 1:3.12.0-1.1 doesn't have this problem.
> I also test it on Loongson 3A.
> 
> root@thor:/# valgrind /usr/bin/hello
> ==2085== Memcheck, a memory error detector
> ==2085== Copyright (C) 2002-2015, and GNU GPL'd, by Julian Seward et al.
> ==2085== Using Valgrind-3.12.0 and LibVEX; rerun with -h for copyright info
> ==2085== Command: /usr/bin/hello
> ==2085==
> 
> VEX: Unsupported baseline
>      Found: Loongson-baseline
> Cannot continue. Good-bye

Well this just means that valgrind refuses to run on Loongson. The code
which triggers this bug hasn't yet run at this point.

However, if I hack /proc/cpuinfo so that it pretends to be an Octeon
machine, then valgrind does work correctly on Loongson 3A machines (at
least ls works). I can also get valgrind to work correctly on the CI20.

It seems this bug is Octeon specific. I'm downgrading the bug on that
basis since it doesn't affect mipsel in general. It just so happens that
the majority of the buildds and the 2 mips porterboxes are Octeons.

Thanks,
James

[signature.asc (application/pgp-signature, attachment)]

Bug reopened Request was from James Cowgill <jcowgill@debian.org> to 854194-submit@bugs.debian.org. (Tue, 07 Feb 2017 13:06:02 GMT) (full text, mbox, link).


Changed Bug title to 'valgrind: segfaults on MIPS Cavium Octeon boards' from 'valgrind segfaults on mipsel'. Request was from James Cowgill <jcowgill@debian.org> to 854194-submit@bugs.debian.org. (Tue, 07 Feb 2017 13:06:03 GMT) (full text, mbox, link).


Severity set to 'important' from 'serious' Request was from James Cowgill <jcowgill@debian.org> to 854194-submit@bugs.debian.org. (Tue, 07 Feb 2017 13:06:03 GMT) (full text, mbox, link).


Set Bug forwarded-to-address to 'https://bugs.kde.org/show_bug.cgi?id=376142'. Request was from James Cowgill <jcowgill@debian.org> to control@bugs.debian.org. (Tue, 07 Feb 2017 16:09:04 GMT) (full text, mbox, link).


Information forwarded to debian-bugs-dist@lists.debian.org, Alessandro Ghedini <ghedo@debian.org>:
Bug#854194; Package valgrind. (Tue, 14 Mar 2017 12:00:03 GMT) (full text, mbox, link).


Acknowledgement sent to James Cowgill <jcowgill@debian.org>:
Extra info received and forwarded to list. Copy sent to Alessandro Ghedini <ghedo@debian.org>. (Tue, 14 Mar 2017 12:00:03 GMT) (full text, mbox, link).


Message #28 received at 854194@bugs.debian.org (full text, mbox, reply):

From: James Cowgill <jcowgill@debian.org>
To: 854194@bugs.debian.org
Cc: Adrian Bunk <bunk@debian.org>, YunQiang Su <wzssyqa@gmail.com>, "debian-mips@lists.debian.org" <debian-mips@lists.debian.org>
Subject: Re: Bug#854194: valgrind: segfaults on MIPS Cavium Octeon boards
Date: Tue, 14 Mar 2017 11:57:43 +0000
[Message part 1 (text/plain, inline)]
Control: tags -1 fixed-upstream

On 07/02/17 13:03, James Cowgill wrote:
> Control: reopen -1
> Control: retitle -1 valgrind: segfaults on MIPS Cavium Octeon boards
> Control: severity -1 important
> 
> Hi,
> 
> On Tue, 7 Feb 2017 17:20:44 +0800 YunQiang Su <wzssyqa@gmail.com> wrote:
>> On Sun, 05 Feb 2017 00:39:49 +0200 Adrian Bunk <bunk@debian.org> wrote:
>>> Package: valgrind
>>> Version: 1:3.12.0~svn20160714-1+b1
>>> Severity: serious
>>>
>>
>> It seems that 1:3.12.0-1.1 doesn't have this problem.
>> I also test it on Loongson 3A.
>>
>> root@thor:/# valgrind /usr/bin/hello
>> ==2085== Memcheck, a memory error detector
>> ==2085== Copyright (C) 2002-2015, and GNU GPL'd, by Julian Seward et al.
>> ==2085== Using Valgrind-3.12.0 and LibVEX; rerun with -h for copyright info
>> ==2085== Command: /usr/bin/hello
>> ==2085==
>>
>> VEX: Unsupported baseline
>>      Found: Loongson-baseline
>> Cannot continue. Good-bye
> 
> Well this just means that valgrind refuses to run on Loongson. The code
> which triggers this bug hasn't yet run at this point.
> 
> However, if I hack /proc/cpuinfo so that it pretends to be an Octeon
> machine, then valgrind does work correctly on Loongson 3A machines (at
> least ls works). I can also get valgrind to work correctly on the CI20.
> 
> It seems this bug is Octeon specific. I'm downgrading the bug on that
> basis since it doesn't affect mipsel in general. It just so happens that
> the majority of the buildds and the 2 mips porterboxes are Octeons.

FYI this bug and a related bug causing hangs on Octeon have now been
fixed in upstream SVN.

See: https://bugs.kde.org/show_bug.cgi?id=376142

Thanks,
James

[signature.asc (application/pgp-signature, attachment)]

Added tag(s) fixed-upstream. Request was from James Cowgill <jcowgill@debian.org> to 854194-submit@bugs.debian.org. (Tue, 14 Mar 2017 12:00:03 GMT) (full text, mbox, link).


Reply sent to Alessandro Ghedini <ghedo@debian.org>:
You have taken responsibility. (Mon, 24 Jul 2017 21:39:09 GMT) (full text, mbox, link).


Notification sent to Adrian Bunk <bunk@debian.org>:
Bug acknowledged by developer. (Mon, 24 Jul 2017 21:39:09 GMT) (full text, mbox, link).


Message #35 received at 854194-close@bugs.debian.org (full text, mbox, reply):

From: Alessandro Ghedini <ghedo@debian.org>
To: 854194-close@bugs.debian.org
Subject: Bug#854194: fixed in valgrind 1:3.13.0-1
Date: Mon, 24 Jul 2017 21:35:49 +0000
Source: valgrind
Source-Version: 1:3.13.0-1

We believe that the bug you reported is fixed in the latest version of
valgrind, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 854194@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Alessandro Ghedini <ghedo@debian.org> (supplier of updated valgrind package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Mon, 24 Jul 2017 00:41:05 +0100
Source: valgrind
Binary: valgrind valgrind-dbg valgrind-mpi
Architecture: source
Version: 1:3.13.0-1
Distribution: unstable
Urgency: medium
Maintainer: Alessandro Ghedini <ghedo@debian.org>
Changed-By: Alessandro Ghedini <ghedo@debian.org>
Description:
 valgrind   - instrumentation framework for building dynamic analysis tools
 valgrind-dbg - instrumentation framework for building dynamic analysis tools (de
 valgrind-mpi - instrumentation framework for building dynamic analysis tools (MP
Closes: 677876 843367 854194
Changes:
 valgrind (1:3.13.0-1) unstable; urgency=medium
 .
   * New upstream release
     - Fix segfaults on MIPS Cavium Octeon boards (Closes: #854194)
     - Support compressed debuginfo sections (Closes: #677876)
   * Update watch file to point to new download site
   * Update Standards-Version to 4.0.0 (no changes needed)
   * Refresh patches
   * Remove Roland Stigge from Uploaders since he retired (Closes: #843367)
Checksums-Sha1:
 dd9d08e58abf38e9f88de3ad2f1624ddbae20165 2441 valgrind_3.13.0-1.dsc
 ddf13e22dd0ee688bd533fc66b94cf88f75fad86 14723076 valgrind_3.13.0.orig.tar.bz2
 548ab1cf7e1c3be9100acc7d198994dfef94c263 25852 valgrind_3.13.0-1.debian.tar.xz
 47d8e940dd82bd40506048c06f9e5bfc41a4756e 7888 valgrind_3.13.0-1_amd64.buildinfo
Checksums-Sha256:
 ab84e017d1660efd30e9e0593a4c8b976aeda013cefb8c416dd284cc7222c11c 2441 valgrind_3.13.0-1.dsc
 d76680ef03f00cd5e970bbdcd4e57fb1f6df7d2e2c071635ef2be74790190c3b 14723076 valgrind_3.13.0.orig.tar.bz2
 b6a5d20e8bab60266e44baa594a96239a4692915bea0bf191c7211bce373f021 25852 valgrind_3.13.0-1.debian.tar.xz
 57542d30eaec37236040208408b5095fc5f3728311e42f466fe5847b7e9edb3f 7888 valgrind_3.13.0-1_amd64.buildinfo
Files:
 deb54019cbfaec88a9e0a25fb2510d3d 2441 devel optional valgrind_3.13.0-1.dsc
 817dd08f1e8a66336b9ff206400a5369 14723076 devel optional valgrind_3.13.0.orig.tar.bz2
 9184c5a90e0e342a13a70c56cc5171bb 25852 devel optional valgrind_3.13.0-1.debian.tar.xz
 a937d2667dc451d76700acc9532982c4 7888 devel optional valgrind_3.13.0-1_amd64.buildinfo

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEEBsId305pBx+F583DbwzL4CFiRygFAll2Y+EACgkQbwzL4CFi
RyhZtQ/9E+j17ok5WSXm4tPO/iK7cqe2rVcKApGuj90xvGvG59n52TMqWSYUaHPF
FdN80lB8Dx5M2qzzgaPYTEVU3nrXRZlTFdPzFz20OOPdS2TRKsQBwDs92VpmhkkS
nm5gY8xV+9JBkTp8phFT5oowxOQb6wIDPaqbOj1j5oExuq3+C2Oar8FH3EqONIAM
LPcgYfLq7r1bzic+SGjxemkoJyZhhbfEJibAGfFwRoqdHS1Ci5LXajBjsH/FhGC4
drrkNgSExqrbwNVLHejgQBAFxkMIebWHe5E8WRyhMeXUhNl3KuQTK97UE5g9Y7NC
LQ0PtqhYBJeRk0/XZcuMDHDL2HILLeLxiY3nvh/wqXjhqFMYTcVs1rthNIbs1/9e
YGWoP/bwPWJGYwkpzALwBunWF+xribRCWZkWZ6g+1nRmyXqe1zsWsTZbrPWze3UO
DqvP3MnHiFLfeDReSadHWDHLfGcvqN1odTlC41o1nvDBnAQQPkIK+syx9Ynj9/lY
r3TUZGPJdE62BmodiiO+R6KlqQQavseVkFycuoi6YemU86EWt/K0GtPZGtdnyd53
TCMrtEBTDfmUbO3gmsoQHq0mB53yFTJq0cIcUzoa48BKswxtG6PAFFQUnuYfhxCn
n58jV67xC+PkH6iiKosXipsPDIuUcgYr7gWsB7lbSkncSvtaq0o=
=Ehin
-----END PGP SIGNATURE-----




Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Mon, 28 Aug 2017 07:30:26 GMT) (full text, mbox, link).


Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Wed Sep 27 07:45:52 2023; Machine Name: bembo

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.