aboutsummaryrefslogtreecommitdiffstats
path: root/ref_vget_lane.c
diff options
context:
space:
mode:
Diffstat (limited to 'ref_vget_lane.c')
-rw-r--r--ref_vget_lane.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/ref_vget_lane.c b/ref_vget_lane.c
index ad3ae95..a1ab6a9 100644
--- a/ref_vget_lane.c
+++ b/ref_vget_lane.c
@@ -40,10 +40,16 @@ void exec_vget_lane (void)
fprintf(ref_file, "%" PRIx##W ", ", VAR(var, T1, W))
/* Special variant for floating-point */
+ union {
+ uint32_t var_int32;
+ float var_float32;
+ } var_int32_float32;
+
#define TEST_VGET_LANE_F(Q, T1, T2, W, N, L) \
VAR(var, T1, W) = vget##Q##_lane_##T2##W(VECT_VAR(vector, T1, W, N), L); \
vst1##Q##_##T2##W(VECT_VAR(result, T1, W, N), VECT_VAR(vector, T1, W, N)); \
- fprintf(ref_file, "%" PRIx##W ", ", *((uint##W##_t*)&VAR(var, T1, W)))
+ var_int##W##_float##W.var_float##W = VAR(var, T1, W); \
+ fprintf(ref_file, "%" PRIx##W ", ", var_int##W##_float##W.var_int##W)
/* With ARM RVCT, we need to declare variables before any executable
statement */