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

Re: talking about memory...

by primus (Scribe)
on Feb 09, 2003 at 18:52 UTC ( [id://233939]=note: print w/replies, xml ) Need Help??


in reply to talking about memory...


well, thanks for the replies, i suppose a more concrete response would be that on my win32 machine, i have a fairly simple program that fetches information from the internet and displays it in a gui format, and then will autoupdate off of the internet every 20 minutes or so.

right now with Tk, it peaks at using 11MB of memory and with win32::gui about 9MB of memory. these numbers just seem a little high for what this program has to accomplish.

i kinda just wanted to know what maybe an "average" gui program of a generic style... nothing fancy, would run at. i am not complaining, and i really do not wish to abruptly bring down that mem usage, i just want to know if that is acceptable.

Replies are listed 'Best First'.
Re^2: talking about memory...
by Solo (Deacon) on Feb 09, 2003 at 20:09 UTC
    Well, since you're using Win32, you should get PSTools from SysInternals and get a "better" profile of when/where your app is using memory. I've whipped up a demo of what I'm suggesting:

    C:\>perl -e "print grep(/Perl /,qx[pslist -m Perl])" Name Pid VM WS WS Pk Priv Faults NonP Page PageFile Perl 1632 28236 1416 1416 592 355 2 13 592 C:\>perl -MWin32::GUI -e "print grep(/Perl /,qx[pslist -m Perl])" Name Pid VM WS WS Pk Priv Faults NonP Page PageFile Perl 1516 34000 3200 3208 2680 802 3 17 2680 C:\>perl -MWin32::GUI -e "$main = Win32::GUI::Window->new(-name => 'Ma +in' , -width => 100, -height => 100);print grep(/Perl /,qx[pslist -m Perl] +)" Name Pid VM WS WS Pk Priv Faults NonP Page PageFile Perl 1632 34000 3240 3248 2684 812 3 17 2684

    By sprinkling pslist in your app and logging its output, you should get a better idea about what's going on. BTW, 'WS' is the number reported by Task Manager.

    Update: Added column headings to the pslist output for clarity.

    --
    Don't be too proud of this technological terror you've constructed...
Re: Re: talking about memory...
by CountZero (Bishop) on Feb 09, 2003 at 20:56 UTC

    It seems reasonable to assume that such GUI programs have a high "start-up"' cost in memory, but that adding a few extra buttons and other widgets will not increase the memory consumption in a linear way.

    CountZero

    "If you have four groups working on a compiler, you'll get a 4-pass compiler." - Conway's Law

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others scrutinizing the Monastery: (4)
As of 2024-04-25 19:38 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found