Avoid 3-way scrypt on AMD Bobcat

This commit is contained in:
pooler 2012-06-04 01:10:53 +02:00
parent 1608a0f1e4
commit d290e317be

View file

@ -49,11 +49,13 @@ _scrypt_best_throughput:
jne scrypt_best_throughput_not_amd
cmpl $0x68747541, %ebx
jne scrypt_best_throughput_not_amd
/* Check for AMD K8 */
/* Check for AMD K8 or Bobcat */
movl $1, %eax
cpuid
andl $0x0ff00000, %eax
jz scrypt_best_throughput_one
cmpl $0x00500000, %eax
je scrypt_best_throughput_one
movl $3, %eax
jmp scrypt_best_throughput_exit
scrypt_best_throughput_not_amd: