https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87436
Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jakub at gcc dot gnu.org --- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Created attachment 45230 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=45230&action=edit gcc9-pr87436.patch The following patch addresses the memory consumption and to some extent compile time issue, but doesn't change what is emitted. Unpatched trunk: Time variable usr sys wall GGC phase setup : 0.00 ( 0%) 0.00 ( 0%) 0.01 ( 0%) 1355 kB ( 0%) phase parsing : 0.01 ( 0%) 0.00 ( 0%) 0.00 ( 0%) 638 kB ( 0%) phase opt and generate : 506.62 (100%) 2.20 (100%) 510.10 (100%)39325772 kB (100%) garbage collection : 4.84 ( 1%) 0.47 ( 21%) 5.36 ( 1%) 0 kB ( 0%) callgraph construction : 0.01 ( 0%) 0.00 ( 0%) 0.00 ( 0%) 5 kB ( 0%) ipa dead code removal : 0.01 ( 0%) 0.00 ( 0%) 0.01 ( 0%) 0 kB ( 0%) ipa icf : 2.06 ( 0%) 0.00 ( 0%) 2.06 ( 0%) 0 kB ( 0%) parser (global) : 0.01 ( 0%) 0.00 ( 0%) 0.00 ( 0%) 571 kB ( 0%) integration : 28.56 ( 6%) 0.00 ( 0%) 28.63 ( 6%) 2621665 kB ( 7%) tree gimplify : 7.33 ( 1%) 1.24 ( 56%) 8.58 ( 2%) 5244044 kB ( 13%) tree VRP : 0.01 ( 0%) 0.00 ( 0%) 0.01 ( 0%) 2 kB ( 0%) tree Early VRP : 63.00 ( 12%) 0.00 ( 0%) 63.16 ( 12%) 5243330 kB ( 13%) tree PTA : 0.01 ( 0%) 0.00 ( 0%) 0.01 ( 0%) 0 kB ( 0%) tree CCP : 33.00 ( 7%) 0.00 ( 0%) 33.09 ( 6%) 2621664 kB ( 7%) tree PRE : 43.59 ( 9%) 0.00 ( 0%) 43.70 ( 9%) 2621665 kB ( 7%) tree FRE : 92.77 ( 18%) 0.00 ( 0%) 93.02 ( 18%) 7864992 kB ( 20%) tree forward propagate : 200.09 ( 39%) 0.01 ( 0%) 200.62 ( 39%)13108320 kB ( 33%) tree conservative DCE : 0.02 ( 0%) 0.00 ( 0%) 0.01 ( 0%) 0 kB ( 0%) tree loop optimization : 0.00 ( 0%) 0.00 ( 0%) 0.01 ( 0%) 0 kB ( 0%) expand : 1.80 ( 0%) 0.00 ( 0%) 1.80 ( 0%) 5 kB ( 0%) integrated RA : 0.09 ( 0%) 0.00 ( 0%) 0.10 ( 0%) 24 kB ( 0%) final : 29.41 ( 6%) 0.47 ( 21%) 29.92 ( 6%) 1 kB ( 0%) rest of compilation : 0.02 ( 0%) 0.01 ( 0%) 0.01 ( 0%) 2 kB ( 0%) TOTAL : 506.63 2.20 510.11 39327775 kB Patched trunk: Time variable usr sys wall GGC phase setup : 0.00 ( 0%) 0.14 ( 15%) 0.14 ( 0%) 1355 kB ( 64%) phase opt and generate : 27.58 (100%) 0.49 ( 53%) 28.11 ( 92%) 112 kB ( 5%) phase finalize : 0.01 ( 0%) 0.29 ( 32%) 2.26 ( 7%) 0 kB ( 0%) final : 27.57 (100%) 0.49 ( 53%) 28.10 ( 92%) 1 kB ( 0%) initialize rtl : 0.01 ( 0%) 0.00 ( 0%) 0.01 ( 0%) 12 kB ( 1%) TOTAL : 27.59 0.92 30.51 2116 kB