aboutsummaryrefslogtreecommitdiffstats
path: root/erts
AgeCommit message (Collapse)Author
2011-11-18Fix warning when lock-checker is enabledRickard Green
2011-11-18Replace spinlock with mutex as pix_lock implementationRickard Green
The spinlocks used implementing pix-locks have been replaced with mutexes since they perform better during heavy contention.
2011-11-13Make sure only one thread exits the runtime systemRickard Green
The runtime system crashed if more than one thread tried to exit the runtime system at the same time.
2011-11-13Use critical sections as mutex implementation on WindowsRickard Green
Windows native critical sections are now used internally in the runtime system as mutex implementation. This since they perform better under extreme contention than our own implementation.
2011-11-13Use generic lock-free queue for async threadsRickard Green
Queues used for communication between async threads and scheduler threads have been replaced with lock-free queues. Drivers using the driver_async functionality are not automatically locked to the system anymore, and can be unloaded as any dynamically linked in driver. Scheduling of ready async jobs is now also interleaved in between other jobs. Previously all ready async jobs was performed at once.
2011-11-13Use generic lock-free queue for misc aux workRickard Green
2011-11-13Implement generic lock-free queueRickard Green
The implementation of an ERTS internal, generic, many to one, lock-free queue for communication between threads. The many to one scenario is very common in ERTS, so it can be used in a lot of places in the future. Changing to this queue from a lock based queue, however, often requires some redesigning. This since we have often used the lock of the queue to protect other information too.
2011-11-13Replace system block with thread progress blockRickard Green
The ERTS internal system block functionality has been replaced by new functionality for blocking the system. The old system block functionality had contention issues and complexity issues. The new functionality piggy-backs on thread progress tracking functionality needed by newly introduced lock-free synchronization in the runtime system. When the functionality for blocking the system isn't used there is more or less no overhead at all. This since the functionality for tracking thread progress is there and needed anyway.
2011-11-13Optimize memory allocationRickard Green
A number of memory allocation optimizations have been implemented. Most optimizations reduce contention caused by synchronization between threads during allocation and deallocation of memory. Most notably: * Synchronization of memory management in scheduler specific allocator instances has been rewritten to use lock-free synchronization. * Synchronization of memory management in scheduler specific pre-allocators has been rewritten to use lock-free synchronization. * The 'mseg_alloc' memory segment allocator now use scheduler specific instances instead of one instance. Apart from reducing contention this also ensures that memory allocators always create memory segments on the local NUMA node on a NUMA system.
2011-10-14Merge branch 'rickard/atomics-api/OTP-9014' and OTP_R14B04Rickard Green
Conflicts: erts/aclocal.m4 erts/emulator/beam/erl_db.c erts/emulator/sys/win32/sys.c erts/include/internal/ethread_header_config.h.in
2011-10-04Prepare releaseOTP_R14B04Erlang/OTP
2011-10-04Merge branch 'maint-r14' into devRaimo Niskanen
2011-10-04Merge branch 'maint-r13' into maint-r14Raimo Niskanen
Conflicts: erts/doc/src/notes.xml erts/emulator/drivers/common/inet_drv.c erts/vsn.mk lib/kernel/test/gen_sctp_SUITE.erl
2011-09-29Update copyright yearsBjörn-Egil Dahlberg
2011-09-29Merge branch 'sverker/stub-module-code-leakage' into devLukas Larsson
* sverker/stub-module-code-leakage: Prevent valgrind warning for erts_alloc_permanent_cache_aligned [erts] Fix memory leak in erts_make_stub_module (hipe loading)
2011-09-29Merge branch 'lukas/fix_erts_testcases/OTP-9596' into devLukas Larsson
* lukas/fix_erts_testcases/OTP-9596: Skip create_big_boot on platforms without crypto Remove test_server path instead of cwd for clash test Skip getaddr_v6 test if on the ipv4_only host Use static port for old solaris versions Extend time to wait for zone files to be loaded Allow out of memory exception for max_port checks Extend slave start timeout for windows tests Double timeout to make sure debug builds pass Use now instead of os:timestamp Increase timeout in scheduler_suspend for slow platforms Skip update_cpu_info if 'taskset' cannot be found
2011-09-29Allow out of memory exception for max_port checksLukas Larsson
2011-09-29Double timeout to make sure debug builds passLukas Larsson
2011-09-29Use now instead of os:timestampLukas Larsson
This is done in order to improve timing when testing debug builds, especially ppc debug builds.
2011-09-28Prevent valgrind warning for erts_alloc_permanent_cache_alignedSverker Eriksson
2011-09-28[erts] Fix memory leak in erts_make_stub_module (hipe loading)Sverker Eriksson
Code area allocation was done twice; first in read_code_header() and then in erts_make_stub_module() itself.
2011-09-28Merge branch 'raimo/sctp-getsetopts-dev/OTP-9544' into devRaimo Niskanen
* raimo/sctp-getsetopts-dev/OTP-9544: erts,kernel: Bugfix - read SCTP socket options from right protocol layer erts: Fix bug SCTP send can only be called from controlling process
2011-09-28Merge branch 'bjorn/fix-test-cases' into devBjörn Gustavsson
* bjorn/fix-test-cases: distribution_SUITE:bulk_send_bigbig/1: Fail with more information distribution_SUITE: Use unique slave node names busy_port_SUITE: Avoid crash in register/2
2011-09-27distribution_SUITE:bulk_send_bigbig/1: Fail with more informationBjörn Gustavsson
2011-09-27distribution_SUITE: Use unique slave node namesBjörn Gustavsson
bad_dist_ext_connection_id/1 used the same names for the slave nodes as bad_dist_ext_receive/1, which would cause it to fail if bad_dist_ext_receive/1 failed.
2011-09-27Merge branch 'hb/doc_corrections/OTP-9550' into devHans Bolinder
* hb/doc_corrections/OTP-9550: Correct XML files
2011-09-26busy_port_SUITE: Avoid crash in register/2Björn Gustavsson
Add an end_per_testcase/2 function to ensure that the process with the name 'busy_drv_server' has been killed before the next test case attempts to register a process with the same name.
2011-09-26Update preloaded modulesBjörn Gustavsson
2011-09-26erl_prim_loader: Eliminate dialyzer warningBjörn Gustavsson
The concat/1 function is now only used to append lists when constructing filenames. Thus it is too general and the first clause (that handles characters) will never be used. We could just remove the clause that is never used, but then the name 'concat' would be misleading and someone could use misuse it. Therefore, replace concat/1 with the join/2 function that can only be used for joining filename components.
2011-09-26Correct XML filesHans Bolinder
2011-09-24Merge branch 'rickard/aux-work-bug/OTP-9567' into devRickard Green
* rickard/aux-work-bug/OTP-9567: Fix lost wakeup of scheduler when enqueuing auxiliary work
2011-09-23Remove static ssl linking in crypto for otp_buildBjörn-Egil Dahlberg
2011-09-22Fix lost wakeup of scheduler when enqueuing auxiliary workRickard Green
When auxiliary work was enqueued on a scheduler, the wakeup of the scheduler in order to handle this work could be lost. Wakeups in order to handle ordinary work were not effected by this bug. The bug only effected runtime systems with SMP support as follows: * Deallocation of some ETS data structures could be delayed. * On Linux systems not using the NPTL thread library (typically ancient systems with kernel versions prior to 2.6) and Windows systems, the {Port, {exit_status, Status}} message from a terminating port program could be delayed. That is, it only effected port programs which had been started by passing exit_status as an option to open_port/2.
2011-09-21Remove static ssl linking in crypto for otp_buildBjörn-Egil Dahlberg
2011-09-21Merge branch 'bjorn/erts/support-macosx-lion/OTP-9547' into devBjörn Gustavsson
* bjorn/erts/support-macosx-lion/OTP-9547: Fix build problems on MacOS 10.7 (Lion)
2011-09-21Increase timeout in scheduler_suspend for slow platformsLukas Larsson
2011-09-21Skip update_cpu_info if 'taskset' cannot be foundLukas Larsson
2011-09-20Fix build problems on MacOS 10.7 (Lion)Björn Gustavsson
On MacOS 10.7 (Lion) with Xcode 4.1 installed, the default C compiler is llvm-gcc-4.2. That compiler compiles beam_emu.c incorrectly, resulting in an emulator that will not start. The problem can be worked around by turning off all optimizations, but that will significantly degrade the performance of the run-time system. The problem can also be worked around manually like this: CC=gcc-4.2 ./configure To allow a working system to be built "out of the box", have the configure script set up the emulator Makefile so that gcc-4.2 will be used to compile beam_emu.c if the default compiler is llvm-based. All other C files will still be compiled with the default compiler.
2011-09-20Merge branch 'cr/cppcheck' into devHenrik Nord
* cr/cppcheck: Changes inspired by running cppcheck(1) OTP-9557
2011-09-20Merge branch 'ta/docs-fixes' into devHenrik Nord
* ta/docs-fixes: Fix misspelling of intermediate Fix typos in erts/preloaded/src Fix more misspellings of compatibility Fix misspelling of kept Fix misspelling of compatibility in ssl_basic_SUITE Fix misspelling of compatibility Fix misspelling of accommodate Fix misspelling of exceed Fix misspelling of accidentally Fix misspelling of erroneous in xmerl_xsd Fix misspelling of erroneous Fix misspelling of successful Fix typos in instrument(3) Fix typos in dbg(3) dialyzer: fix a small typo in list_to_bitstring test Fix typos in cover.erl Fix typos (variable name) in erl_nif(3) Fix typos in mod_esi(3) Fix trivial typos in erlang(3) OTP-9555
2011-09-19Merge branch 'raimo/sctp-getsetopts/OTP-9544' into ↵Raimo Niskanen
raimo/sctp-getsetopts-dev/OTP-9544 Conflicts: erts/emulator/drivers/common/inet_drv.c lib/kernel/test/gen_sctp_SUITE.erl
2011-09-19Prepare releaseErlang/OTP
2011-09-19erts,kernel: Bugfix - read SCTP socket options from right protocol layerRaimo Niskanen
Socket options 'sndbuf', 'recbuf' and 'linger were read from the SCTP protocol layer instead of from the socket protocol layer. Conflicts: lib/kernel/test/gen_sctp_SUITE.erl
2011-09-19Merge branch 'rickard/glibc-mutex-destroy-bug/OTP-9373' into devRickard Green
* rickard/glibc-mutex-destroy-bug/OTP-9373: Do not abort emulator when buggy pthread impl return EBUSY
2011-09-19erts: Fix bug SCTP send can only be called from controlling processRaimo Niskanen
Conflicts: lib/kernel/test/gen_sctp_SUITE.erl
2011-09-16Fix misspelling of intermediateTuncer Ayaz
2011-09-16Fix typos in erts/preloaded/srcTuncer Ayaz
2011-09-16erts: Remove compiler warning in sys.cBjörn-Egil Dahlberg
2011-09-16Merge branch 'pan/erl-bif-types/OTP-9496' into devBjörn-Egil Dahlberg
* pan/erl-bif-types/OTP-9496: Cleanup ETS bif's in hipe:erl_bif_types.erl (for dialyzer)
2011-09-16Merge branch 'pan/win_erlsrv_stop/OTP-9344' into devBjörn-Egil Dahlberg
* pan/win_erlsrv_stop/OTP-9344: Move init of smp rw mutex from init to sys_args to make sure that it is initialized before the first erts_sys_getenv call Move erts_sys_env_init() to erts_sys_pre_init() Remove _DEBUG from start_erl.c Spelling correction in erlsrv doc Convert windows start_erl to take rootdir on command line Add command start_disabled to erlsrv Add global lock for erlsrv to avoid races Change start order so that service_event gets initialized before it's used