Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Do not attempt to load code if mode is embedded
Erlang/OTP 25 only attempted to perform code loading if the mode was interactive: https://github.com/erlang/otp/blob/maint-25/lib/kernel/src/code_server.erl#L301 This check was removed in erlang#6736 as part of the decentralization. However, we received reports of increased cpu/memory usage in Erlang/OTP 26.1 in a code that was calling code:ensure_loaded/1 on a hot path. The underlying code was fixed but, given erlang#7503 added the server back into the equation for ensure_loaded we can add the mode check back to preserve Erlang/OTP 25 behaviour.
- Loading branch information