45 |
45 |
46 // Note: 'double' and 'long long' have 32-bits alignment on x86. |
46 // Note: 'double' and 'long long' have 32-bits alignment on x86. |
47 static jlong* double_quadword(jlong *adr, jlong lo, jlong hi) { |
47 static jlong* double_quadword(jlong *adr, jlong lo, jlong hi) { |
48 // Use the expression (adr)&(~0xF) to provide 128-bits aligned address |
48 // Use the expression (adr)&(~0xF) to provide 128-bits aligned address |
49 // of 128-bits operands for SSE instructions. |
49 // of 128-bits operands for SSE instructions. |
50 jlong *operand = (jlong*)(((long)adr)&((long)(~0xF))); |
50 jlong *operand = (jlong*)(((intptr_t)adr) & ((intptr_t)(~0xF))); |
51 // Store the value to a 128-bits operand. |
51 // Store the value to a 128-bits operand. |
52 operand[0] = lo; |
52 operand[0] = lo; |
53 operand[1] = hi; |
53 operand[1] = hi; |
54 return operand; |
54 return operand; |
55 } |
55 } |