Age | Commit message (Collapse) | Author |
|
|
|
|
|
In the current iteration of Maps we should deny *any* variables in
Map keys.
|
|
|
|
|
|
- Update map_SUITE with hash and encode tests
- Update map_SUITE with external format decode tests
- Update map_SUITE with map:to_list/1 and map:from_list/1 tests
|
|
|
|
|
|
|
|
* vinoski/ds:
initial support for dirty schedulers and dirty NIFs
|
|
Add initial support for dirty schedulers.
There are two types of dirty schedulers: CPU schedulers and I/O
schedulers. By default, there are as many dirty CPU schedulers as there are
normal schedulers and as many dirty CPU schedulers online as normal
schedulers online. There are 10 dirty I/O schedulers (similar to the choice
of 10 as the default for async threads).
By default, dirty schedulers are disabled and conditionally compiled
out. To enable them, you must pass --enable-dirty-schedulers to the
top-level configure script when building Erlang/OTP.
Current dirty scheduler support requires the emulator to be built with SMP
support. This restriction will be lifted in the future.
You can specify the number of dirty schedulers with the command-line
options +SDcpu (for dirty CPU schedulers) and +SDio (for dirty I/O
schedulers). The +SDcpu option is similar to the +S option in that it takes
two numbers separated by a colon: C1:C2, where C1 specifies the number of
dirty schedulers available and C2 specifies the number of dirty schedulers
online. The +SDPcpu option allows numbers of dirty CPU schedulers available
and dirty CPU schedulers online to be specified as percentages, similar to
the existing +SP option for normal schedulers. The number of dirty CPU
schedulers created and dirty CPU schedulers online may not exceed the
number of normal schedulers created and normal schedulers online,
respectively. The +SDio option takes only a single number specifying the
number of dirty I/O schedulers available and online. There is no support
yet for programmatically changing at run time the number of dirty CPU
schedulers online via erlang:system_flag/2. Also, changing the number of
normal schedulers online via erlang:system_flag(schedulers_online,
NewSchedulersOnline) should ensure that there are no more dirty CPU
schedulers than normal schedulers, but this is not yet implemented. You can
retrieve the number of dirty schedulers by passing dirty_cpu_schedulers,
dirty_cpu_schedulers_online, or dirty_io_schedulers to
erlang:system_info/1.
Currently only NIFs are able to access dirty scheduler
functionality. Neither drivers nor BIFs currently support dirty
schedulers. This restriction will be addressed in the future.
If dirty scheduler support is present in the runtime, the initial status
line Erlang prints before presenting its interactive prompt will include
the indicator "[ds:C1:C2:I]" where "ds" indicates "dirty schedulers", "C1"
indicates the number of dirty CPU schedulers available, "C2" indicates the
number of dirty CPU schedulers online, and "I" indicates the number of
dirty I/O schedulers.
Document The dirty NIF API in the erl_nif man page. The API closely follows
Rickard Green's presentation slides from his talk "Future Extensions to the
Native Interface", presented at the 2011 Erlang Factory held in the San
Francisco Bay Area. Rickard's slides are available online at
http://bit.ly/1m34UHB .
Document the new erl command-line options, the additions to
erlang:system_info/1, and also add the erlang:system_flag/2 dirty scheduler
documentation even though it's not yet implemented.
To determine whether the dirty NIF API is available, native code can check
to see whether the C preprocessor macro ERL_NIF_DIRTY_SCHEDULER_SUPPORT is
defined. To check if dirty schedulers are available at run time, native
code can call the boolean enif_have_dirty_schedulers() function, and Erlang
code can call erlang:system_info(dirty_cpu_schedulers), which raises
badarg if no dirty scheduler support is available.
Add a simple dirty NIF test to the emulator NIF suite.
|
|
OTP-11628
* vinoski/rm-drv-async-cancel:
remove deprecated driver_async_cancel function
|
|
|
|
* sverk/term2bin-simplify:
erts: Refactor ESTACK & WSTACK to use a struct easy to "export"
erts: Fix benign ESTACK/WSTACK typo
erts: Fix compiler warnings for NO_JUMP_TABLE
erts: Run binary_SUITE:trapping even for 32bit
erts: Extend binary_SUITE:ttb_trap to also cover binary_to_term
erts: Remove the extra_root feature from the process structure
erts: Simplify term_to_binary by removing saved ESTACK from root set
|
|
|
|
OTP-11585
* sverk/bin2term-int-size-estimation-bug:
erts: Fix useless comparisons in binary_SUITE:external_size
erts: Reduce heap usage for binary_SUITE:deep
erts: Remove overestimation of heap space in binary_to_term
|
|
* bjorn/fix-line-number-in-bs-exception/OTP-11572:
compiler: Correct line number in exception from binary construction
|
|
Reported-by: Stanislav Seletskiy
|
|
Some time ago the driver_async_cancel function was deprecated and slated
for removal in R17. This commit removes the function along with its
associated tests and documentation, sets the
ERL_DRV_EXTENDED_MAJOR_VERSION to 3 and ERL_DRV_EXTENDED_MINOR_VERSION to
0, and modifies the sys_info_base_drv and sys_info_prev_drv tests in the
driver test suite to check version 3.0 instead of 2.0.
|
|
Not sure why it was disabled for 32bit in the first place?
|
|
and rename it 'trapping'.
|
|
|
|
|
|
|
|
Yielding binary_to_term.
OTP-11535
* tag 'OTP_R16B03_yielding_binary_to_term':
Increase versions for OTP_R16B03_yielding_binary_to_term
erts: Adjust term_to_binary reduction factors
erts: Yield after trapping term_to_binary if gc has been ordered
erts: Let term_to_binary disable gc while trapping
erts: Improve stress of binary_to_term in binary_SUITE
erts: Fix bug in binary_to_term for compressed on halfword
erts: Fix crash when binary_to_term throws badarg
erts: Trapping memcpy in binary_to_term
erts: Cleanup code for trapping binary_to_term
erts: Add erlang wrappers to binary_to_term
trapping uncompress
trapping size calculation
trapping binary_to_term/2
trapping STRING_EXT
trapping lists and tuples
trapping binary_to_term passing binary_SUITE
Conflicts:
erts/preloaded/ebin/erlang.beam
erts/preloaded/ebin/erts_internal.beam
erts/vsn.mk
lib/kernel/vsn.mk
lib/stdlib/vsn.mk
|
|
|
|
* sverk/trapping-bin2term:
erts: Adjust term_to_binary reduction factors
erts: Yield after trapping term_to_binary if gc has been ordered
erts: Let term_to_binary disable gc while trapping
erts: Improve stress of binary_to_term in binary_SUITE
erts: Fix bug in binary_to_term for compressed on halfword
erts: Fix crash when binary_to_term throws badarg
erts: Trapping memcpy in binary_to_term
erts: Cleanup code for trapping binary_to_term
erts: Add erlang wrappers to binary_to_term
trapping uncompress
trapping size calculation
trapping binary_to_term/2
trapping STRING_EXT
trapping lists and tuples
trapping binary_to_term passing binary_SUITE
Parallel check_process_code when code_server purge a module
Functionality for disabling garbage collection
Use asynchronous check_process_code in code_parallel_SUITE
Execution of system tasks in context of another process
Conflicts:
erts/emulator/beam/external.c
erts/emulator/beam/sys.h
erts/emulator/test/binary_SUITE.erl
erts/preloaded/ebin/erlang.beam
erts/preloaded/ebin/erts_internal.beam
|
|
* rickard/garbage_collect/OTP-11388:
Parallel check_process_code when code_server purge a module
Functionality for disabling garbage collection
Use asynchronous check_process_code in code_parallel_SUITE
Execution of system tasks in context of another process
Conflicts:
bootstrap/lib/kernel/ebin/hipe_unified_loader.beam
erts/preloaded/ebin/erlang.beam
erts/preloaded/ebin/erts_internal.beam
|
|
|
|
|
|
* maint:
Improve error info when main carrier creation fails
|
|
* lukas/erts/supercarrier_fix/OTP-11149:
Improve error info when main carrier creation fails
Conflicts:
erts/emulator/test/alloc_SUITE.erl
|
|
|
|
* sverk/bin2term-bitstr-bugs/OTP-11479:
erts: Fix bug in binary_to_term for binaries larger than 2^31
erts: Fix bugs in binary_to_term for invalid bitstrings
|
|
Also fix testcase that failed due to main carrier creation failure.
|
|
* maint:
Fix observer retrieval of alloc info
Fix documentation of the +MMsco switch
Replace the +MMscmgc switch with +MMscrfsd
Add switch for disabling sys_alloc carriers
Add support for locking mappings to physical memory
|
|
* rickard/supercarrier-fix/OTP-11149:
Fix observer retrieval of alloc info
Fix documentation of the +MMsco switch
Replace the +MMscmgc switch with +MMscrfsd
Add switch for disabling sys_alloc carriers
Add support for locking mappings to physical memory
|
|
|
|
* sverk/hash_SUITE-bit_level_binaries:
erts: Fix test case hash_SUITE:bit_level_binaries
|
|
Commontest doesn't like exported functions with same name as test case.
|
|
by doing repeated calls with different reduction count.
|
|
Being able to disable garbage collection over context
switches vastly simplifies implementation of yielding
native code that builds large or complex data structures
on the heap. This since the heap can be left in an
inconsistent state over the context switch.
|
|
|
|
A process requesting a system task to be executed in the context of
another process will be notified by a message when the task has
executed. This message will be on the form:
{RequestType, RequestId, Pid, Result}.
A process requesting a system task to be executed can set priority
on the system task. The requester typically set the same priority
on the task as its own process priority, and by this avoiding
priority inversion. A request for execution of a system task is
made by calling the statically linked in NIF
erts_internal:request_system_task(Pid, Prio, Request). This is an
undocumented ERTS internal function that should remain so. It
should *only* be called from BIF implementations.
Currently defined system tasks are:
* garbage_collect
* check_process_code
Further system tasks can and will be implemented in the future.
The erlang:garbage_collect/[1,2] and erlang:check_process_code/[2,3]
BIFs are now implemented using system tasks. Both the
'garbage_collect' and the 'check_process_code' operations perform
or may perform garbage_collections. By doing these via the
system task functionality all garbage collect operations in the
system will be performed solely in the context of the process
being garbage collected. This makes it possible to later implement
functionality for disabling garbage collection of a process over
context switches.
Newly introduced BIFs:
* erlang:garbage_collect/2 - The new second argument is an option
list. Introduced option:
* {async, RequestId} - making it possible for users to issue
asynchronous garbage collect requests.
* erlang:check_process_code/3 - The new third argument is an
option list. Introduced options:
* {async, RequestId} - making it possible for users to issue
asynchronous check process code requests.
* {allow_gc, boolean()} - making it possible to issue requests
that aren't allowed to garbage collect (operation will abort
if gc should be needed).
These options have been introduced as a preparation for
parallelization of check_process_code operations when the
code_server is about to purge a module.
|
|
|
|
<<131, 77, Len:32, Bits:8, Data/binary>>
badarg if Bits > 8
Used to return internally inconsistent bitstring
badarg if Len==0 and Bits > 0
Used to return invalid *huge* binary (size = (Uint)-1)
badarg if Bits==0 and Len > 0
Used to return valid binary as if Bits was 8
|
|
Conflicts:
bootstrap/lib/kernel/ebin/os.beam
|
|
|
|
New BIF os:unsetenv/1 which deletes an environment variable and
returns 'true'.
Does not change any old functionality.
Calls the libc function unsetenv(3) on UNIX and
SetEnvironmentVariableW(key, NULL) on Windows. The unicode support
is the same as for os:getenv and os:putenv.
|
|
Replaced the +MMscmgc switch with the +MMscrfsd switch. The old switch
didn't reflect what it controlled.
|