mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-11 13:30:02 -05:00
core: Add ARM NEON optimized sample conversion code
final: * includes some minor style fixes and build-time changes to allow building a single binary for neon and non-neon systems v4: * fix for sample length < 4 v3: * convert from intrinsics to inline assembly v2: * load and store data with vld1/vld1q and vst1/vst1q, resp., to work around alignment issues of compiler-generated vldmia instruction * remove redundant check for NEON flags Ubuntu/Linaro gcc 4.6.3 arm-linux-gnueabi-gcc -O2 -mcpu=cortex-a8 -mfloat-abi=softfp -mfpu=neon runtime on beagle-xm: D: [pulseaudio] sconv_neon.c: checking NEON sconv_s16le_from_float I: [pulseaudio] sconv_neon.c: NEON: 3754 usec. I: [pulseaudio] sconv_neon.c: ref: 58594 usec. D: [pulseaudio] sconv_neon.c: checking NEON sconv_s16le_to_float I: [pulseaudio] sconv_neon.c: NEON: 1831 usec. I: [pulseaudio] sconv_neon.c: ref: 10528 usec. I: [pulseaudio] sconv_neon.c: Initialising ARM NEON optimized conversions. conversion may be off by one for some samples due to rounding issues
This commit is contained in:
parent
4171df3019
commit
1319c4533a
6 changed files with 193 additions and 1 deletions
|
|
@ -26,6 +26,10 @@
|
|||
#include <stdint.h>
|
||||
#include <pulsecore/macro.h>
|
||||
|
||||
#ifndef PACKAGE
|
||||
#error "Please include config.h before including this file!"
|
||||
#endif
|
||||
|
||||
typedef enum pa_cpu_arm_flag {
|
||||
PA_CPU_ARM_V6 = (1 << 0),
|
||||
PA_CPU_ARM_V7 = (1 << 1),
|
||||
|
|
@ -41,4 +45,8 @@ pa_bool_t pa_cpu_init_arm(pa_cpu_arm_flag_t *flags);
|
|||
/* some optimized functions */
|
||||
void pa_volume_func_init_arm(pa_cpu_arm_flag_t flags);
|
||||
|
||||
#ifdef HAVE_NEON
|
||||
void pa_convert_func_init_neon(pa_cpu_arm_flag_t flags);
|
||||
#endif
|
||||
|
||||
#endif /* foocpuarmhfoo */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue