[PATCH] Don't write beyond destination in __mempcpy_avx512_no_vzeroupper (bug 23196)
Florian Weimer
fweimer@redhat.com
Tue May 22 14:36:00 GMT 2018
On 05/22/2018 04:12 PM, Andreas Schwab wrote:
> On Mai 22 2018, Florian Weimer <fweimer@redhat.com> wrote:
>
>> My test machine had an L2 cache size of 1 MiB.
>
> Then you should be safe, a 64K mempcpy is enough to trigger it.
Our memcpy has:
L(512bytesormore):
#ifdef SHARED_CACHE_SIZE_HALF
mov $SHARED_CACHE_SIZE_HALF, %r8
#else
mov __x86_64_shared_cache_size_half(%rip), %r8
#endif
cmp %r8, %rdx
jae L(preloop_large)
cmp $1024, %rdx
ja L(1024bytesormore)
And with the original reproducer, we wouldn't hit preloop_large, where
the bug is.
Thanks,
Florian
More information about the Libc-alpha
mailing list