[AArch64] Fix strict aliasing issue in gcc.target/aarch64/simd/vminmaxnm_1.c
While doing some unrelated work the gcc.target/aarch64/simd/vminmaxnm_1.c testcase started failing for me. Upon investigation it turns out that it breaks the C strict aliasing rules in the CHECK macro by casting a pointer to an incompatible type and dereferencing it. GCC even warns about it if compiled with -Wstrict-aliasing. This patch fixes the testcase by making it use memcmp to compare the vector elements. This avoids the undefined behaviour. The testcase still passes on trunk. * gcc.target/aarch64/simd/vminmaxnm_1.c: Fix strict aliasing issues. From-SVN: r249972
Showing
Please
register
or
sign in
to comment