[Bug lto/41858] -flto -O2 crashes when many source files.

bstarynk at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Wed Oct 28 21:40:00 GMT 2009

------- Comment #1 from bstarynk at gcc dot gnu dot org  2009-10-28 21:40 -------
Created an attachment (id=18927)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=18927&action=view)
a small program which generates many files to exhibit the bug

The attached main.c file generates many files.

Put it in a new directory (empty).

Compile it with 
   gcc -O main.c -o main

Run it to generate many files, for example
  ./main 4000

it should display messages ending with

generated function #3904 in E_150
generated function #3968 in Q_152
generated 4000 files last is W_153.c
try to compile all 4000 files with:
         gcc-trunk -flto -O2 -DGENERATEDALL main.c [A-Z]*.c -o big

Now, run the suggest command (replacing gcc-trunk with what is appropriate for




More information about the Gcc-bugs mailing list