Home away from home
Joined: 2006/12/4 23:15 Last Login
: 10/14 16:04
Group:
Registered Users
|
Kas1e
There is no way that a call which extracts both the div and mod of a pair of numbers will be faster that one that only extracts the div
gcc can certainly optimise
int x,y,z;
z = x / y ;
more efficiently than
int x,y,z;
z = div(x,y)
and furthermore the example case you gave was hardly even a speed sensitive usage.
It's sensible to do it in stages, but for long term managable portable code, such platform specific calls should go.
|