App RAM usage
Posted
#1
(In Topic #1504)
Regular

Posted
Regular

rj71 said
When you launch your <COLOR color="#80BF00">app</COLOR> from the Gambas IDE, the IDE shows you how much RAM your <COLOR color="#80BF00">app</COLOR> is using.
What? How? Where? Who?
I don't think there is anything apart from an instantaneous memory map dump that could tell you how much physical memory your <COLOR color="#FF0000">APPLICATION</COLOR> :x is using. And why would you care? That's what the OS is there for.
Memory usage reporting is a vague and mystical art practiced by the Unseen University and never published in a way that mortals could possibly understand.
I think if you are worried about how much something-or-other your application is using, as you described as "lots of images", then you should be more interested in how much file buffer space is being consumed by the process as they are loaded.
Some idea of this can be got from the buff/cache column reported by free -h. But also refer to ulimit -a to check what levels of resources are being allowed by your kernel.
I had a bit of a look through the IDE code to see if I could find what it is reporting in that little bar at the top of the debugger panel but gave up. So I can't even tell you what it thinks it's saying.
SO, in short, not to put a fine point on it, in summation, no there is no quick solution.
:cry:
b
Posted
Banned
Code
ps -o %cpu,%mem -p <pid>
Code (gambas)
check out the source for GambasProcWatch
Bruce Steers / gambasprocwatch · GitLab
it show mem and CPU usage of all running gambas programs using ps.
Posted
Banned
In Design.module / Public Sub TimerWatch_Timer()
(it uses the Pss field of the file called smaps_rollup in /proc/<pid>)
Code (gambas)
- $hTimerWatch.Stop
- ProcessMemory = 0
Posted
Regular

1 guest and 0 members have just viewed this.





