Go Back   Science Forums > Physical Sciences Forums > Computer Science and Technology
Reply
 
LinkBack Thread Tools
Old 08-08-2007   #1 (permalink)
sanctus's Avatar
Resident Diabolist

Administrator

Location:
Geneva-Bern-Zürich, Switzerland;Oslo,Norway
 
sanctus has a brilliant futuresanctus has a brilliant futuresanctus has a brilliant futuresanctus has a brilliant futuresanctus has a brilliant futuresanctus has a brilliant futuresanctus has a brilliant futuresanctus has a brilliant future
 



Not Ranked  0 score     
Seeing what is taking the memory?

A program I modified and I run on the cluster of my uni goes in error because it uses too much memory.
If I go on the processors calculating for me then I type top I see that it gently grows up to RES=2Gb (i.e %MEM=100%) where the processors shut it down.
Now, I was wondering is there a way to see exactly what it is calculating? I mean top tells me it is running mc_general which is the whole program I'm running so not much help...


----------------
Administrator

A COUNTRY WITHOUT AN ARMY IS LIKE A FISH WITHOUT A BIKE!!!


I don't believe in god, but I do believe in what others call utopies.
Reply With Quote
Old 08-08-2007   #2 (permalink)
alexander's Avatar
Dedicated Smart-ass

Senior Moderator
Gallery Curator
Dev Team Member

Location:
Just before 0xAA55
 
alexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond repute
Send a message via AIM to alexander
 



Not Ranked  0 score     
Re: Seeing what is taking the memory?

the total footprint of the program. if you want to get more specific and see what exactly is growing, i would gdb the app and see which part of your code is not cleaning up after itself.... i can almost bet that you can stop it from using that much ram if you start dereferencing unused pointers

top just tells you which process is running and how much ram and processor it uses (btw i prefer htop for its coloring features)...

if you have problems with seeing all the procs running, like it only shows you user processes, i would sudo it


----------------
Microsoft, the leader in using innovative tactics to promote irksome experience, coupled with antiquated technology that's held together by a pyramid of makeshift afterthoughts.

Apple, the leader in using irksome tactics to promote innovative experience, coupled with an antiquated core that's enhanced by state-of-the-art afterthoughts.

Linux, the leader in not using any tactics to promote user-defined experience, coupled with state-of-the-art core enhanced by innovative afterthoughts.

Reply With Quote
Old 08-09-2007   #3 (permalink)
sanctus's Avatar
Resident Diabolist

Administrator

Location:
Geneva-Bern-Zürich, Switzerland;Oslo,Norway
 
sanctus has a brilliant futuresanctus has a brilliant futuresanctus has a brilliant futuresanctus has a brilliant futuresanctus has a brilliant futuresanctus has a brilliant futuresanctus has a brilliant futuresanctus has a brilliant future
 



Not Ranked  0 score     
Re: Seeing what is taking the memory?

Well, yes eventually I found those pointers...it was so stupid, there was a function finish() which call a function ridofpointerA() I expanded the program and added a pointerB and a function finish1() which still called ridofpointerA()
Took me two days to figure that out!


----------------
Administrator

A COUNTRY WITHOUT AN ARMY IS LIKE A FISH WITHOUT A BIKE!!!


I don't believe in god, but I do believe in what others call utopies.
Reply With Quote
Old 08-09-2007   #4 (permalink)
alexander's Avatar
Dedicated Smart-ass

Senior Moderator
Gallery Curator
Dev Team Member

Location:
Just before 0xAA55
 
alexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond reputealexander has a reputation beyond repute
Send a message via AIM to alexander
 



Not Ranked  0 score     
Re: Seeing what is taking the memory?

lol


----------------
Microsoft, the leader in using innovative tactics to promote irksome experience, coupled with antiquated technology that's held together by a pyramid of makeshift afterthoughts.

Apple, the leader in using irksome tactics to promote innovative experience, coupled with an antiquated core that's enhanced by state-of-the-art afterthoughts.

Linux, the leader in not using any tactics to promote user-defined experience, coupled with state-of-the-art core enhanced by innovative afterthoughts.

Reply With Quote
Old 08-09-2007   #5 (permalink)
Pyrotex's Avatar
Slaying Bad Memes

Moderator
Editor

Location:
Houston, Texas
Latest blog entry:
 
Pyrotex has a reputation beyond reputePyrotex has a reputation beyond reputePyrotex has a reputation beyond reputePyrotex has a reputation beyond reputePyrotex has a reputation beyond reputePyrotex has a reputation beyond reputePyrotex has a reputation beyond reputePyrotex has a reputation beyond reputePyrotex has a reputation beyond reputePyrotex has a reputation beyond reputePyrotex has a reputation beyond repute
Send a message via MSN to Pyrotex
 



Not Ranked  0 score     
Re: Seeing what is taking the memory?

Quote:
Originally Posted by alexander View Post
...i would gdb the app and ...start dereferencing unused pointers...top just tells you ...if you have problems with seeing all the procs running...i would sudo it
god I love it when you talk dirty


----------------
Hypography Forums Moderator
-- - - - - -
What concerns me is not the way things are, but rather the way people think things are.
Epictetus, Greek Philosopher
The map is NOT the territory.
Korzybski, Polish-American Philosopher
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
How much memory does he need? Switchy Computer Science and Technology 7 07-25-2007 01:50 PM
Anyone here taking up Liptoprin? ProfGlenda Introductions 1 12-09-2006 08:12 PM
Firefox is slowly taking away from IE alexander Computer Science and Technology 26 04-21-2005 04:19 PM

» Advertisement
» Current Poll
Who's the sexiest man alive? Johnny Depp or Robert Pattinson?
Johnny Depp - 27.27%
3 Votes
Robert Pattinson - 0%
0 Votes
Someone else (please specify) - 45.45%
5 Votes
I'm too macho to think a guy is sexy - 27.27%
3 Votes
Total Votes: 11
You may not vote on this poll.


All times are GMT -8. The time now is 09:37 PM.

Hypography?

Hypography [n.]: A combination of "hyperlink" and "bibliography" - ie, a list of links to electronic documents. Comparable to discography and bibliography, but not cartography.

We have been online since May 2000, and aim to be the best place to find and share science-related content of all kinds.

Share the love!

Please add more science to your life. Use our RSS feeds on your blog, your portal, or your favorite feedreader!


Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.2
Copyright © 2000-2009 Hypography
Part of the Hypography - Science for Everyone Network