This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Suggestions for improving gcc 3.2 compilation speed?


>> Is the .pch just not being used?
>
>It's possible. 

I'm hoping that it's not being used, just from the timings.

I was hoping for a bit more info than this if possible. Like, should the
.pch file show up in -v -H? How is this debugged?

>You might want to check whether you're using a compiler that uses .pch
>or .gch as the PCH extension.

Apparently, mainline g++ on linux uses .pch by default. I tried to just
generate a pch as you've previously instructed and the output file has
.pch, not .gch. 

Perhaps you could try this yourself?

>Also, consider using the -Winvalid-pch flag.

Ummmm, yeah. Done and done. 

On mainline gcc, you can generate a precompiled C++ include for
libstdc++-v3 with relatively small effort. To recap:

cd bld/target/libstdc++-v3/include
make stamp-std-precompile

Also, at the suggestion of Mike Stump, I re-did the C++ includes to
first include stdc++.h. Then, I generated a stdc++.h.pch. That approach,
which is only a stylistic variation, can be found here:

http://gcc.gnu.org/ml/gcc-patches/2003-03/msg00694.html

I'm not quite sure what to do now.

-benjamin


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]