[FFmpeg-cvslog] r10241 - trunk/libavcodec/unary.h

Aurelien Jacobs aurel
Fri Aug 31 20:51:28 CEST 2007


On Fri, 31 Aug 2007 16:39:48 +0200
Vitor Sessak <vitor1001 at gmail.com> wrote:

> Hi
> 
> aurel wrote:
> > Author: aurel
> > Date: Mon Aug 27 00:34:49 2007
> > New Revision: 10241
> > 
> > Log:
> > cleanup get_unary()
> 
> [...]
> 
> > 
> > -#else
> > -  unsigned int buf;
> > -  int log;
> > -
> > -  OPEN_READER(re, gb);
> > -  UPDATE_CACHE(re, gb);
> > -  buf=GET_CACHE(re, gb); //Still not sure
> > -  if (stop) buf = ~buf;
> > -
> > -  log= av_log2(-buf); //FIXME: -?
> > -  if (log < limit){
> > -    LAST_SKIP_BITS(re, gb, log+1);
> > -    CLOSE_READER(re, gb);
> > -    return log;
> > -  }
> > -
> > -  LAST_SKIP_BITS(re, gb, limit);
> > -  CLOSE_READER(re, gb);
> > -  return limit;
> > -#endif
> >  }
> 
> Are you sure it is a good idea to remove the disabled code? It seems to 
> be the most efficient way to implement get_unary...

It's not removed... It's still there, in the svn history.
If you think this code is faster, send a patch to replace current
get_unary implementation along with benchmark results.

Aurel




More information about the ffmpeg-cvslog mailing list