[vlc-devel] commit: Add a CPU capability for ARM NEON ( Rémi Denis-Courmont )
git version control
git at videolan.org
Sat Sep 5 17:24:39 CEST 2009
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sat Sep 5 16:56:25 2009 +0300| [600d29043eed8f9c3e848dddb79bb0e2e9a0a391] | committer: Rémi Denis-Courmont
Add a CPU capability for ARM NEON
Currently, detection is done at build time. Feel free to add run-time
detect if you know how.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=600d29043eed8f9c3e848dddb79bb0e2e9a0a391
---
include/vlc_common.h | 1 +
src/misc/cpu.c | 3 +++
2 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/include/vlc_common.h b/include/vlc_common.h
index 8675ff8..f5829fe 100644
--- a/include/vlc_common.h
+++ b/include/vlc_common.h
@@ -798,6 +798,7 @@ VLC_EXPORT(int, vlc_wclosedir, ( void *_p_dir ));
#define CPU_CAPABILITY_SSE (1<<6)
#define CPU_CAPABILITY_SSE2 (1<<7)
#define CPU_CAPABILITY_ALTIVEC (1<<16)
+#define CPU_CAPABILITY_NEON (1<<24)
#define CPU_CAPABILITY_FPU (1<<31)
VLC_EXPORT( unsigned, vlc_CPU, ( void ) );
diff --git a/src/misc/cpu.c b/src/misc/cpu.c
index 5162294..ac42227 100644
--- a/src/misc/cpu.c
+++ b/src/misc/cpu.c
@@ -229,6 +229,9 @@ out:
# if defined( __ARM_EABI__ ) && !defined( __SOFTFP__ )
// i_capabilities |= CPU_CAPABILITY_FPU;
# endif
+# if defined( __ARM_NEON__ )
+ i_capabilities |= CPU_CAPABILITY_NEON;
+# endif
#elif defined( __powerpc__ ) || defined( __ppc__ ) || defined( __ppc64__ )
More information about the vlc-devel
mailing list