help-guix
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Valgrind not working [core-update fixes?]


From: zimoun
Subject: Re: Valgrind not working [core-update fixes?]
Date: Fri, 02 Sep 2022 17:28:22 +0200

Hi,

On Tue, 08 Mar 2022 at 11:12, Ludovic Courtès <ludo@gnu.org> wrote:

>> valgrind:  Fatal error at startup: a function redirection

[...]

>> valgrind:  Cannot continue -- exiting now.  Sorry.
>
> I’m late to the party, but here’s the trick you can use:

Well, I am even later to the party. ;-)

> --8<---------------cut here---------------start------------->8---
> $ guix build -e '(@@ (gnu packages commencement) glibc-final)' 
> /gnu/store/xgarlnscgbm9l04karj15xpc4nn14ak1-glibc-2.33-debug
> /gnu/store/5h2w4qi9hk1qzzgi1w83220ydslinr4s-glibc-2.33
> /gnu/store/4jdghmc65q7i7ib89zmvq66l0ghf7jc4-glibc-2.33-static
> $ valgrind 
> --extra-debuginfo-path=/gnu/store/xgarlnscgbm9l04karj15xpc4nn14ak1-glibc-2.33-debug/lib/debug
>  uname -o
> ==16741== Memcheck, a memory error detector
> ==16741== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
> ==16741== Using Valgrind-3.18.1 and LibVEX; rerun with -h for copyright info
> ==16741== Command: uname -o
> ==16741== 
> GNU/Linux
> ==16741== 
> ==16741== HEAP SUMMARY:
> ==16741==     in use at exit: 0 bytes in 0 blocks
> ==16741==   total heap usage: 2,813 allocs, 2,813 frees, 184,302 bytes 
> allocated
> ==16741== 
> ==16741== All heap blocks were freed -- no leaks are possible
> ==16741== 
> ==16741== For lists of detected and suppressed errors, rerun with: -s
> ==16741== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)
> --8<---------------cut here---------------end--------------->8---

This trick is really nice…

> I think the reason it no longer works out of the box is because we
> now[*] use ‘--strip-unneeded’ instead of ‘--strip-debug’, since commit
> e0f31baacc6ad30096a332b69433c85f5830bb2c.
>
> We’d need to double-check the hypothesis and fix it on ‘core-updates’.

…but since core-updates is moving, maybe it is time for this
double-check.  Well, gentle reminder. :-)

How could I double-check without rebuilding locally the world?


Cheers,
simon





reply via email to

[Prev in Thread] Current Thread [Next in Thread]