Mail Archives: djgpp/1996/04/11/20:43:11
Reply to message 7605615 from ELIZ AT IS DOT ELTA. on 04/11/96 2:41AM
>What matters is not the total size of the allocated memory, but the number
>of independent allocations which live at any given moment. I doubt that
>any reasonable program has more than a hundred malloced regions
>simultaneously. The GNU C++ compiler that is the first DJGPP program to
>be known to hit that CWSDPMI limit (see the FAQ), reaches slightly more
>than 200 chunks when compiling some *really* large C++ programs.
I took a closer look at the code for the program as I was writing this
reply, and it turns out that I was slightly wrong. It does create several
tens of thousands of individual "objects", but it actually grabs the
memory one large block at a time and parcels it out in chunks, just
like you said. No wonder the damn thing runs so fast... :) Out of
curiosity, maybe I'll do some internal analysis to see exactly how many
times it actually calls calloc().
Thanks for the insights!
John
- Raw text -