List Info

Thread: Re: Memory usage of GNUstep processes




Re: Memory usage of GNUstep processes
country flaguser name
United States
2007-12-14 11:07:19
>From: =?ISO8859-1?Q?Andreas_H=F6schler?= <ahoeschsmartsoft.de>
>Date: 2007/12/14 Fri AM 09:55:26 CST
>To: discuss-gnustepgnu.org
>Subject: Memory usage of GNUstep processes

>Hi all,
>
>I have a general memory usage question regarding GNUstep
applications. 
>My app allows users to fetch objects from a database.
The fetched raw 
>data is converted to Objective-C objects in memory.
These objects are 
>held in a dic. As the user continues to do fetches the
memory usages of 
>the process goes up:
>
>prstat
>    PID USERNAME  SIZE   RSS STATE  PRI NICE      TIME 
CPU PROCESS/NLWP
>  27357 paravici  423M  414M sleep   59    0   0:36:36
0.6% SmartClient/1
>...
>
>So far that is what I would expect. However, if the user
closes the 
>form the dic and all the Objective-C objects are
released. I would 
>expect memory usage to go down to 100M or so but it
stays at 423M. I 
>have made sure that dealloc on the objects is called.
>
>Shouldn't the process return memory to the operation
system so that we 
>see decreased figures in prstat? I am seeing this on
Solaris 10. I have 
>no idea whether this is Solaris or GNustep related or a
general memory 
>management issue under Unix operating systems.
>
>Thanks for you hints!
>
>   Andreas
>
>
>
>_______________________________________________
>Discuss-gnustep mailing list
>Discuss-gnustepgnu.org
>http://lists.gnu.org/mailman/listinfo/discuss-gnustep


>From the malloc (3c) man page on Solaris, second
paragraph of the description:

"After free() is executed, this space is made available
for further allocation by the application, though not
returned to the system. Memory is returned to the system
only upon termination of the application."

HTH

--Robert


_______________________________________________
Discuss-gnustep mailing list
Discuss-gnustepgnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnustep

Re: Memory usage of GNUstep processes
country flaguser name
Germany
2007-12-14 11:11:38
Hi Robert,

> "After free() is executed, this space is made
available for further 
> allocation by the application, though not returned to
the system. 
> Memory is returned to the system only upon termination
of the 
> application."

Thanks for this info!!! That is general unix behaviour or do
Solaris, 
MacOSX, Linux,... have a different flavour of handling these
kind of 
things?

Regards,

   Andreas




_______________________________________________
Discuss-gnustep mailing list
Discuss-gnustepgnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnustep

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )