aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator
AgeCommit message (Collapse)Author
2014-03-21Introduce minimum allowed major driver and nif versions on loadRickard Green
2014-03-20Merge branch 'vinoski/ds-enif-send'Rickard Green
* vinoski/ds-enif-send: enable enif_send to work from a dirty scheduler
2014-03-20Merge branch 'bjorn/erts/fix-lingering-tracer'Björn Gustavsson
* bjorn/erts/fix-lingering-tracer: Teach the call_time trace to notice when the trace dies (non-SMP system)
2014-03-20Teach the call_time trace to notice when the trace dies (non-SMP system)Björn Gustavsson
The call_time trace is a special kind of tracing that requires a tracer process just like ordinary call trace, but it never actually sends anything to the tracer. It merely use the existence of a trace process (and call trace flags) as an indication that call_time tracing is active for the process. If the tracer dies in a non-SMP run-time system, processes with call_time tracing would not notice that the tracer had died. Furthermore, if the set_on_spawn flag was active, the dead tracer could be propagaged to newly spawned processes. Before accumulating trace information in a non-SMP system, always validate the tracer process. (In an SMP system, a reference to a dead tracer will be cleared away each time a process is scheduled.) While we could put all of the new code beam_bp.c, we have chosen to make a function call from beam_bp.c to a function in erl_trace.c for clarity's sake and to ease further maintenance. In the future, we might want to handle tracing in more similar ways in the SMP and non-SMP system.
2014-03-19Merge branch 'cobusc/correct_comment'Henrik Nord
* cobusc/correct_comment: Fix comment that differs from code OTP-11793
2014-03-18Merge branch 'egil/maps-literals'Björn-Egil Dahlberg
* egil/maps-literals: compiler: Transform M#{} to is_map(M) dialyzer: Do not native compile modules with Maps code hipe: Properly identify map() type form terms stdlib: Test Map key linting stdlib: Accept records as Map keys stdlib: Accept Maps as Map keys stdlib: Move map type to proper definition stdlib: Properly lint map key expressions compiler: Change #c_map{var} to #c_map{arg} compiler: Constant fold Maps that are safe compiler: Validate Map src compiler: Support literal maps in cerl_clauses:match/2 compiler: Guard BIF is_map/1 is pure erts: Handle literals in is_map/1 compiler: Change Maps Core Format compiler: Create literal Maps in creation if possible
2014-03-18Merge branch 'lukas/erts/make_deps_fixes/OTP-11784'Lukas Larsson
* lukas/erts/make_deps_fixes/OTP-11784: erts: Fix resolve of generated files for depend erts: Move compiler flags generation
2014-03-17erts: Handle literals in is_map/1Björn-Egil Dahlberg
2014-03-14Merge branch 'sverk/maps-erl_interface'Sverker Eriksson
* sverk/maps-erl_interface: erts: Add distribution capability flag for maps DFLAG_MAP_TAG erts: Change external format for maps erts: Document external format for maps (MAP_EXT) erl_interface: Add test for ei_skip_term of container terms erl_interface: Add map support in ei_skip_term erl_interface: Fix mem leak in ei_decode_encode_test erl_interface: test decode/encode of maps erl_interface: Add ei encode/decode for maps erl_interface: test decode_encode of tuples and lists erl_interface: refactor ei_decode_encode_test.c
2014-03-14erts: Add distribution capability flag for maps DFLAG_MAP_TAGSverker Eriksson
This is just a preparation to allow detection of older nodes that do not understand maps (R16 and older).
2014-03-14erts: Change external format for mapsSverker Eriksson
to be: 116,Arity, K1,V1,K2,V2,...,Kn,Vn instead of: 116,Arity, K1,K2,...,Kn, V1,V2,....,Vn We think this will be better for future internal map structures like HAMT. Would be bad if we need to iterate twice over HAMT in term_to_binary, one for keys and one for values.
2014-03-13Merge branch 'sverk/valgrind-leaks'Sverker Eriksson
* sverk/valgrind-leaks: erts: Suppress false leak in hipe_thread_signal_init erts: Fix leak in nif_SUITE:resource_takeover (again)
2014-03-10enable enif_send to work from a dirty schedulerSteve Vinoski
2014-03-05Fix comment that differs from codeCobus Carstens
The comment in the code state that the tree is traversed to the left, when in fact it is traversed to the right.
2014-03-04Merge branch 'bjorn/hipe/fix-race-condition'Björn Gustavsson
* bjorn/hipe/fix-race-condition: Delay patching of closures to eliminate a race condition hipe: Break apart hipe_bif:make_fe/3 into two BIFs
2014-02-28erts: Suppress false leak in hipe_thread_signal_initSverker Eriksson
2014-02-28erts: Fix leak in nif_SUITE:resource_takeover (again)Sverker Eriksson
2014-02-28hipe: Break apart hipe_bif:make_fe/3 into two BIFsBjörn Gustavsson
This commit is a preparation for eliminating a race condition loading the native code for modules whose BEAM code has already been loaded. Here we introduce two new BIFs so that looking up a fun entry is separate from setting the native address in the fun entry.
2014-02-27erts: Fix Map cmp exact equal of an empty mapBjörn-Egil Dahlberg
The expression, #{} =:= M where M was any Map, would always result in 'true'. This commit fixes this issue by first comparing sizes for both terms and then checking for size zero.
2014-02-25Merge branch 'sverk/hipe-disable-gc-bug'Sverker Eriksson
* sverk/hipe-disable-gc-bug: erts: Fix heap overwrite by hipe "trap frames" when GC is disabled ASSERT that GC is not tried with "need" when GC is disabled
2014-02-25erts: Fix heap overwrite by hipe "trap frames" when GC is disabledSverker Eriksson
by trapping BIFs like term_to_binary and binary_to_term.
2014-02-24Merge branch 'lukas/erts/float_encoding/OTP-11738'Lukas Larsson
* lukas/erts/float_encoding/OTP-11738: erts: Set default external enc to use new float scheme
2014-02-24Merge branch 'lukas/ose/master/OTP-11334'Lukas Larsson
* lukas/ose/master/OTP-11334: (71 commits) erts: Fix unix efile assert ose: Use -O2 when building ose: Expand OSE docs ose: Add dummy ttsl driver ose: Cleanup cleanup of mutex selection defines ose: Polish mmap configure checks ose: Add ose specific x-compile flags ose: Updating fd_driver and spawn_driver for OSE ose: Updating event and signal API for OSE ose: Cleanup of mutex selection defines win32: Compile erl_log.exe ose: Remove uneccesary define ose: Fix ssl configure test for osx erts: Fix sys_msg_dispatcher assert ose: Fix broken doc links ose: Thread priorities configurable from lmconf ose: Yielding the cpu is done "the OSE" way ose: Start using ppdata for tse key ose: Do not use spinlocks on OSE ose: Fix support for crypto ... Conflicts: lib/crypto/c_src/crypto.c
2014-02-24erts: Fix unix efile assertLukas Larsson
If writev return an error (eg ENOSPC) we do not want to abort here but instead propagate upwards into erlang.
2014-02-24ose: Add dummy ttsl driverLukas Larsson
2014-02-24ose: Updating fd_driver and spawn_driver for OSEJonas Karlsson
2014-02-24ose: Updating event and signal API for OSEJonas Karlsson
2014-02-24erts: Fix sys_msg_dispatcher assertLukas Larsson
Schedulers is too restrictive. Managed threads should be able to clean this up.
2014-02-24ose: Thread priorities configurable from lmconfLukas Larsson
The pattern used for getting the priority from the lmconf is based on the name of the process created. The pattern is: ERTS_%%PROCESS_NAME%%_PRIO with the %%PROCESS_NAME%% replaced by the prefix of the process the priority applies to. eg: ERTS_SCHEDULER_PRIO=24 applies to processes with name SCHEDULER_1, SCHEDULER_2 etc.
2014-02-24ose: Cleanup POLL_SCHED_1 codeLukas Larsson
Now schedulers 2..N make sure to wake sched 1 if they find that all io has been consumed and sched 1 is sleeping. Before sched 1 was spinning in sys_schedule waiting for sched 2..N to finish consuming io jobs
2014-02-24ose: Added Enea copyright header to lcf files.Robert Paal
Also removed softkernel lcf files.
2014-02-24ose: Eliminating delays when trying to open filesRobert Paal
When opening filers on not mounted volumes the default timeout on OSE is quite big and since at startup we load something like 20 beam files this slows down startup by as much as 50 seconds.
2014-02-24ose: Update ddll interface after rebase to 17.0-rc1Lukas Larsson
Also deleted all the copy-paste stuff
2014-02-24ose: Add fair scheduling yieldsLukas Larsson
This is needed on OSs that do not do round robin scheduling of threads.
2014-02-24ose: Port run_erl and to_erlLukas Larsson
2014-02-24ose: Rewrite resolve_signal API for ose driversLukas Larsson
This new API has less impact on the check_io code and also removes the callback from ErlDrvEntry. The downside is that you have to give the resolve function when creating each event. Also the mode if the resolve was removed as this mimics the win32 code and decreases complexity.
2014-02-24ose: Fix starting with pm_createLukas Larsson
For some reason starting with pm_create offsets the input argument list by one, so we have to adjust them before calling erl_start.
2014-02-24ose: Update erl_assert_error after R16B03 api changeLukas Larsson
2014-02-24ose: OSE port related cleanup and fixesJonas Karlsson
Some OSE cross-chains have problems with system includes being used, so for atleast OSE specific parts we use "" instead of <>.
2014-02-24ose: efile driver updates.Jonas Karlsson
2014-02-24ose: Fix printout to stdout to not duplicate long buffersLukas Larsson
2014-02-24ose: Bugfixes to filesystem related issues.Jonas Karlsson
2014-02-24ose: Use spinlock as default heap lock mechanismJonas Karlsson
2014-02-24ose: Handle lseek() with offset beyond EOF in the file driver.Lukas Larsson
2014-02-24ose: Fix clearmake compat issueLukas Larsson
2014-02-24ose,erts: Specify name for tsd keysLukas Larsson
This simplified debugging on OSE and also limits the number of ppdata keys that are created when beam is restarted.
2014-02-24ose: Style updates onlyLukas Larsson
2014-02-24ose: Fix various build environment issuesLukas Larsson
2014-02-24erts: configure number of write_concurrency locksLukas Larsson
Make it possible to change the number of write_concurrency locks to use. This is usefull to change when you for some reason want to use more/less locks per write_concurrency ets table. eg. OSs with a limit on how many mutexes can exist at once.
2014-02-24ose: Change signal base to registered rangeLukas Larsson