diff options
author | Martin Liska <mliska@suse.cz> | 2020-07-30 09:24:40 +0200 |
---|---|---|
committer | Giuliano Belinassi <giuliano.belinassi@usp.br> | 2020-08-17 13:20:21 -0300 |
commit | 98b66863f2b4752513b39fbe29f8334776ad0d9a (patch) | |
tree | e3bf69bdf737d57ecf7878365befe59c38878030 /gcc/fortran | |
parent | 11a630f20c766ffa91cfe323e02bb7a0e55e5cff (diff) | |
download | gcc-98b66863f2b4752513b39fbe29f8334776ad0d9a.zip gcc-98b66863f2b4752513b39fbe29f8334776ad0d9a.tar.gz gcc-98b66863f2b4752513b39fbe29f8334776ad0d9a.tar.bz2 |
Do not allocate huge array in output_in_order.
We noticed that when analyzing LTRANS memory peak that happens right
after the start:
https://gist.github.com/marxin/223890df4d8d8e490b6b2918b77dacad
In case of chrome, we have symtab->order == 200M, so we allocate
16B * 200M = 3.2GB.
gcc/ChangeLog:
* cgraph.h: Remove leading empty lines.
* cgraphunit.c (enum cgraph_order_sort_kind): Remove
ORDER_UNDEFINED.
(struct cgraph_order_sort): Add constructors.
(cgraph_order_sort::process): New.
(cgraph_order_cmp): New.
(output_in_order): Simplify and push nodes to vector.
Diffstat (limited to 'gcc/fortran')
0 files changed, 0 insertions, 0 deletions