Questions tagged [memory-footprint]

Memory footprint refers to the amount of main memory that a program, application or service uses or references while running. The program itself does not make the largest contribution to the footprint, but rather their run-time data

Memory footprint includes all sorts of active memory regions like:

  • code segment containing program instructions (and occasionally constants)
  • data segment (both initialized and uninitialized)
  • heap memory
  • call stack

plus memory required to hold any additional data structures, such as:

  • symbol tables
  • debugging data structures
  • shared libraries mapped to the current process

that the program ever needs while executing and will be loaded at least once during its life cycle. Programs themselves often do not contribute the largest portions to their own memory footprints; rather, structures introduced by the run-time environment take up most of the memory.

74 questions
142
votes
7 answers

In-memory size of a Python structure

Is there a reference for the memory size of Python data stucture on 32- and 64-bit platforms? If not, this would be nice to have it on SO. The more exhaustive the better! So how many bytes are used by the following Python structures (depending on…
LeMiz
  • 5,554
  • 5
  • 28
  • 23
36
votes
9 answers

Java performance: true vs. Boolean.TRUE

Which of the following is better in terms of performance and efficient memory usage? Boolean isItTrue(arg){ return Boolean.TRUE; } boolean isItTrue(arg){ return Boolean.TRUE } Boolean isItTrue(arg){ return true; } boolean…
Dima
  • 1,774
  • 5
  • 21
  • 31
21
votes
5 answers

How is memory-efficient non-destructive manipulation of collections achieved in functional programming?

I'm trying to figure out how non-destructive manipulation of large collections is implemented in functional programming, ie. how it is possible to alter or remove single elements without having to create a completely new collection where all…
13
votes
3 answers

Tools to analyzing the memory footprint of native DLLs and assemblies loaded in a process?

I have a process holding 130MB of memory according to task manager, with only 11MB of live .NET objects according to dotTrace so I am wondering what's happening with the other 120MB?? I'd need a tool to list assemblies and native DLLs loaded in a…
Patrick from NDepend team
  • 13,237
  • 6
  • 61
  • 92
12
votes
4 answers

Do Java Records actually save memory over a similar class declaration or are they more like syntactic sugar?

I’m hoping that Java 14 records actually use less memory than a similar data class. Do they or is the memory using the same?
Clancy Merrick
  • 855
  • 1
  • 8
  • 16
12
votes
2 answers

Laravel Queue Worker Memory Footprint is Too Big :/

I am running a queue worker that connects to six MQs. When it is brought up, it consumes 25MB of RAM. That is with zero jobs on the queue, i.e. the worker is in a sleep state. I use Larvel for all of my projects, this particular project is purely…
mils
  • 1,878
  • 2
  • 21
  • 42
12
votes
2 answers

GCC vs Greenhills on ARM

I'm interested in any comparisons between GCC and Greenhills C compiler with regard to memory footprint of generated code specifically on ARM platforms. Are there any benchmarks or comparisons for these compilers? Has anyone had any experience here…
atikat
  • 367
  • 3
  • 11
10
votes
3 answers

What is the memory footprint of the JVM and how can I minimize it?

I just wanted to know what the actual footprint of the JavaVM (Sun, Linux) is when one starts to start to spawn multiple processes of JVMs. When I remember well those should share the rt.jar (and maybe beyond?). Does those JVM share the JIT cache…
Martin Kersten
  • 5,127
  • 8
  • 46
  • 77
9
votes
5 answers

Get memory and CPU usage

I would like to get the total physical memory, the CPU usage, and and the amount of memory being used. I have looked into Runtime.freeMemory(), but that isn't the free memory for the whole system.
Connor
  • 107
  • 1
  • 1
  • 2
7
votes
1 answer

How can I reduce the memory footprint of a minimal Linux process

Consider the following C program, 'pause.c': void main() { pause(); } Compiling this on x64 Linux 3.0.0-16-generic using this command 'gcc -Os pause.c -o pause' produces an executable of size ~8KB. When I run this executable and examine its precise…
Gearoid Murphy
  • 11,834
  • 17
  • 68
  • 86
7
votes
1 answer

python versus java runtime footprint

Can anyone point to serious comparison of Python runtime footprint versus Java? Thanks, Avraham
Avraham Leff
7
votes
5 answers

How to determine the size of PermGen within a Java application (i.e., programmatically)?

Is there any way to measure the currently used size of permanent generation (PermGen) within my Java application? I cannot use external profiling tools such as VisualVM. Even better would be an estimation of the memory consumption of a Java class…
s106mo
  • 1,243
  • 2
  • 14
  • 20
6
votes
3 answers

Recording Memory Footprint In Linux

Is there a way we can record memory footprint? In a way that after the process has finish we still can have access to it. The typical way I check memory footprint is this: $ cat /proc/PID/status But in no way it exist after the process has…
neversaint
  • 60,904
  • 137
  • 310
  • 477
6
votes
4 answers

Reduce Mongrel Rails Memory Footprint & Increase performance?

My rails sites run Mongrel, I am having a problem with the amount of memory being used. My ruby-bin processes are using up about 66 MB of resident memory. How can I reduce the amount of memory used by rails? It is not very economical to have many…
Kekoa
  • 27,892
  • 14
  • 72
  • 91
4
votes
2 answers

how to estimate RAM ROM usage from (Text data bss dec hex)

Hello is it possible to estimate the size of RAM and ROM used from text data bss dec hex filename 24823 0 920 25743 648f (TOTALS) I read on some blog "RAM = Data + bss" is that correct??. The target hardware…
Rishikesh Ayre
  • 99
  • 3
  • 14
1
2 3 4 5