[FFmpeg-cvslog] r14239 - trunk/libavutil/bswap.h

mru subversion
Tue Jul 15 21:05:53 CEST 2008


Author: mru
Date: Tue Jul 15 21:05:49 2008
New Revision: 14239

Log:
ARM: ARMv6 optimised bswap_16/32

Modified:
   trunk/libavutil/bswap.h

Modified: trunk/libavutil/bswap.h
==============================================================================
--- trunk/libavutil/bswap.h	(original)
+++ trunk/libavutil/bswap.h	Tue Jul 15 21:05:49 2008
@@ -40,6 +40,8 @@ static av_always_inline av_const uint16_
     asm("rorw $8, %0" : "+r"(x));
 #elif defined(ARCH_SH4)
     asm("swap.b %0,%0" : "=r"(x) : "0"(x));
+#elif defined(HAVE_ARMV6)
+    asm("rev16 %0, %0" : "+r"(x));
 #else
     x= (x>>8) | (x<<8);
 #endif
@@ -62,6 +64,8 @@ static av_always_inline av_const uint32_
         "swap.w %0,%0\n"
         "swap.b %0,%0\n"
         : "=r"(x) : "0"(x));
+#elif defined(HAVE_ARMV6)
+    asm("rev %0, %0" : "+r"(x));
 #elif defined(ARCH_ARM)
     uint32_t t;
     asm ("eor %1, %0, %0, ror #16 \n\t"




More information about the ffmpeg-cvslog mailing list