[erlang-questions] Garbage Collection, BEAM memory and Erlang memory

Tony Rogvall tony@REDACTED
Fri Jan 23 13:55:40 CET 2015

> On 23 jan 2015, at 13:27, Roberto Ostinelli <roberto@REDACTED> wrote:
> Correct, however just after this call the process gets hibernated so Data (I assume) is getting gc'ed right away).

hibernate will garbage collect before going to sleep.

> On Fri, Jan 23, 2015 at 7:14 AM, Dan Gudmundsson <dangud@REDACTED <mailto:dangud@REDACTED>> wrote:
> Binary copy makes a new copy of the binary regardless of size, but it is only useful on ref-c binaries,
> and should be used to avoid keeping references to large binaries, when you keep and use a small part
> of the original binary. But in this case you make a copy of Data (-2 bytes) and thus will double up the memory until Data is gc'ed and refc reaches zero. So I do not see the point of the above nor of making it a list which will
> only explode your memory even more.
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20150123/f9900a14/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20150123/f9900a14/attachment.bin>

More information about the erlang-questions mailing list