Re: enabling SSE for 3-vector inner product

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 29 Apr 2010, Qianqian Fang wrote:

Here is my SSE3 vec_dot

struct CPU_float4{
   float x,y,z,w;
}
typedef struct CPU_float4 pvec;

Shouldn't there be some magic here for alignment purposes?

now I am trying to use SSE4.x DPPS, but gcc gave me
error. I don't know if I used it with a wrong format.

Did you try using the intrinsic _mm_dp_ps?

               "dpps %%xmm0, %%xmm1, 0xF1 \n\t"

Maybe the order of the arguments is reversed in asm and it likes a $ before a constant (and it prefers fewer parentheses on the next line).

In any case, you shouldn't get a factor 2 compared to the SSE3 version, so that won't be enough for you.

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux