Refs #189. Fixed the bug of s/cdot about invalid reading NAN on x86_64.
authorZhang Xianyi <traits.zhang@gmail.com>
Fri, 25 Jan 2013 08:18:27 +0000 (16:18 +0800)
committerZhang Xianyi <traits.zhang@gmail.com>
Fri, 25 Jan 2013 12:56:14 +0000 (20:56 +0800)
kernel/x86_64/dot_sse.S
kernel/x86_64/zdot_sse.S

index 61c4810641975b7f8cd611f11d3007cea7bd5b8f..985ce9fec65c1a28c4fe2f266a393ebc409a30b9 100644 (file)
 #endif
        movsd   -32 * SIZE(Y), %xmm8
 
-       pshufd  $0x39, %xmm4,  %xmm5
+       pshufd  $0x29, %xmm4,  %xmm5
 
        mulps   %xmm8,  %xmm5
        addps   %xmm5,  %xmm3
        xorps   %xmm5, %xmm5
        movhlps %xmm4, %xmm5
 
-       mulps   -32 * SIZE(Y), %xmm5
+       movlps  -32 * SIZE(Y), %xmm4
+       mulps   %xmm4, %xmm5
        addps   %xmm5, %xmm0
 
        addq    $2 * SIZE, X
        movsd   -32 * SIZE(Y), %xmm8
 
        movss   %xmm5, %xmm4
-       shufps  $0x93, %xmm5,  %xmm4
+       shufps  $0x93, %xmm4,  %xmm4
 
        mulps   %xmm8,  %xmm4
        addps   %xmm4,  %xmm3
index 13804e0f829963e4174b634d6c422e14b21017f8..e2f153ab36d6be361b479e690a3c7385eb78e14f 100644 (file)
        movsd   -32 * SIZE(X), %xmm4
 
        pshufd  $0xb1,  %xmm4, %xmm12 
-       shufps  $0x39,  %xmm8, %xmm8
+       shufps  $0x59,  %xmm8, %xmm8
        mulps   %xmm8,  %xmm4
        addps   %xmm4,  %xmm0
        mulps   %xmm8,  %xmm12
 
        movss   %xmm9,  %xmm8
        pshufd  $0xb1,  %xmm4, %xmm12 
-       shufps  $0x93,  %xmm8, %xmm8
+       shufps  $0x03,  %xmm8, %xmm8
        mulps   %xmm8,  %xmm4
        addps   %xmm4,  %xmm0
        mulps   %xmm8,  %xmm12
        movsd   -32 * SIZE(Y), %xmm4
 
        pshufd  $0xb1,  %xmm4, %xmm12 
-       shufps  $0x39,  %xmm8, %xmm8
+       shufps  $0xa9,  %xmm8, %xmm8
        mulps   %xmm8,  %xmm4
        addps   %xmm4,  %xmm0
        mulps   %xmm8,  %xmm12
 
        movss   %xmm9,  %xmm8
        pshufd  $0xb1,  %xmm4, %xmm12 
-       shufps  $0x93,  %xmm8, %xmm8
+       shufps  $0x03,  %xmm8, %xmm8
        mulps   %xmm8,  %xmm4
        addps   %xmm4,  %xmm0
        mulps   %xmm8,  %xmm12