[XviD-devel] Quantization

Christoph Lampert chl at math.uni-bonn.de
Sun Jul 20 18:38:14 CEST 2003


On Sun, 20 Jul 2003, Marco Al wrote:
> BTW why does the C version even need to use the approximation of division by
> fixed point multipication by reciprocal? If it just used normal division it
> would make the intention of the code clearer.

Because even C version should care a little about performance in crucial
routines, e.g. for non-x86 plattforms. Integer division is the worst
you can do on many CPUs. The SGI compiler iirc even replaced it by
"convert to double, divide double, convert back" because that was at least
pipelined and ended up faster.

If we wanted XVID as a reference implementation only, we could create two
C versions of crucial routines: One for speed, one to get the idea.

gruel





More information about the XviD-devel mailing list