memory spikes during heap allocation
Thu Jun 18 17:35:52 CEST 2009
I have a program that gradually allocates more data on the heap. I have noticed that periodically erlang seems to allocate more space for my process. One strange thing, though, is that it appears when this happens there is a spike in memory usage that is only temporary. Sometimes these spikes can be quite large. I was wondering if there is any explanation for this. For example, does GC or heap allocation require a large amount of temporary work space?
I guess one good thing is that it appears it is mostly a spike in virtual memory; actual memory usage doesn't seem to spike nearly as much. I wonder if actual pages are being written to disk or if somehow they are just temporarily allocated and released without being written.
32346 jerickso 25 0 3394m 2.7g 2224 S 99.8 17.5 12:30.84 beam.smp
32346 jerickso 25 0 3412m 2.8g 2224 S 49.6 17.9 12:32.33 beam.smp
32346 jerickso 25 0 5040m 3.4g 2224 S 86.9 21.5 12:34.94 beam.smp <<<<<<---------- Here's a spike!!
32346 jerickso 25 0 3724m 2.7g 2224 S 72.9 17.5 12:37.13 beam.smp
32346 jerickso 25 0 3723m 2.8g 2224 S 34.3 17.7 12:38.16 beam.smp
More information about the erlang-questions