Closed GoogleCodeExporter closed 9 years ago
It appears that memcpy() and memmove() are aliases on Lion:
$ nm /usr/lib/system/libsystem_c.dylib | grep "memcpy\|memmove"
0000000000013830 T ___memcpy_chk
000000000001381c T ___memmove_chk
00000000000a1969 T _memcpy
0000000000027ebd t _memcpy$VARIANT$sse3x
0000000000027cbd t _memcpy$VARIANT$sse42
00000000000e0af0 d _memcpy_platfunc_descriptors
000000000009ea1a T _memmove
0000000000027ebd t _memmove$VARIANT$sse3x
0000000000027cbd t _memmove$VARIANT$sse42
00000000000e0ab0 d _memmove_platfunc_descriptors
00000000000e19f0 s _platfunc_memcpy$VARIANT$sse3x
00000000000e19c0 s _platfunc_memcpy$VARIANT$sse42
00000000000e1a00 s _platfunc_memmove$VARIANT$sse3x
00000000000e19d0 s _platfunc_memmove$VARIANT$sse42
00000000000295a5 T _wmemcpy
0000000000006793 T _wmemmove
Therefore we're wrapping the same function twice, so for both memcpy() and
memmove() we're calling wrap_memcpy() => wrap_memmove() => original function.
To fix this we should just wrap memmove() and forget about memcpy-param-overlap
errors.
See also https://bugzilla.mozilla.org/show_bug.cgi?id=715750 and
http://code.google.com/p/valgrind-variant/issues/detail?id=5
Original comment by ramosian.glider@gmail.com
on 31 Jan 2012 at 11:30
Fixed in clang:r149492
Original comment by ramosian.glider@gmail.com
on 1 Feb 2012 at 10:13
Original comment by ramosian.glider@gmail.com
on 1 Feb 2012 at 10:13
Original issue reported on code.google.com by
ramosian.glider@gmail.com
on 30 Jan 2012 at 1:03