Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister

Re: make perl release memory

by Jenda (Abbot)
on Jun 19, 2003 at 16:11 UTC ( #267262=note: print w/replies, xml ) Need Help??

in reply to make perl release memory

Ask them to look at the other processes. If I look at my processes I see four IEXPLORERs with 10-15MB, SiteView (in-house tool for web automation) 15 MB, ProductTranslator 14MB, svchost 10MB, DLLHOST 10MB, inetinfo 9MB, MCSHIELD 9MB, etc. etc. etc. etc.

Maybe it would also help if you told them that a VB program as small as this:

Sub Main() MsgBox "Ahoj Jendo", vbInformation, "Greeting" End Sub
takes up as much as 3MB of memory according to the Task Manager.

In either case I think the best solution would be to disable the Task Manager for those users ;-)

Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live.
   -- Rick Osborne

Edit by castaway: Closed small tag in signature

Replies are listed 'Best First'.
Re: Re: make perl release memory
by batkins (Chaplain) on Jun 19, 2003 at 17:37 UTC
    I've tried this argument as well, pointing out that iexplore often consumes more memory than my app. mysqld consumes around 40MB; opera takes about 25MB. I personally don't see much of a problem with these figures, so I think I may just have to give up on these users. If they're not willing to recognize that 25MB _isn't that bad_ then forget them. :)

    The other thing is that when I open new windows in my app (it's Tk-based) or perform certain actions, the memory increases slightly. I've personally never seen it go beyond 27MB, even after days of usage and hundreds of windows being opened. So I guess what I want to know is: is this indicative of a memory leak, or is it something I shouldn't worry about?

    This project can be downloaded from the link in my sig if anyone feels the need to test it out.

    Thanks for your answers, everyone!


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

      If you open and close the same window many times does the used memory keep growing? If not then there's no leak in that part. It's next to impossible to prove a program has no leaks (especialy in Perl), but if you run it for long and do not see a problem I don't think it's necessary to care much :-)

      As someone (sorry don't remember who) has in his/her signature: Worry only about the things you have to implement.

      Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live.
         -- Rick Osborne

      Edit by castaway: Closed small tag in signature

      I think it's fitting to mention when you say that 25Mb is not that bad that Milkbone (I'm assuming that's what you're talking about) is an instant messenger app. I remember before you re-tuned it, the memory usage was close to 100Mb. When I'd compare it to AIM/Yahoo/MSN, each of those used under 10Mb. And usually my AIM is only at about5-6Mb. Compared to that, the 25Mb footprint of Milkbone did seem like a lot.
      <aside>Anyways, I hope things have been well. Sorry I haven't kept up with *Mercury*, maybe I'll look at it when I get back to school.</aside>

      $will->code for @food or $$;

        Sheesh, that's enough to make me put on the Grumpy Old Guy hat. An IM app ought to weigh in at less than a 1M memory footprint, exclusive of logs. (Though if you have more than 100-200K of log data you may need to get out more :)

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (3)
As of 2022-01-26 08:28 GMT
Find Nodes?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:

    Results (69 votes). Check out past polls.