[erlang-questions] Embedded vs Interactive - Why embedded?

Ryan <>
Thu Mar 10 21:18:55 CET 2016


On 03/10/2016 12:28 AM, Max Lapshin wrote:
> Have you ever looked in strace log when a moderate erlang system is 
> booting from flash on ARM? =)
>
I haven't, no. What would I see if I did?

Profiling is a huge question in my mind! To me, it seems that's going to 
be the biggest issue in the embedded/interactive debate, and I'm 
currently trying to figure out what are the important characteristics of 
our system that I should measure in trying to change from embedded to 
interactive.

> We (in flussonic) are not using embedded mode and don't use releases, 
> but we explicitly load all beams and it is faster then load them ondemand.
How long have you been running a non-embedded node? Have you done any 
comparisons between embedded and interactive mode?

The beam loading time is something I expected to be a notable difference 
between modes. Is the trouble with the actual loading of the bytecode or 
is it the time it takes to locate the beam file on the code path? Have 
you tried the "-code_path_cache" startup flag? It purports to make code 
lookup a constant-time operation: 
http://erlang.org/doc/man/code.html#id104406

When you say you "explicitly load all beams", how do you achieve that? 
Do you just use erlang:ensure_loaded(Module)? How do you come up with 
the list of modules to load eagerly? Boot script? App descriptor (.app) 
files? I'm very interested, because I expect I might want to do 
something similar.

Ryan


More information about the erlang-questions mailing list