Path: utzoo!censor!geac!alias!imax!watcgl!watserv1!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!swrinde!elroy.jpl.nasa.gov!decwrl!world!siegel From: siegel@world.std.com (Rich Siegel) Newsgroups: comp.sys.mac.programmer Subject: Re: Think C vs MPW C?? Message-ID: <1991Mar26.224716.29004@world.std.com> Date: 26 Mar 91 22:47:16 GMT References: <91082.152427ACPS5788@Ryerson.Ca> Organization: Symantec Language Products Group Lines: 23 In article (Stephen Z. Stein) writes: >This is a great puzzle. The THINK C code is running about 3 times faster >than the MPW code. Though I would expect THINK C to generate better >code than MPW for the loop, I doubt it would be a factor of three better! THINK C has better floating-point code generation, which is mostly due to the fact that in THINK C, 'double' is the SANE 'Extended' data type. Since there's no internal conversion going on, floating-point calculations and comparisons are much more efficient. MPW C's 'double' is the SANE 'double'. A long time ago, I did some timings, and discovered that using 80-bit reals was as much as four times faster as using 64-bit reals. R. -- ----------------------------------------------------------------------- Rich Siegel Internet: siegel@world.std.com Software Engineer Applelink: SIEGEL Symantec Languages Group