aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator
AgeCommit message (Collapse)Author
2019-03-25erts: Include external msg in need of GCLukas Larsson
When many external messages suddenly appear in the mailbox the young gen size is adjusted accordingly but it was immediately shrunk as the data was not counted towards the shrink size. This commit includes the ext dist size in the shrink calculation which means that the decode of the external messages will not trigger as many GCs which means much better performance.
2019-03-25erts: Include dist header in return from dist_ctrl_get_dataLukas Larsson
2019-03-25erts: Fix so that exit/down terms stay aliveLukas Larsson
When the GC is run or the link/monitor node is deleted, the terms associated with it will also be deallocated so we have to make sure that we don't do any GCs and that all link/monitor nodes are copied onto the heap before the node is deallocated.
2019-03-25erts: Pending signals can be for free processesLukas Larsson
Since we no schedule free processes multiple times, pending signals can be from free as well as current processes.
2019-03-25erts: Fix faulty assert in reference_table_termLukas Larsson
2019-03-25erts: Adjust dist obuf size correctly after hdr finLukas Larsson
2019-03-25erts: Fix non-payload dist exit signalsLukas Larsson
When interacting with jinterface and erl_interface the old dist messages are used and they incorrectly used the external data.
2019-03-25erts: Always do trylock on proc locks when crash dumpingLukas Larsson
2019-03-25Fix tests to work better in debug emulatorLukas Larsson
2019-03-25erts: erts_factory_proc_init should not set hole markerLukas Larsson
Setting the hole marker in debug on the entire heap is very slow so instead we do it in erts_produce_heap.
2019-03-25erts: Skip heavy process tab tests in debug emuLukas Larsson
2019-03-25Revert "erts: Always run fds check after each testcase"Lukas Larsson
This reverts commit 1eb0a2c47edd036731ee1e4e4f7b5bdfc7d576fa.
2019-03-25erts: Always run fds check after each testcaseLukas Larsson
2019-03-25erts: Always stop any testnodes before testcase exitsLukas Larsson
This needs to be done in order for automatic fd leak checking to work properly.
2019-03-25erts: Add crash dumping of EXITING and FREE processesLukas Larsson
2019-03-25erts: Fix file desc leak in poll debug get_evtsLukas Larsson
2019-03-25erts: Fix verify_nc in distribution suiteLukas Larsson
When the calling process is trapping exits a stray message will end up in the mailbox which is problematic. This change uses a monitor instead.
2019-03-25erts: Fix atom16 testcase after dist frag implLukas Larsson
2019-03-25Revert "erts: Add debug dist obuf memory leak check"Lukas Larsson
This reverts commit f4c121b1d98bf3db7e6eecbb9fb5b292f2bc3bb0.
2019-03-25erts: Fix version error in erl_nif.hJohn Högberg
2019-03-22Merge branch 'sverker/enable-big-creation/OTP-15603'Sverker Eriksson
* sverker/enable-big-creation/OTP-15603: epmd: Support 32-bit creation values in local node erts: Robustify epmd reply function erts: Reject decoded local refs with too large first word erts: Fix bug in list_to_ref erl_interface: Remove old encoding of pid,port,refs erts: Remove old encoding of pids, ports and refs erts: Make DFLAG_BIG_CREATION mandatory
2019-03-22epmd: Support 32-bit creation values in local nodeSverker Eriksson
* Increase distribution version from 5 to 6 * Introduce new ALIVE2_X_RESP with 32-bit creation as reply to ALIVE2_REQ when sender dist version >= 6 * Still reply old ALIVE2_RESP with tiny creation 1..3 if sender dist version < 6.
2019-03-22erts: Reject decoded local refs with too large first wordSverker Eriksson
2019-03-22erts: Fix bug in list_to_refSverker Eriksson
First word must be less than (1 bsl 18) for local refs.
2019-03-22Suppress false positive warning in gcc 4.8.2Kjell Winblad
This commit suppresses the following warning in gcc 4.8.2: In file included from beam/bif.c:33:0: beam/bif.c: In function ‘iolist_size_1’: beam/bif.h:332:14: warning: ‘state_mref’ may be used uninitialized in this function [-Wmaybe-uninitialized] reg[0] = (A0); \ ^ beam/bif.c:2464:11: note: ‘state_mref’ was declared here Eterm state_mref;
2019-03-22beam_emu.c: Avoid triggering an assertion for the wrong reasonBjörn Gustavsson
Before 2d2e78ad6e66 that introduced tail-recursive calls of BIFs, the stack was guaranteed not to be empty when `erlang:raise/3` was called from the `catch` block of a `try` (because the `try` had set up a stack frame that would be deallocated after the `raise` call). Now the stack can be empty, so the ASSERT() call in next_catch() that checks that there is a continuation pointer at the top of the stack may fail. Move the ASSERT() call to after check for empty stack. While at it, also add a comment of the reason for the assertion.
2019-03-22Merge branch 'john/erts/fix-badarg-fixed_apply'John Högberg
* john/erts/fix-badarg-fixed_apply: erts: Include argument list on badarg in fixed_apply
2019-03-22Merge branch 'john/erts/unc-path-size-fix/OTP-15693'John Högberg
* john/erts/unc-path-size-fix/OTP-15693: erts: Fix incorrect UNC path length calculation
2019-03-22erts: Fix incorrect UNC path length calculationJohn Högberg
This didn't cause any issues for the most part since the path was still properly formed, but it broke down when appending the wildcards in file:list_dir/1. The ASSERT_PATH_FORMAT macro would have caught this in no time, but it went unnoticed because we don't run debug builds on Windows.
2019-03-21Merge 'sverker/master/enif_whereis_pid-dirty-dtor/OTP-15694'Sverker Eriksson
* sverker/master/enif_whereis_pid-dirty-dtor: erts: Add test of enif_whereis* from resource destructor erts: Simplify nif_SUITE:nif_whereis* tests erts: Schedule resource destructors always
2019-03-21erts: Remove old encoding of pids, ports and refsSverker Eriksson
Always encode with 32-bit creation value.
2019-03-21erts: Make DFLAG_BIG_CREATION mandatorySverker Eriksson
2019-03-21Merge branch 'maint'Rickard Green
* maint: Fix reception of resume signal on process executing dirty
2019-03-21Merge branch 'rickard/dist_ctrl_get_data/OTP-15617'Rickard Green
* rickard/dist_ctrl_get_data/OTP-15617: Testing of the example gen_tcp_dist module Add possibility to also get size of data from erlang:dist_ctrl_get_data()
2019-03-21erts: Include argument list on badarg in fixed_applyJohn Högberg
2019-03-21Merge pull request #2188 from bjorng/bjorn/tune-beam-3Björn Gustavsson
Tune BEAM instructions for the new compiler (part 3)
2019-03-21Merge branch 'bmk/20190320/esock/test_case_adjustements'Micael Karlberg
2019-03-21Merge branch 'bmk/20190318/temporary_fix_for_realtime_on_darwin'Micael Karlberg
2019-03-21Merge branch 'bmk/20190318/invalid_make_ref_at_sock_close'Micael Karlberg
2019-03-21Merge branch 'max-au/erts/dirty_scheduler_shutdown/PR-2172/OTP-15690'Lukas Larsson
* max-au/erts/dirty_scheduler_shutdown/PR-2172/OTP-15690: erts: release dirty runqueue lock before entering endless loop when BEAM is shutting down
2019-03-21erts: release dirty runqueue lock before entering endless loop when BEAM is ↵Maxim Fedorov
shutting down This patch fixes a problem happening when BEAM is shutting down. It is possible for a dirty scheduler to take the lock, and keep it, when the system is shutting down. It may also happen that a normal scheduler decides to schedule some dirty job (example is major garbage collection that results in migrating the process into dirty CPU queue), and hangs trying to take the lock that will never be released. To fix the problem, either release the lock before entering endless wait loop, or reverse the order in which schedulers are stopped. Either fix works, and, of course, it works even better to apply both.
2019-03-20Fix reception of resume signal on process executing dirtyRickard Green
If a suspend/resume signal pair was sent to a process while it was executing dirty the resume counter on the process got into an inconsistent state. This in turn could cause the process to enter a suspended state indefinitely.
2019-03-20Optimize moving of several Y registers to X registersBjörn Gustavsson
Introduce move_src_window[234] instructions for moving several consecutively numbered Y registers to discontiguously numbered X registers. This optimization is effective because the compiler has sorted the `move` instructions in Y register order.
2019-03-20[socket|test] Improve test case preconditionMicael Karlberg
Added a fun for precondition check run before each test case is actually run. The primary reason for this is the api_to_connect test case, which does not work for a number of platforms. Also, moved the IPv6 check into this fun (instead of an explicit skip in the test case fun) for the IPv6 test cases.
2019-03-20Merge branch 'sverker/nif-test-cuddle'Sverker Eriksson
2019-03-19Merge branch 'sverker/enif_whereis_pid-dirty-dtor'Sverker Eriksson
into sverker/master/enif_whereis_pid-dirty-dtor
2019-03-19Add possibility to also get size of data from erlang:dist_ctrl_get_data()Rickard Green
2019-03-19erts: Add test of enif_whereis* from resource destructorSverker Eriksson
2019-03-19erts: Simplify nif_SUITE:nif_whereis* testsSverker Eriksson
and change some argc checks from badarg to assert.
2019-03-19erts: Schedule resource destructors alwaysSverker Eriksson
to run user NIF code in a more known execution context. Fixes problems like user calling enif_whereis_pid() in destructor which may need to release process main lock in order to lock reg_tab.