vp8: Add ifdef guards around the sse2 loopfilter in the sse2slow branch too

Message ID 1341430124-55219-1-git-send-email-martin@martin.st
State Committed
Commit 07eeeb1d4fa6dea0fb3ad7cd11859db760a76528
Headers show

Commit Message

Martin Storsjö July 4, 2012, 7:28 p.m.
This was missed in the the previous commit in 70a1c800.
---
 libavcodec/x86/vp8dsp-init.c |    2 ++
 1 file changed, 2 insertions(+)

Comments

Ronald Bultje July 4, 2012, 9:03 p.m. | #1
Hi,

On Wed, Jul 4, 2012 at 12:28 PM, Martin Storsjö <martin@martin.st> wrote:
> This was missed in the the previous commit in 70a1c800.
> ---
>  libavcodec/x86/vp8dsp-init.c |    2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/libavcodec/x86/vp8dsp-init.c b/libavcodec/x86/vp8dsp-init.c
> index a0e8f9b..589804f 100644
> --- a/libavcodec/x86/vp8dsp-init.c
> +++ b/libavcodec/x86/vp8dsp-init.c
> @@ -389,11 +389,13 @@ av_cold void ff_vp8dsp_init_x86(VP8DSPContext* c)
>
>          c->vp8_v_loop_filter_simple = ff_vp8_v_loop_filter_simple_sse2;
>
> +#if ARCH_X86_64 || HAVE_ALIGNED_STACK
>          c->vp8_v_loop_filter16y_inner = ff_vp8_v_loop_filter16y_inner_sse2;
>          c->vp8_v_loop_filter8uv_inner = ff_vp8_v_loop_filter8uv_inner_sse2;
>
>          c->vp8_v_loop_filter16y       = ff_vp8_v_loop_filter16y_mbedge_sse2;
>          c->vp8_v_loop_filter8uv       = ff_vp8_v_loop_filter8uv_mbedge_sse2;
> +#endif
>      }

Oops - lgtm.

Ronald

Patch

diff --git a/libavcodec/x86/vp8dsp-init.c b/libavcodec/x86/vp8dsp-init.c
index a0e8f9b..589804f 100644
--- a/libavcodec/x86/vp8dsp-init.c
+++ b/libavcodec/x86/vp8dsp-init.c
@@ -389,11 +389,13 @@  av_cold void ff_vp8dsp_init_x86(VP8DSPContext* c)
 
         c->vp8_v_loop_filter_simple = ff_vp8_v_loop_filter_simple_sse2;
 
+#if ARCH_X86_64 || HAVE_ALIGNED_STACK
         c->vp8_v_loop_filter16y_inner = ff_vp8_v_loop_filter16y_inner_sse2;
         c->vp8_v_loop_filter8uv_inner = ff_vp8_v_loop_filter8uv_inner_sse2;
 
         c->vp8_v_loop_filter16y       = ff_vp8_v_loop_filter16y_mbedge_sse2;
         c->vp8_v_loop_filter8uv       = ff_vp8_v_loop_filter8uv_mbedge_sse2;
+#endif
     }
 
     if (mm_flags & AV_CPU_FLAG_SSE2) {