Signed-off-by: Diego Biurrun <diego@biurrun.de>
Signed-off-by: Martin Storsjö <martin@martin.st>
rdtsc
round
roundf
+ rweflags
sched_getaffinity
sdl
sdl_video_size
check_code ld immintrin.h "__xgetbv(0)" && enable xgetbv
check_code ld intrin.h "int info[4]; __cpuid(info, 0)" && enable cpuid
check_code ld intrin.h "__rdtsc()" && enable rdtsc
+ check_code ld intrin.h "unsigned int x = __readeflags()" && enable rweflags
check_code ld mmintrin.h "_mm_empty()" && enable mm_empty
} while (0)
#endif /* HAVE_XGETBV */
+#if HAVE_INLINE_ASM
+
#define get_eflags(x) \
__asm__ volatile ("pushfl \n" \
"pop %0 \n" \
"popfl \n" \
:: "r"(x))
+#elif HAVE_RWEFLAGS
+
+#include <intrin.h>
+
+#define get_eflags(x) \
+ x = __readeflags()
+
+#define set_eflags(x) \
+ __writeeflags(x)
+
+#endif /* HAVE_INLINE_ASM */
+
/* Function to test if multimedia instructions are supported... */
int ff_get_cpu_flags_x86(void)
{