aboutsummaryrefslogtreecommitdiffstats
path: root/erts
AgeCommit message (Collapse)Author
2015-06-10Merge branch 'rickard/timer-improvement/OTP-12650'Rickard Green
* rickard/timer-improvement/OTP-12650: Callback timer Disable accessor timer option Aux work flag descriptions Fix test cases
2015-06-10Merge branch 'rickard/lost-multi-aux-work/OTP-12812'Rickard Green
* rickard/lost-multi-aux-work/OTP-12812: Fix lost aux work flags when setting multiple flags
2015-06-10Delayed node table GCRickard Green
2015-06-10Merge branch 'egil/fix-purge-literals/OTP-12821'Björn-Egil Dahlberg
* egil/fix-purge-literals/OTP-12821: erts: Fix garbage collect literals in code purge
2015-06-10erts: Add test for module_info on purged modulesBjörn-Egil Dahlberg
2015-06-10erts: Remove ?line macros from module_info_SUITEBjörn-Egil Dahlberg
2015-06-10Fix segfault in module_info for deleted modulesRichard Carlsson
Add a check to protect from segfault when erlang:get_module_info/1/2 is called on a deleted module (i.e. with no current code). Also refactor erts_module_info_0/1 to avoid repeated calls to erts_active_code_ix() and remove some obsolete comments. Add test for module_info on deleted modules.
2015-06-10Merge branch 'nybek/fix_inet_drv_add_multi_timer_logic'Henrik Nord
* nybek/fix_inet_drv_add_multi_timer_logic: Fix add_multi_timer() in inet_drv Fix 6 tests in gen_tcp_misc_SUITE OTP-12817
2015-06-09Fix socket option {linger, {true, 0}} to abort TCP connectionsRory Byrne
Up until now, if {linger, {true, 0}} is set on the socket and there is data in the port driver queue, the connection is not aborted until the port queue is empty and close() is called on the underlying file descriptor. This bug allows an idle TCP client to prevent a server from terminating the connection and freeing resources. This patch fixes the problem by discarding the port queue if the socket is closed when {linger, {true, 0}} is set.
2015-06-09Apply 'show_econnreset' socket option to send errors as wellRory Byrne
Up till now all send errors have been translated into a generic {error, closed}. This patch allows {error, econnreset} to be returned on send errors when it is detected that the TCP peer has sent an RST.
2015-06-09Add 'show_econnreset' TCP socket optionRory Byrne
An ECONNRESET is a socket error which tells us that a TCP peer has sent an RST. The RST indicates that they have aborted the connection and that the payload we have received should not be considered complete. Up until now, the implementation of TCP in inet_drv.c has hidden the receipt of the RST from the user, treating it as though it was just a FIN terminating the read side of the socket. There are many cases where user code needs to be able to distinguish between a socket that was closed normally and one that was aborted. Setting the option {show_econnreset, true} enables the user to receive ECONNRESET errors on both active and passive sockets. A connected socket returned from gen_tcp:accept/1 will inherit the show_econnreset setting of the listening socket. By default this option is set to {show_econnreset, false}. Note that this patch only enables the reporting of ECONNRESET when the socket is being read from. It does not report ECONNRESET (or EPIPE) when the user tries to write to a connection when an RST has already been received. Currently the TCP implementation in inet_drv.c hides all such send errors from the user in favour of returning {error, close}. A separate patch will be needed to enable the reporting of such errors.
2015-06-09Only read lock node table when reading infoRickard Green
2015-06-09Callback timerRickard Green
2015-06-09Disable accessor timer optionRickard Green
2015-06-09Aux work flag descriptionsRickard Green
2015-06-09Fix test casesRickard Green
2015-06-09erts: Tweak statistics_SUITE:scheduler_wall_time/1Björn-Egil Dahlberg
2015-06-08Fix lost aux work flags when setting multiple flagsRickard Green
All flags was not always set when setting multiple aux work flags at once. This scenario is fortunately quite uncommon and only caused further delay in memory deallocations.
2015-06-08erts: Refactor arg swapping for maps:mergeSverker Eriksson
2015-06-08Merge branch 'egil/fix-internal_hash-list-opt'Björn-Egil Dahlberg
* egil/fix-internal_hash-list-opt: erts: Fix faulty list optimization in make_internal_hash
2015-06-08erts: Fix faulty list optimization in make_internal_hashBjörn-Egil Dahlberg
Reported-by: Rory Byrne
2015-06-05Add forgotten argument to example in erl_nif docTomas Abrahamsson
In the documentation for erl_nif, in the map iterator example, the iterator argument was forgotten in the call to function enif_map_iterator_create. This is now fixed.
2015-06-05Merge branch 'henrik/typo-fix-branch'Henrik Nord
* henrik/typo-fix-branch: Fixing typo
2015-06-05Reorder scheduler information in crashdumpsDan Gudmundsson
To make it easier to parse stack trace information from tools
2015-06-04Fix add_multi_timer() in inet_drvRory Byrne
Fix the sorting logic in add_multi_timer() and expand the test case coverage around this area.
2015-06-04Merge branch 'egil/cuddle-tests'Björn-Egil Dahlberg
* egil/cuddle-tests: erts: Remove remaining ?line macros in trace_meta_SUITE erts: Relax trace_meta_SUITE:on_and_off_test/1 erts: Remove ?line macro in trace_meta_SUITE:on_and_off_test/1 kernel: Remove remaining ?line macros in gen_tcp_misc_SUITE kernel: Relax gen_tcp_misc_SUITE don't wait for timeout kernel: Relax test gen_tcp_misc_SUITE:wrapping_oct/1
2015-06-04erts: Remove remaining ?line macros in trace_meta_SUITEBjörn-Egil Dahlberg
Also, fixed some confusing indentations and whitespace errors. This commit only has whitespace changes and removal of ?line macros.
2015-06-04erts: Relax trace_meta_SUITE:on_and_off_test/1Björn-Egil Dahlberg
2015-06-04erts: Remove ?line macro in trace_meta_SUITE:on_and_off_test/1Björn-Egil Dahlberg
2015-06-03Merge commit fixing typoHenrik Nord
Thanks to Nathanael Bartley
2015-06-03Merge branch 'jh/freebsdcpu/OTP-12796'Björn-Egil Dahlberg
* jh/freebsdcpu/OTP-12796: os_mon: Comply with C89 standard os_mon: Update docs for FreeBSD os_mon: Implement cpu_sup:util/0,1 for FreeBSD
2015-06-02erts: Add save/restore for PSTACKSverker Eriksson
2015-06-02Merge branch 'nybek/fix_gen_tcp_shutdown'Zandra Hird
OTP-12797
2015-06-01erts: Fix magic binary alignment on 32-bitSverker Eriksson
Caused bus error on 32-bit sparc from unaligned 64-bit word in binary_to_term trap context. Also add _UNALIGNED_ magic macros to avoid double alignment padding in NIF resources.
2015-06-01Merge branch 'vinoski/enif-raise-exception/OTP-12770'Sverker Eriksson
* vinoski/enif-raise-exception/OTP-12770: Add enif_raise_exception Enhance enif_has_pending_exception Fix for enif_schedule_nif and exceptions Conflicts: erts/doc/src/erl_nif.xml
2015-06-01Merge branch 'sverk/nif-map-docs'Sverker Eriksson
* sverk/nif-map-docs: erts: Cleanup fsummary lines in erl_nif docs erts: Fix alphabetic order in erl_nif doc erts: Add docs for map functions in nif API erts: Rename ErlNifMapIteratorEntry enums
2015-05-29Merge branch 'legoscia/dialyzer/cache-hipe-binaries/OTP-12779'Björn Gustavsson
* legoscia/dialyzer/cache-hipe-binaries/OTP-12779: Dialyzer to cache results of HiPE compilation Change hipe_bifs:system_crc/1 to hipe_bifs:system_crc/0
2015-05-28erts: Cleanup fsummary lines in erl_nif docsSverker Eriksson
by removing all full stop.
2015-05-28erts: Fix alphabetic order in erl_nif docSverker Eriksson
enif_make_reverse_list was at the wrong place
2015-05-28erts: Add docs for map functions in nif APISverker Eriksson
2015-05-28Merge branch 'richcarl/warnings-by-default/OTP-12781'Björn-Egil Dahlberg
* richcarl/warnings-by-default/OTP-12781: stdlib: Use warning channel in test qlc_SUITE:otp_6964/1 stdlib: Fix testcase for qlc_SUITE kernel: Fix code_SUITE with respect to new logger default Map error logger warnings to warning messages by default
2015-05-27Change hipe_bifs:system_crc/1 to hipe_bifs:system_crc/0Magnus Henoch
The macro HIPE_SYSTEM_CRC used to contain a hidden cookie from the VM that generated hipe_literals.hrl. This means that BEAM files containing that macro would be tied to a particular version of the VM. Change hipe_bifs:system_crc such that it doesn't require a hidden cookie to return the desired value.
2015-05-27erts: Rename ErlNifMapIteratorEntry enumsSverker Eriksson
To differentiate between first/last map entry and head/tail which is before/after first/last map entry.
2015-05-26Add enif_raise_exceptionSteve Vinoski
Add enif_raise_exception function to allow NIFs to raise error exceptions holding any Erlang terms. This does not replace or deprecate the enif_make_badarg function, though, because raising badarg errors is so idiomatic in NIFs. Reimplement enif_make_badarg on top of enif_raise_exception. Add new tests for enif_raise_exception for both normal and dirty NIFs. Add documentation for enif_raise_exception.
2015-05-26Enhance enif_has_pending_exceptionSteve Vinoski
Sverker Eriksson came up with the following idea: to handle a future ability for NIFs to raise more than just badarg exceptions, modify the recently-added enif_has_pending_exception function to take a second argument: a pointer to ERL_NIF_TERM. If this argument is a null pointer, ignore it. Otherwise, if the first argument, an ErlNifEnv*, has an associated exception, set the pointed-to ERL_NIF_TERM of the second argument to the value of the exception term. Add new tests and documentation for this modification.
2015-05-26Fix for enif_schedule_nif and exceptionsSteve Vinoski
Fix a place where part of the implementation of enif_schedule_nif was not using the ErlNifEnv exception_thrown field when it should have been. Also make the result of enif_schedule_nif return false when passed to enif_is_exception, and add an assertion for this to the nif_SUITE.c tests.
2015-05-26os_mon: Implement cpu_sup:util/0,1 for FreeBSDWasif Malik and Johannes Huning
Authors: Wasif Malik and Johannes Huning
2015-05-26Merge branch 'egil/cuddle-tests'Björn-Egil Dahlberg
* egil/cuddle-tests: erts: Relax monitor_SUITE:mixer/1 erts: Refactor monitor_SUITE:mixer/1 stdlib: Minor change of unicode_SUITE stdlib: Relax iterations in binary_module_SUITE:random_ref_sr_comp/1 Remove ?line macro in binary_module_SUITE:random_ref_sr_comp/1 stdlib: Relax iterations in binary_module_SUITE:random_ref_comp/1 stdlib: Remove ?line macro in binary_module_SUITE:random_ref_comp/1 stdlib: Relax filesize of io_proto_SUITE:unicode_options_gen/1 stdlib: Relax rand_SUITE timeout debugger: Relax test map_SUITE:t_guard_receive_large/1 tools: Relax lcnt test time stdlib: ets_SUITE cuddling
2015-05-26Merge branch 'jlouis/cocci-noderef-fixes'Henrik Nord
* jlouis/cocci-noderef-fixes: Correct usage of sizeof() for pointer types OTP-12771
2015-05-25erts: Relax monitor_SUITE:mixer/1Björn-Egil Dahlberg