[Ffmpeg-devel] [PATCH] Snow mmx+sse2 asm optimizations

Robert Edele yartrebo
Tue Mar 14 00:15:24 CET 2006


On Mon, 2006-03-13 at 14:07 +0100, Michael Niedermayer wrote:
> Hi
> 
> On Mon, Mar 13, 2006 at 07:30:41AM -0500, Robert Edele wrote:
> > On Mon, 2006-03-13 at 03:54 +0100, Luca Barbato wrote:
> > > Robert Edele wrote:
> > > [...]
> > > 
> > > 
> > > @@ -1557,8 +1470,8 @@
> > >  STOP_TIMER("vertical_compose97i")}}
> > > 
> > >  {START_TIMER
> > > -        if(y-1<(unsigned)height) horizontal_compose97i(b0, width);
> > > -        if(y+0<(unsigned)height) horizontal_compose97i(b1, width);
> > > +        if(y-1<(unsigned)height) ff_snow_horizontal_compose97i(b0, width);
> > > +        if(y+0<(unsigned)height) ff_snow_horizontal_compose97i(b1, width);
> > > 
> > > 
> > > Why not dsputilize it too?
> > > 
> > A fair question. The reasoning is that only the encoder, which is not
> > sliced, uses this function. However, this should not be important for
> > horizontal and vertical compose so long as stride is aligned. The
> > regtest might very well not catch this error, so is stride in horizontal
> > and vertical compose 16-byte aligned?
> 
> hmm, maybe not, but if so thats a bug and should be fixed (= stride should
> be a multiple of 16)
> 
> [...]
> 
Stride is not aligned. I'm not very familiar with the code that would
have to be changed and I am afraid of making more bugs with a poorly
written patch. If someone else could fix this bug, it would be much
appreciated. If not, this code could be dsputilized later as it is only
used by the encoder and is a pretty small use of CPU cycles compared to
motion estimation.

Robert Edele





More information about the ffmpeg-devel mailing list