Looking somewhat further, I see that in fact, the replacement of memcpy
is not broken.
I find two memcpy: one memcpy is inside ld-linux-x86-64.so.2 (which is
there very early
from the start of the process and so the breakpoint was place there),
and then another memcpy "appears" somewhat later in the execution (in
libc.so.6).
This last one is properly replaced by memcheck.

So, the other  reason which might explain no errors being reported is
that gcc replaces a call to memcpy
by an inline loop.
In particular, when calling memcpy with a small hardcoded length, I see
that gcc does not insert
a call to memcpy but rather effectively does an inline loop.

Compiling with -fno-builtin might also make the overlap error
re-appearing.

Note that the memcheck regression test verifying that memcpy overlaps
are properly detected
(overlap.vgtest) is failing on my system (due to this "inline loop"
replacing the call to memcpy).

Philippe

____
 
This message and any files transmitted with it are legally privileged and 
intended for the sole use of the individual(s) or entity to whom they are 
addressed. If you are not the intended recipient, please notify the sender by 
reply and delete the message and any attachments from your system. Any 
unauthorised use or disclosure of the content of this message is strictly 
prohibited and may be unlawful.
 
Nothing in this e-mail message amounts to a contractual or legal commitment on 
the part of EUROCONTROL, unless it is confirmed by appropriately signed hard 
copy.
 
Any views expressed in this message are those of the sender.
------------------------------------------------------------------------------
Forrester Wave Report - Recovery time is now measured in hours and minutes
not days. Key insights are discussed in the 2010 Forrester Wave Report as
part of an in-depth evaluation of disaster recovery service providers.
Forrester found the best-in-class provider in terms of services and vision.
Read this report now!  http://p.sf.net/sfu/ibm-webcastpromo
_______________________________________________
Valgrind-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/valgrind-users

Reply via email to