[Gambas-user] How to audit memory consumption in Gambas project

Benoît Minisini g4mba5 at gmail.com
Tue Mar 13 19:51:42 CET 2018


Le 13/03/2018 à 18:44, Yahoo via User a écrit :
> Hello all,
> 
> I’m trying to figure why one of my project increase in the time his 
> memory consumption and where/what object(s) take all this memory.
> 
> I have tried ‘Object.SizeOf()’ but without success…
> 
> Is there way to figure it for a Gambas project in command line installed 
> on a server and without IDE.
> 
> Thank you for you advices.
> 
> Olivier Cruilles
> 

You have to find the "big loop" of your server, i.e. a point in your 
code where the used memory should be the same.

Then at that point you count the number of objects and prints it, using 
the Class.Count property, and make the difference with the previous loop 
to know how many objects of each class have been created or destroyed.

You will have a better view of what happens exactly.

-- 
Benoît Minisini


More information about the User mailing list