Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucbvax!hoptoad!tim From: tim@hoptoad.uucp (Tim Maroney) Newsgroups: comp.sys.mac.programmer Subject: Re: Think's LSC generates slow code in comp with MPW C Message-ID: <8059@hoptoad.uucp> Date: 19 Jul 89 19:55:34 GMT References: <1630@eds.ericsson.se> Reply-To: tim@hoptoad.UUCP (Tim Maroney) Organization: Eclectic Software, San Francisco Lines: 19 In article <1630@eds.ericsson.se> rif_xu@eds.ericsson.se writes: > I have compiled the standard Byte benchmark Savage using > Think's LSC 3.01p4 on a MacII. I used the Math881lib and > the std881lib and had the flags for '881 and '020 code > generation set. It ran in 6 s. A version compiled in > MPW C 2.02 ran in 3.3 s. > Can anyone tell me why LSC generates so slow (MPW C is nearly > twice as fast) code ? Because MPW C does optimizing passes and Lightspeed C doesn't. MPW C puts everything it can in registers and does a number of the other standard optimizing tricks. Lightspeed C puts everything on the stack unless specifically commanded to put things in registers and does no optimizing tricks. It doesn't even use DBRAs. -- Tim Maroney, Mac Software Consultant, sun!hoptoad!tim, tim@toad.com "Religion flourishes in greater purity without than with the aid of government." -- James Madison