[Lazarus] RE : RE : RE : RE : RE : RE : RE : RE : RE : RE : Console AppDevelopment
Ludo Brands
ludo.brands at free.fr
Tue Aug 16 10:46:14 CEST 2011
> > > With the
> > > GTK2 widgedset I see an increase in memory allocated by
> TCodeBuffer
> > > when opening/closing/reopening the same files.
> >
> > How much increase?
> >
> The test I did is the following:
> 1 Open lazarus with --skip-last-projet
> 2 File Open, select * files in fpc/packages/univint/.src (450
> files, 18M on
> disk)
> 3 close all editor files
> 4 repeat 2,3
> 5 repeat 2,3
> Looking at a valgrind massif trace I find
> -after step 2:
> 53M allocated through DOOPENUNKNOWNFILE (first time load)
> -after step 4:
> 53M allocated through DOOPENUNKNOWNFILE
> 16M allocated through DOOPENEDITORFILE (main.pp:9367
> reload file) -after step 5:
> 53M allocated through DOOPENUNKNOWNFILE
> 32M allocated through DOOPENEDITORFILE (main.pp:9367 reload file)
>
> There are intermediate samples and matching the massif
> samples with the steps taken isn't straightforward. The last
> sample taken has 53M+36M. The default timing is in
> instrictions, not in seconds. I'll have to retake the trace
> and time exactly the steps taken. I did make quit large
> pauses between steps but still...
>
> Ludo
>
Recompiled lazarus gtk2 with cmem and memory growth is almost gone. After
step 5 I have 3.4M allocated by DOOPENEDITORFILE (main.pp:9367 reload file).
Apparently the memory manager is holding on to large blocks.
Ludo
More information about the Lazarus
mailing list