using !

Stephen Clamage steve at taumet.com
Sat Dec 22 03:54:03 AEST 1990


heroux at cemmva.cem.msu.edu (Brett Heroux) writes:


>Is !(a > b) portable?

Yes.

>slower or faster than  a <= b?

Depends on the compiler and machine.  Many compilers will generate
identical code for both constructs.  You can look at the code your
compiler generates for each construct, and if they are different,
measure the time taken by each version.  If you choose one construct
on this basis, you must realize that the next compiler or machine you
use may not produce the same result.
-- 

Steve Clamage, TauMetric Corp, steve at taumet.com



More information about the Comp.lang.c mailing list