1. Re: Math Shortcuts
- Posted by Andy Kurnia <akur at DELOS.COM> Jul 05, 1998
- 712 views
At Sat, 4 Jul 1998 14:45:59 -0400, Robert Craig <rds at EMAIL.MSN.COM> wrote: >Intel also has a machine instruction for *rounding* a f.p. >number to the nearest integer. Unfortunately it can't be used >directly for floor(), which always rounds *down*. I don't understand the fp machine instructions, but if frndint N rounds i.5 to (i+1) and i.4999... to i (or so) then you can cheat by rounding (N-0.5) instead. Maybe this helps?

