From 27af15dc5c7be828e5ac7052a7f6c4a285c8caee Mon Sep 17 00:00:00 2001 From: Diego Biurrun Date: Fri, 15 Feb 2008 14:58:18 +0000 Subject: prettyprinting cosmetics Originally committed as revision 11941 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavutil/bswap.h | 50 ++++++++++++++++++++++++-------------------------- 1 file changed, 24 insertions(+), 26 deletions(-) (limited to 'libavutil/bswap.h') diff --git a/libavutil/bswap.h b/libavutil/bswap.h index 850cbe3201..ee75f88c34 100644 --- a/libavutil/bswap.h +++ b/libavutil/bswap.h @@ -42,11 +42,11 @@ static av_always_inline uint16_t bswap_16(uint16_t x) { #if defined(ARCH_X86) - __asm("rorw $8, %0" : - LEGACY_REGS (x) : - "0" (x)); + __asm("rorw $8, %0" : + LEGACY_REGS (x) : + "0" (x)); #elif defined(ARCH_SH4) - __asm__("swap.b %0,%0":"=r"(x):"0"(x)); + __asm__("swap.b %0,%0":"=r"(x):"0"(x)); #else x= (x>>8) | (x<<8); #endif @@ -57,35 +57,33 @@ static av_always_inline uint32_t bswap_32(uint32_t x) { #if defined(ARCH_X86) #if __CPU__ != 386 - __asm("bswap %0": - "=r" (x) : + __asm("bswap %0": + "=r" (x) : #else - __asm("xchgb %b0,%h0\n" - " rorl $16,%0\n" - " xchgb %b0,%h0": - LEGACY_REGS (x) : + __asm("xchgb %b0,%h0\n" + "rorl $16,%0 \n" + "xchgb %b0,%h0": + LEGACY_REGS (x) : #endif - "0" (x)); + "0" (x)); #elif defined(ARCH_SH4) - __asm__( - "swap.b %0,%0\n" - "swap.w %0,%0\n" - "swap.b %0,%0\n" - :"=r"(x):"0"(x)); + __asm__("swap.b %0,%0\n" + "swap.w %0,%0\n" + "swap.b %0,%0\n" + :"=r"(x):"0"(x)); #elif defined(ARCH_ARM) uint32_t t; - __asm__ ( - "eor %1, %0, %0, ror #16 \n\t" - "bic %1, %1, #0xFF0000 \n\t" - "mov %0, %0, ror #8 \n\t" - "eor %0, %0, %1, lsr #8 \n\t" - : "+r"(x), "+r"(t)); + __asm__ ("eor %1, %0, %0, ror #16 \n\t" + "bic %1, %1, #0xFF0000 \n\t" + "mov %0, %0, ror #8 \n\t" + "eor %0, %0, %1, lsr #8 \n\t" + : "+r"(x), "+r"(t)); #elif defined(ARCH_BFIN) unsigned tmp; - asm("%1 = %0 >> 8 (V);\n\t" - "%0 = %0 << 8 (V);\n\t" - "%0 = %0 | %1;\n\t" - "%0 = PACK(%0.L, %0.H);\n\t" + asm("%1 = %0 >> 8 (V); \n\t" + "%0 = %0 << 8 (V); \n\t" + "%0 = %0 | %1; \n\t" + "%0 = PACK(%0.L, %0.H); \n\t" : "+d"(x), "=&d"(tmp)); #else x= ((x<<8)&0xFF00FF00) | ((x>>8)&0x00FF00FF); -- cgit v1.2.3