caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* [Caml-list] Memory usage of ocaml program
@ 2012-11-23  2:34 Chengqi Song
  2012-11-23  6:40 ` Gabriel Scherer
  2012-11-23 16:05 ` Gerd Stolpmann
  0 siblings, 2 replies; 4+ messages in thread
From: Chengqi Song @ 2012-11-23  2:34 UTC (permalink / raw)
  To: caml-list

[-- Attachment #1: Type: text/plain, Size: 600 bytes --]

I have the same program (same binary) running in different modes. From
GC stats I see they're using the same amount of heap now (209m) and
the stack is small. But in top's RES column, I see one is using 270m
memory and the other one is using 622m. Forcing heap compaction does
not change the numbers.

I don't quite understand this difference. A program's memory usage
should be code, static data, heap and stack. For the same binary, code
and static data segment should be the same, and now that GC stats
tells me heap and stack are the same, why there is a 352m difference
in memory usage?

Thanks

[-- Attachment #2: Type: text/html, Size: 658 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-11-23 16:05 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-11-23  2:34 [Caml-list] Memory usage of ocaml program Chengqi Song
2012-11-23  6:40 ` Gabriel Scherer
2012-11-23 15:29   ` Edgar Friendly
2012-11-23 16:05 ` Gerd Stolpmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).