From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Berlin To: Phil Edwards Cc: Justin Guyett , Neil Booth , Gerald Pfeifer , Marc Espie , gcc@gcc.gnu.org Subject: Re: [GCC 3.0] Bad regression, binary size Date: Mon, 09 Jul 2001 16:43:00 -0000 Message-id: <87vgl1oehl.fsf@cgsoftware.com> References: <20010709212737.A19542@daikokuya.demon.co.uk> <20010709180015.A8502@disaster.jaj.com> X-SW-Source: 2001-07/msg00675.html Phil Edwards writes: > On Mon, Jul 09, 2001 at 02:54:21PM -0700, Justin Guyett wrote: >> I dunno about the 1minute+ helloworld compile time someone just suggested, >> but this is disturbing: >> (v2.95) g++ -o hello hello.cc 0.15s user 0.03s system 96% cpu 0.186 total >> (v3.0) g++ -o hello hello.cc 2.04s user 0.06s system 99% cpu 2.102 total >> >> if there's a 2 second loading overhead for g++v3, that's 2 seconds * (# >> files) which can be quite a lot in large trees. Is this simply from >> linking in the new libstdc++? > > Parsing the libstdc++ headers takes time, mostly because nearly all the > code is in the headers. Once we have 'export' this should be > better. This isn't the trouble, it's the inlining. We expand something from 300 insns to 15k insns, which itself takes time, memory, and then the backend has to deal with a lot more. Parsing took < 5 seconds on my example. It was the rest of compilation that took > 30 seconds. Without inlining, it took 5 seconds at -O3 total. There must be a happy medium. > > Phil > > -- > Would I had phrases that are not known, utterances that are strange, in > new language that has not been used, free from repetition, not an utterance > which has grown stale, which men of old have spoken. > - anonymous Egyptian scribe, c.1700 BC -- "I put tape on the mirrors in my house so I don't accidentally walk through into another dimension. "-Steven Wright