Re: Free memory_block pool

2019-11-21 Thread Richard Biener
On November 21, 2019 9:27:15 PM GMT+01:00, Jan Hubicka wrote: >Hi, >here is updated patch. Bootstrapped/regtested x86_64-linux, OK? Ok. Richard. >Honza > > * ggc-page.c (ggc_collect): Call memory_block_pool::trim. > * memory-block.cc (memory_block_pool::clear_free_list): Rename t

Re: Free memory_block pool

2019-11-21 Thread Jan Hubicka
Hi, here is updated patch. Bootstrapped/regtested x86_64-linux, OK? Honza * ggc-page.c (ggc_collect): Call memory_block_pool::trim. * memory-block.cc (memory_block_pool::clear_free_list): Rename to ... (memory_block_pool::reduce_free_list): ... this one. (memory_b

Re: Free memory_block pool

2019-11-21 Thread Jan Hubicka
> On Wed, 20 Nov 2019, Jan Hubicka wrote: > > > Hi, > > I have noticed that for Firefox around 1GB of peak memory use goes into > > the fact that we never free memory_block_pool::freelist. > > > > This patch adds memory_block_pool::trim which reduces freelist to a given > > size. It is called fr

Re: Free memory_block pool

2019-11-20 Thread Richard Biener
On Wed, 20 Nov 2019, Jan Hubicka wrote: > Hi, > I have noticed that for Firefox around 1GB of peak memory use goes into > the fact that we never free memory_block_pool::freelist. > > This patch adds memory_block_pool::trim which reduces freelist to a given > size. It is called from ggc_collect w

Re: Free memory_block pool

2019-11-20 Thread Jan Hubicka
> On 11/20/19 4:03 PM, Jan Hubicka wrote: > > I have noticed that for Firefox around 1GB of peak memory use goes into > > the fact that we never free memory_block_pool::freelist. > > Great, can you reduce the peak memory by the 1GB with the patch? About half of it, approx 0.5GB (8.3GB -> 7.8GB) j

Re: Free memory_block pool

2019-11-20 Thread Martin Liška
On 11/20/19 4:03 PM, Jan Hubicka wrote: I have noticed that for Firefox around 1GB of peak memory use goes into the fact that we never free memory_block_pool::freelist. Great, can you reduce the peak memory by the 1GB with the patch? Thanks, Martin