optimization (was: Re: swap(x,y))

kenny at m.cs.uiuc.edu kenny at m.cs.uiuc.edu
Sat Sep 23 09:23:28 AEST 1989


>(I wonder if SIGN is used in any FORTRAN program outside a test suite :-)

You betcha, and it's used outside Fortran, also.  There's no nice way
to do this one simply, either; you *don't* want to do a multiply just
to copy a sign.

I just grepped for copysign in the 4.3BSD math library, and found
fifty-odd uses there alone.

| /         o            Kevin Kenny                             (217) 333-5821
|<  /) |  | | |/\        Department of Computer Science           o  ,    o  ,
| \ X_  \/  | | |        University of Illinois                 40 07 N 88 13 W
kenny at cs.uiuc.edu        1304 W. Springfield Ave.       
uunet!uiucdcs!kenny      Urbana, IL   61801                  AD ASTRA PER ARDUA
k-kenny at uiuc.edu
kenny%cs at uiucvmd.bitnet



More information about the Comp.lang.c mailing list