diff options
author | Christophe Lyon <christophe.lyon@st.com> | 2011-09-26 18:00:27 +0200 |
---|---|---|
committer | Christophe Lyon <christophe.lyon@st.com> | 2011-09-26 18:00:27 +0200 |
commit | c8aa0f690d4febd69842708d468673b7f2c99c25 (patch) | |
tree | d032a0de6dd6b5472d4e0280861903fc5369ca14 /ref_vabd.c | |
parent | ae97a862ad03f118f56e9b4d099f1fcf1d50c541 (diff) | |
download | platform_external_arm-neon-tests-c8aa0f690d4febd69842708d468673b7f2c99c25.tar.gz platform_external_arm-neon-tests-c8aa0f690d4febd69842708d468673b7f2c99c25.tar.bz2 platform_external_arm-neon-tests-c8aa0f690d4febd69842708d468673b7f2c99c25.zip |
Add more corner case tests.
Diffstat (limited to 'ref_vabd.c')
-rw-r--r-- | ref_vabd.c | 17 |
1 files changed, 17 insertions, 0 deletions
@@ -30,10 +30,13 @@ THE SOFTWARE. #endif #include "stm-arm-neon-ref.h" +#include <math.h> #define TEST_MSG "VABD/VABDQ" void exec_vabd (void) { + int i; + /* Basic test: v4=vabd(v1,v2), then store the result. */ #define TEST_VABD(Q, T1, T2, W, N) \ VECT_VAR(vector_res, T1, W, N) = \ @@ -113,4 +116,18 @@ void exec_vabd (void) TEST_VABD(q, float, f, 32, 4); dump_results_hex (TEST_MSG); + + + /* Extra FP tests with special values (-0.0, ....) */ + TEST_VDUP(vector1, q, float, f, 32, 4, -0.0f); + TEST_VDUP(vector2, q, float, f, 32, 4, 0.0); + TEST_VABD(q, float, f, 32, 4); + DUMP_FP(TEST_MSG " FP special (-0.0)", float, 32, 4, PRIx32); + + + /* Extra FP tests with special values (-0.0, ....) */ + TEST_VDUP(vector1, q, float, f, 32, 4, 0.0f); + TEST_VDUP(vector2, q, float, f, 32, 4, -0.0); + TEST_VABD(q, float, f, 32, 4); + DUMP_FP(TEST_MSG " FP special (-0.0)", float, 32, 4, PRIx32); } |