diff options
Diffstat (limited to 'libavcodec/x86/mathops.h')
-rw-r--r-- | libavcodec/x86/mathops.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/libavcodec/x86/mathops.h b/libavcodec/x86/mathops.h index 78f37f24eb..79e29e6232 100644 --- a/libavcodec/x86/mathops.h +++ b/libavcodec/x86/mathops.h @@ -101,6 +101,12 @@ __asm__ volatile(\ ); #endif +#define MASK_ABS(mask, level) \ + __asm__ ("cltd \n\t" \ + "xorl %1, %0 \n\t" \ + "subl %1, %0 \n\t" \ + : "+a"(level), "=&d"(mask)) + // avoid +32 for shift optimization (gcc should do that ...) #define NEG_SSR32 NEG_SSR32 static inline int32_t NEG_SSR32( int32_t a, int8_t s){ |