Mail Archives: djgpp/1997/08/04/05:35:23
Floats on regular Pentium and and Pentium Pro are as fast as fixeds. Float
to int conversion is super slow. Fixed to int conversion is fast. (It's a
single ML instruction, an octuple left shift or something of that sort.
Look in allegro.h where it is inlined.) If you convert a lot, use purely
floats even for "ints" unless you need to count on nonfractional values
(e.g. array subscripts, pixels), or used fixeds.
Also, Pentium Pro MMX and regular Cyrix 686 stink at floating point math.
(Intel must have dyked the floating accelerator stuff out to fit MMX in, and
Cyrix just plain stinks anyways. Cyrix MMX still stinks at floating point,
but it beats Intel MMX!)
--
.*. Where feelings are concerned, answers are rarely simple [GeneDeWeese]
-() < When I go to the theater, I always go straight to the "bag and mix"
`*' bulk candy section...because variety is the spice of life... [me]
Paul Derbyshire ao950 AT freenet DOT carleton DOT ca, http://chat.carleton.ca/~pderbysh
- Raw text -