[FFmpeg-devel] [PATCH 1/2] lavc: define STRIDE_ALIGN as 32 when compiling with AVX support

Michael Niedermayer michaelni at gmx.at
Mon May 19 22:11:36 CEST 2014


On Mon, May 19, 2014 at 09:43:25AM -0400, Ronald S. Bultje wrote:
> Hi,
> 
> On Sun, May 18, 2014 at 8:59 PM, James Almer <jamrial at gmail.com> wrote:
> 
> > Signed-off-by: James Almer <jamrial at gmail.com>
> > ---
> >  libavcodec/internal.h | 4 +++-
> >  1 file changed, 3 insertions(+), 1 deletion(-)
> >
> > diff --git a/libavcodec/internal.h b/libavcodec/internal.h
> > index 603ffcf..948d006 100644
> > --- a/libavcodec/internal.h
> > +++ b/libavcodec/internal.h
> > @@ -35,7 +35,9 @@
> >
> >  #define FF_SANE_NB_CHANNELS 63U
> >
> > -#if HAVE_NEON || ARCH_PPC || HAVE_MMX
> > +#if HAVE_AVX
> > +#   define STRIDE_ALIGN 32
> > +#elif HAVE_NEON || ARCH_PPC || HAVE_MMX
> >  #   define STRIDE_ALIGN 16
> >  #else
> >  #   define STRIDE_ALIGN 8
> 
> 
> I'll be the first to admit this isn't very pretty, but it does the job and
> I can't think of anything better that doesn't add runtime constraints. So
> if others don't have strong objections or better ideas, I'd like this to be
> committed. It'll help a lot for future AVX/2 optimizations.

applied

thx

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Asymptotically faster algorithms should always be preferred if you have
asymptotical amounts of data
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20140519/5ab4cb0d/attachment.asc>


More information about the ffmpeg-devel mailing list