configura.ac: fix test for SSE2 & SSSE3 assembler support
authorOded Gabbay <oded.gabbay@gmail.com>
Tue, 15 Dec 2015 12:53:18 +0000 (14:53 +0200)
committerOded Gabbay <oded.gabbay@gmail.com>
Tue, 22 Dec 2015 09:19:01 +0000 (11:19 +0200)
commita566f627dbd6ea8f2cba70a446e62caaa2ecbd26
tree73ea02e2c99bc48c7e4e57965e7d8fd22d3a0ea1
parentd24b415f3e2753a588759d028b811e1ce38fea6c
configura.ac: fix test for SSE2 & SSSE3 assembler support

This patch modifies the SSE2 & SSSE3 tests in configure.ac to use a
global variable to initialize vector variables. In addition, we now
return the value of the computation instead of 0.

This is done so gcc 4.9 (and lower) won't optimize the SSE assembly
instructions (when using -O1 and higher), because then the configure test
might incorrectly pass even though the assembler doesn't support the
SSE instructions (the test will pass because the compiler does support
the intrinsics).

v2: instead of using volatile, use a global variable as input

Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
configure.ac