Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Re: make perl release memory

by batkins (Chaplain)
on Jun 19, 2003 at 14:59 UTC ( [id://267216]=note: print w/replies, xml ) Need Help??


in reply to Re: make perl release memory
in thread make perl release memory

How about Win32? Can't I just call free()?

milkbone - perl/tk instant messaging - it's the only way to fly

Replies are listed 'Best First'.
Re: Re: Re: make perl release memory
by gellyfish (Monsignor) on Jun 19, 2003 at 15:10 UTC

    Well, a cursory test of:

    main() { char *foo = (char *)malloc(1000000); getch(); free(foo); getch() }
    Examined in task manager would suggest not, of course this is highly unscientific and someone else might know different.

    /J\
    
Re: Re: Re: make perl release memory
by broquaint (Abbot) on Jun 19, 2003 at 15:08 UTC
    Using free(ptr) will just make available the memory pointed to by ptr in the process' memory pool, not to the OS at large. This memory freeing behaviour isn't Win32 specific, but applies to most modern OSes.
    HTH

    _________
    broquaint

Re: Re: Re: make perl release memory
by Elian (Parson) on Jun 19, 2003 at 17:24 UTC
    Perl already does.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://267216]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (7)
As of 2024-04-18 17:41 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found