https://gcc.gnu.org/bugzilla/show_bug.cgi?id=124684

--- Comment #4 from Robert Dubner <rdubner at gcc dot gnu.org> ---
I concur.  The catastrophic 40,000-line case, on my system:

"-ggdb -O0" 7.3 seconds for both -fpie and -fno-pie.

"-O1" 2.3 seconds for both -fpie and -fno-pie.

So the patch seemingly addressed that problem.

While running those tests, I accidentally used "-ggdb -O1" and I noticed that
it increased compilation time.

When comparing N=10000 to N=20000:

"-ggdb -O1 -fpie" went from 4.4 seconds to 16.2 seconds
"-ggdb -O1 -fno-pie" went from 5.9 seconds to 23.8 seconds

So, without doing all the research again, that small sample certainly looks
quadratic.

The -ftime-report looks different.  The big items are 

Time variable                                  wall           GGC
 phase opt and generate             :  23.48 ( 98%)   125M ( 46%)
 callgraph ipa passes               :  22.94 ( 96%)    23M (  9%)
 tree CFG cleanup                   :  22.22 ( 93%)  1024k (  0%)
 TOTAL                              :  23.88          270M
Extra diagnostic checks enabled; compiler may run slowly.

Reply via email to