[erlang-questions] erlang:system_monitor in production?

Roberto Aloi <>
Wed Apr 29 16:50:19 CEST 2015


Hi Roger,

Is it OK to have erlang:system_monitor permanently enabled in production?
>

One problem with `erlang:system_monitor/X` combined with an option such as
`long_gc`
is that, for each GC, the C equivalent of `erlang:now/0` - which has some
very well known overhead - is called before and after each GC:

https://github.com/erlang/otp/blob/feb45017da36be78d4c5784d758ede619fa7bfd3/erts/emulator/beam/erl_gc.c#L421

In other words, keeping long_gc monitoring enabled will add a couple of
sync points for each GC.

Disclaimer: It was not me discovering this, but a colleague, so not taking
any merit or blame for the discovery.

Roberto
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20150429/2a00bdc7/attachment.html>


More information about the erlang-questions mailing list