[Ffmpeg-cvslog] r6715 - trunk/libavcodec/cabac.h
Rich Felker
dalias
Tue Oct 17 20:42:09 CEST 2006
On Tue, Oct 17, 2006 at 02:47:46AM +0200, Diego Biurrun wrote:
> On Tue, Oct 17, 2006 at 02:36:32AM +0200, Michael Niedermayer wrote:
> >
> > On Mon, Oct 16, 2006 at 11:47:19PM +0200, diego wrote:
> > >
> > > Log:
> > > Fix crash with illegal instruction, cmov is available on 686 and later only.
> > >
> > > --- trunk/libavcodec/cabac.h (original)
> > > +++ trunk/libavcodec/cabac.h Mon Oct 16 23:47:19 2006
> > > @@ -460,7 +460,7 @@
> > > "movl "LOW "(%2), %%ebx \n\t"
> > > //eax:state ebx:low, edx:range, esi:RangeLPS
> > > "subl %%esi, %%edx \n\t"
> > > -#ifdef CMOV_IS_FAST
> > > +#if (defined CMOV_IS_FAST && __CPU__ >= 686)
> >
> > IMHO CMOV_IS_FAST should not be defined in the first place if cmov isnt
> > available
> > (if its not available it cant be fast)
>
> It's not the cleanest solution, but I wanted to just avoid the crash
> for now. Once this whole CABAC optimization business is done we can
> implement a clean cmov detection if it's still necessary then.
I agree. Whenever code is left in a state that it doesn't compile or
compiles a crashing binary, IMO it's fine for anyone with write access
to commit a quick and dirty fix. The maintainer of the code is welcome
to convert it to a proper fix later.
Rich
More information about the ffmpeg-cvslog
mailing list