[LCP]/lib/ld-2.3.5.so unconditional jumps (valgrind / memcheck)

Jack Lloyd lloyd at randombit.net
Wed Nov 16 03:26:02 UTC 2005


On Tue, Nov 15, 2005 at 04:31:38PM +0000, matthew studley wrote:
> Hi
> 
> Apologies first : this is a C++ question, so I may be posting to the
> wrong forum.
> 
> With Valgrind using memcheck, I frequently observe this:
> 
> ==12443== Conditional jump or move depends on uninitialised value(s)
> ==12443==    at 0x1B8ECB13: (within /lib/ld-2.3.5.so)
> 
> Does anybody know :
> 
> what is /lib/ld-2.3.5.so ?

It is the dynamic loader, which is used by any program that uses dynamic
libraries (either linking to shared objects or dlopen'ing them).

> how do I fix this (does it need fixing?) ?

If you link your application statically (-static flag to gcc during link), the
dynamic loader will be removed from the equation and these should vanish. You
can also write a supression for Valgrind so you don't see them.

It doesn't need fixing AFAIK. I've seen these warnings from Valgrind as well
from time to time. The dynamic linker does many strange things because of what
it is, and I suspect this is a false positive. If it is not, then it is a bug
in the dynamic linker, not your program, so there isn't much you can do about
it besides upgrade your system to the latest glibc and hope that fixes it.

-Jack




More information about the linuxCprogramming mailing list