[erlang-questions] why each erlang process sets 233 words as its default heap size?
Thu Sep 20 20:25:29 CEST 2007
On 20 sep 2007, at 18.03, Jeremy Chow wrote:
> Hi all,
> My first instinction is that it want to club together with
> one process size to reach exactly 1024 bytes . But each process
> has more than 1024/4 -233 = 23 words size .
> What's the author's original intention? why each erlang
> process sets 233 words as its default heap size?
The Erlang runtime system allocates memory for a process in
increments of Fibonacci numbers.
The rational is apparently that memory usage has a tendency to grow
like the Fibonacci numbers,
whether this really pays off is questionable but the code has been kept.
233 is a reasonably sized Fibonacci number and seems seemingly
randomly chosen as a good initial start size.
More information about the erlang-questions