diff options
author | H.J. Lu <hongjiu.lu@intel.com> | 2010-01-12 11:22:03 -0800 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2010-01-12 11:22:03 -0800 |
commit | 3af48cbdfaeb8bc389de1caeb33bc29811da80e8 (patch) | |
tree | 94a209777ab8c7e24cff9e50660a4075e6338594 /sysdeps/x86_64/multiarch/init-arch.c | |
parent | 4bfc6ab9ae3b259caa8b12229f0c67b4b514e9cd (diff) | |
download | glibc-3af48cbdfaeb8bc389de1caeb33bc29811da80e8.tar.gz |
Optimize 32bit memset/memcpy with SSE2/SSSE3.
Diffstat (limited to 'sysdeps/x86_64/multiarch/init-arch.c')
-rw-r--r-- | sysdeps/x86_64/multiarch/init-arch.c | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/sysdeps/x86_64/multiarch/init-arch.c b/sysdeps/x86_64/multiarch/init-arch.c index 7823aceb9b..50b2a38fbd 100644 --- a/sysdeps/x86_64/multiarch/init-arch.c +++ b/sysdeps/x86_64/multiarch/init-arch.c @@ -64,7 +64,23 @@ __init_cpu_features (void) __cpu_features.model += extended_model; } else if (__cpu_features.family == 0x06) - __cpu_features.model += extended_model; + { + __cpu_features.model += extended_model; + switch (__cpu_features.model) + { + case 0x1a: + case 0x1e: + case 0x1f: + case 0x25: + case 0x2e: + case 0x2f: + /* Rep string instructions are fast on Intel Core i3, i5 + and i7. */ + __cpu_features.feature[index_Fast_Rep_String] + |= bit_Fast_Rep_String; + break; + } + } } /* This spells out "AuthenticAMD". */ else if (ebx == 0x68747541 && ecx == 0x444d4163 && edx == 0x69746e65) |