| Summary: | valgrind - invalid read w/ glibc 2.6.1 | ||
|---|---|---|---|
| Product: | [Developer tools] valgrind | Reporter: | Sylvain BERTRAND <sylvain.bertrand> |
| Component: | general | Assignee: | Julian Seward <jseward> |
| Status: | RESOLVED WORKSFORME | ||
| Severity: | normal | ||
| Priority: | NOR | ||
| Version First Reported In: | 3.2.3 | ||
| Target Milestone: | --- | ||
| Platform: | Gentoo Packages | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
| Attachments: |
valgrind -v output of reproduced issue
Test case |
||
|
Description
Sylvain BERTRAND
2007-11-21 10:22:21 UTC
Created attachment 22140 [details]
valgrind -v output of reproduced issue
You appear to be reporting an uninitialised memory read in glibc - do you actually have any reason to believe this is a bug in valgrind rather than what it would appear to be at first site, namely an issue in glibc? Only I can't see anything on the original bug report to suggest that the possibility of a glibc issue has been considered and excluded? For what it's worth I get no warnings on Fedora 8 with glibc 2.7 anyway. I suspect this is happening because ld-2.6.1.so is doing some highly optimised strlen/strcpy/strcmp stunt which involves reading 8 bytes at a time. But because ld-2.6.1.so has basically no symbols, Valgrind cannot intercept the call and replace it with a non-optimised version of its own. Do you have a simple test case we can reproduce this with? What does nm /lib64/ld-2.6.1.so produce? > ------- Additional Comments From tom compton nu 2007-11-21 10:30 -------
> For what it's worth I get no warnings on Fedora 8 with glibc 2.7 anyway.
Following on from my previous comment, a good way to exacerbate/show up
such problems is to deinstall the glibc-debuginfo package, if you have
one. The problem (of stripped ld-2.X.Y.so) is now so bad that I
recently introduced the concept of "mandatory redirections", which
cause V to stop at startup if the (soname,symbol) pair to redirect cannot
be found when the soname is loaded. See r7165's commit message for
more details.
The test case is on the gentoo bug - I'm attaching it here... Compile with: cc -o x x.c -L/usr/lib64/mysql -lmysqlclient Created attachment 22141 [details]
Test case
I do have the debuginfo rpm installed, but F8 with glibc 2.7 still works even with it removed. Gone with dev-util/valgrind-3.3.0 Gone with dev-util/valgrind-3.3.0 |