[cairo] Patches for speeding up _cairo_fixed_from_double

Daniel Amelang daniel.amelang at gmail.com
Thu Nov 16 14:49:06 PST 2006


On 11/8/06, Jim Gettys <jg at laptop.org> wrote:
> On Mon, 2006-11-06 at 16:13 -0800, Carl Worth wrote:
>
> >
> > Does anybody have a good reason that cairo should work with the FPU in
> > single-precision mode?
> >
> > Until someone speaks up there, I suggest we eliminate the current
> > comment and replace it with a sentence in the manual and in NEWS (for
> > sake of the next release) officially making single-precision mode
> > unsupported.
>
> I speak up.
>
> On some/many machines, single precision is much faster than double
> precision (e.g. the Geode).

This fact alone isn't an argument against eliminating
single-precision. If we can make Cairo on a Geode (or any processor)
run faster in double-precision mode than in single-precision mode,
that fact is irrelevant. Using this double->fixed trick speeds up a
critical section of Cairo in a way that may very well make up for
slower float arithmetic elsewhere.

Dan


More information about the cairo mailing list