shithub: mp3dec

Download patch

ref: eee0a840b3e35d0868ed19ccbceaf045031a36c8
parent: b9092374f230ebf9503fd1100a3950f858f8524e
author: lieff <[email protected]>
date: Wed Jan 31 12:44:56 EST 2018

fix neon code

--- a/minimp3.h
+++ b/minimp3.h
@@ -167,7 +167,8 @@
 #   define VMAC(a, x, y) vmlaq_f32(a, x, y)
 #   define VMSB(a, x, y) vmlsq_f32(a, x, y)
 #   define VMUL_S(x, s)  vmulq_f32(x, vmovq_n_f32(s))
-#   define VREV(x) vrev64q_f32(x)
+/*#   define VREV(x) vcombine_f32(vrev64_f32(vget_high_f32(x)), vrev64_f32(vget_low_f32(x)))*/
+#   define VREV(x) vcombine_f32(vget_high_f32(vrev64q_f32(x)), vget_low_f32(vrev64q_f32(x)))
 typedef float32x4_t f4;
 static int have_simd()
 {   /* TODO: detect neon for !MINIMP3_ONLY_SIMD */
--- a/scripts/build.sh
+++ b/scripts/build.sh
@@ -19,7 +19,7 @@
 -ffunction-sections -fdata-sections -Wl,--gc-sections -o minimp3_arm minimp3_test.c --specs=rdimon.specs -lm
 qemu-arm ./minimp3_arm
 
-#arm-none-eabi-gcc -O2 -g -std=c89 -Wall -Wextra -Wmissing-prototypes -Werror -fno-asynchronous-unwind-tables -fno-stack-protector \
-#-marm -mcpu=cortex-a15 -mfpu=neon -mfloat-abi=softfp \
-#-ffunction-sections -fdata-sections -Wl,--gc-sections -o minimp3_arm minimp3_test.c --specs=rdimon.specs -lm
-#qemu-arm ./minimp3_arm
+arm-none-eabi-gcc -O2 -g -std=c89 -Wall -Wextra -Wmissing-prototypes -Werror -fno-asynchronous-unwind-tables -fno-stack-protector \
+-marm -mcpu=cortex-a15 -mfpu=neon -mfloat-abi=softfp \
+-ffunction-sections -fdata-sections -Wl,--gc-sections -o minimp3_arm minimp3_test.c --specs=rdimon.specs -lm
+qemu-arm ./minimp3_arm