Commit 9d47333e authored by Michael Niedermayer's avatar Michael Niedermayer

Merge commit '2b379a92'

* commit '2b379a92':
  mlpdsp: x86: Respect cpuflags

Conflicts:
	libavcodec/x86/mlpdsp.c
Merged-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parents 50617fce 2b379a92
...@@ -20,7 +20,9 @@ ...@@ -20,7 +20,9 @@
*/ */
#include "libavutil/attributes.h" #include "libavutil/attributes.h"
#include "libavutil/cpu.h"
#include "libavutil/x86/asm.h" #include "libavutil/x86/asm.h"
#include "libavutil/x86/cpu.h"
#include "libavcodec/mlpdsp.h" #include "libavcodec/mlpdsp.h"
#include "libavcodec/mlp.h" #include "libavcodec/mlp.h"
...@@ -177,6 +179,8 @@ static void mlp_filter_channel_x86(int32_t *state, const int32_t *coeff, ...@@ -177,6 +179,8 @@ static void mlp_filter_channel_x86(int32_t *state, const int32_t *coeff,
av_cold void ff_mlpdsp_init_x86(MLPDSPContext *c) av_cold void ff_mlpdsp_init_x86(MLPDSPContext *c)
{ {
#if HAVE_7REGS && HAVE_INLINE_ASM #if HAVE_7REGS && HAVE_INLINE_ASM
int cpu_flags = av_get_cpu_flags();
if (INLINE_MMX(cpu_flags))
c->mlp_filter_channel = mlp_filter_channel_x86; c->mlp_filter_channel = mlp_filter_channel_x86;
#endif #endif
} }
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