This is the mail archive of the
glibc-cvs@sourceware.org
mailing list for the glibc project.
GNU C Library master sources branch hjl/erms/nt updated. glibc-2.23-161-gba909ce
- From: hjl at sourceware dot org
- To: glibc-cvs at sourceware dot org
- Date: 8 Apr 2016 16:26:25 -0000
- Subject: GNU C Library master sources branch hjl/erms/nt updated. glibc-2.23-161-gba909ce
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".
The branch, hjl/erms/nt has been updated
via ba909ce100685de5c227760356b2ad6ea2ba3876 (commit)
from a5d8234dcb78451af3ca70285ecc6b68edc2b070 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=ba909ce100685de5c227760356b2ad6ea2ba3876
commit ba909ce100685de5c227760356b2ad6ea2ba3876
Author: H.J. Lu <hjl.tools@gmail.com>
Date: Fri Apr 8 09:26:07 2016 -0700
Don't use non-temporal store if there is overlap
diff --git a/sysdeps/x86_64/multiarch/memmove-vec-unaligned-erms.S b/sysdeps/x86_64/multiarch/memmove-vec-unaligned-erms.S
index 51e562b..0b140f3 100644
--- a/sysdeps/x86_64/multiarch/memmove-vec-unaligned-erms.S
+++ b/sysdeps/x86_64/multiarch/memmove-vec-unaligned-erms.S
@@ -310,7 +310,7 @@ L(movsb_more_2x_vec):
ja L(movsb)
#endif
L(more_2x_vec):
- /* More than 2 * VEC and there may be overlap bewteen destination
+ /* More than 2 * VEC and there may be overlap between destination
and source. */
cmpq $(VEC_SIZE * 8), %rdx
ja L(more_8x_vec)
@@ -376,6 +376,12 @@ L(more_8x_vec):
/* Adjust length. */
addq %r8, %rdx
#if (defined USE_MULTIARCH || VEC_SIZE == 16) && IS_IN (libc)
+ /* Don't use non-temporal store if there is overlap between
+ destination and source since destination may be in cache
+ when source is loaded. */
+ leaq (%rdi, %rdx), %r10
+ cmpq %r10, %rsi
+ jb L(loop_4x_vec_forward)
/* Check non-temporal store threshold. */
cmpq __x86_shared_non_temporal_threshold(%rip), %rdx
ja L(loop_large_forward)
@@ -428,6 +434,12 @@ L(more_8x_vec_backward):
/* Adjust length. */
subq %r8, %rdx
#if (defined USE_MULTIARCH || VEC_SIZE == 16) && IS_IN (libc)
+ /* Don't use non-temporal store if there is overlap between
+ destination and source since destination may be in cache
+ when source is loaded. */
+ leaq (%rcx, %rdx), %r10
+ cmpq %r10, %r9
+ jb L(loop_4x_vec_backward)
/* Check non-temporal store threshold. */
cmpq __x86_shared_non_temporal_threshold(%rip), %rdx
ja L(loop_large_backward)
-----------------------------------------------------------------------
Summary of changes:
.../x86_64/multiarch/memmove-vec-unaligned-erms.S | 14 +++++++++++++-
1 files changed, 13 insertions(+), 1 deletions(-)
hooks/post-receive
--
GNU C Library master sources