Re: perl use of malloc()

2000-04-20 Thread David McCabe

 From: Doug MacEachern [EMAIL PROTECTED]
 Date: Thu, 20 Apr 2000 14:04:09 -0700 (PDT)
 Subject: Re: shrinking memory (was Re: Modperl/Apache deficiencies... Memory usage.)
 
 On Tue, 18 Apr 2000, Stas Bekman wrote:
  
  What do you say? 1003520 bytes are returned to OS when @x goes out of
  scope. Note that this doesn't happen if you use a global @x instead.
 
 because under linux Perl defaults to system malloc:
 % perl -V:usemymalloc
 usemymalloc='n';

This implies that on another OS, the system malloc() might be different? Right??

 if usemymalloc='y', then Perl uses Perl's malloc, in which case memory is
 not returned to the os.

Now, does this mean that if usemyalloc='y', memory is not returned to the OS, no matter
what the OS is, or is this OS dependent as well??



David McCabe  Unix System Administrator
Le Groupe Videotron [EMAIL PROTECTED]   (514) 380 4433

"PHP is training wheels ... without the bike."
 Randal Schwartz, on comp.lang.perl.misc




Re: perl use of malloc()

2000-04-20 Thread Doug MacEachern

 This implies that on another OS, the system malloc() might be different?
 Right?? 

right.

 Now, does this mean that if usemyalloc='y', memory is not returned to
 the OS, no matter what the OS is

yes.