Commit 48aef27f authored by Luca Barbato's avatar Luca Barbato

x86: Put COPY3_IF_LT under HAVE_6REGS

It uses 6 registers, unbreaks building on hardened x86 system.

Bug-Id: gentoo/541930
CC: libav-stable@libav.org
parent 96dd0442
...@@ -23,7 +23,9 @@ ...@@ -23,7 +23,9 @@
#define AVCODEC_X86_MATHOPS_H #define AVCODEC_X86_MATHOPS_H
#include "config.h" #include "config.h"
#include "libavutil/common.h" #include "libavutil/common.h"
#include "libavutil/x86/asm.h"
#if HAVE_INLINE_ASM #if HAVE_INLINE_ASM
...@@ -88,6 +90,7 @@ static inline av_const int mid_pred(int a, int b, int c) ...@@ -88,6 +90,7 @@ static inline av_const int mid_pred(int a, int b, int c)
return i; return i;
} }
#if HAVE_6REGS
#define COPY3_IF_LT(x, y, a, b, c, d)\ #define COPY3_IF_LT(x, y, a, b, c, d)\
__asm__ volatile(\ __asm__ volatile(\
"cmpl %0, %3 \n\t"\ "cmpl %0, %3 \n\t"\
...@@ -97,6 +100,8 @@ __asm__ volatile(\ ...@@ -97,6 +100,8 @@ __asm__ volatile(\
: "+&r" (x), "+&r" (a), "+r" (c)\ : "+&r" (x), "+&r" (a), "+r" (c)\
: "r" (y), "r" (b), "r" (d)\ : "r" (y), "r" (b), "r" (d)\
); );
#endif /* HAVE_6REGS */
#endif /* HAVE_I686 */ #endif /* HAVE_I686 */
#define MASK_ABS(mask, level) \ #define MASK_ABS(mask, level) \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment