Age | Commit message (Collapse) | Author |
|
|
|
If a NIF monitor fired while the resource was present in an ETS
table, the lock checker would erroneously report a lock order
violation.
This has no effect outside of debug builds.
|
|
This introduces a way to retrieve erlang terms from NIF IO queues
without having to resort to copying.
OTP-14797
|
|
|
|
Document enif_realloc and pointer alignment guarantees
|
|
|
|
|
|
|
|
This commit adds a new syntax for retrieving the stacktrace
without calling erlang:get_stacktrace/0. That allow us to
deprecate erlang:get_stacktrace/0 and ultimately remove it.
The problem with erlang:get_stacktrace/0 is that it can keep huge
terms in a process for an indefinite time after an exception. The
stacktrace can be huge after a 'function_clause' exception or a failed
call to a BIF or operator, because the arguments for the call will be
included in the stacktrace. For example:
1> catch abs(lists:seq(1, 1000)).
{'EXIT',{badarg,[{erlang,abs,
[[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20|...]],
[]},
{erl_eval,do_apply,6,[{file,"erl_eval.erl"},{line,674}]},
{erl_eval,expr,5,[{file,"erl_eval.erl"},{line,431}]},
{shell,exprs,7,[{file,"shell.erl"},{line,687}]},
{shell,eval_exprs,7,[{file,"shell.erl"},{line,642}]},
{shell,eval_loop,3,[{file,"shell.erl"},{line,627}]}]}}
2> erlang:get_stacktrace().
[{erlang,abs,
[[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,
23,24|...]],
[]},
{erl_eval,do_apply,6,[{file,"erl_eval.erl"},{line,674}]},
{erl_eval,expr,5,[{file,"erl_eval.erl"},{line,431}]},
{shell,exprs,7,[{file,"shell.erl"},{line,687}]},
{shell,eval_exprs,7,[{file,"shell.erl"},{line,642}]},
{shell,eval_loop,3,[{file,"shell.erl"},{line,627}]}]
3>
We can extend the syntax for clauses in try/catch to optionally bind
the stacktrace to a variable.
Here is an example using the current syntax:
try
Expr
catch C:E ->
Stk = erlang:get_stacktrace(),
.
.
.
In the new syntax, it would look like:
try
Expr
catch
C:E:Stk ->
.
.
.
Only a variable (not a pattern) is allowed in the stacktrace position,
to discourage matching of the stacktrace. (Matching would also be
expensive, because the raw format of the stacktrace would have to be
converted to the cooked form before matching.)
Note that:
try
Expr
catch E ->
.
.
.
is a shorthand for:
try
Expr
catch throw:E ->
.
.
.
If the stacktrace is to be retrieved for a throw, the 'throw:'
prefix must be explicitly included:
try
Expr
catch throw:E:Stk ->
.
.
.
|
|
In the grammar file for the Erlang language, patterns are parsed
as expressions. erl_lint will then weed out expressions that are
not legal patterns.
The rule sharing causes problems if we were to introduce new
syntax, for example a pattern followed by a ':'. There would
be a shift/reduce conflict, and a pattern followed by a ':'
would be parsed as a remote call.
Introduce a new pat_expr rule to express exactly the subset
of expressions that is allowed in pattern.
Note: For the moment, we must allow full expressions in
case clauses to keep 'merl' working.
|
|
X register 0 used to be mapped to a hardware register, and therefore
faster than the other registers. Because of that, the compiler
tried to use x(0) as much as possible as a temporary register.
That was changed a few releases ago. X register 0 is now placed
in the array of all X registers and has no special speed
advantage compared to the other registers.
Remove the code in the compiler that attempts to use x(0) as
much as possible. As a result, the following type of instruction
will be much less frequent:
{put_list,Src,{x,0},{x,0}}
Instead, the following type of instruction will be more frequent:
{put_list,Src,{x,X},{x,X}}
(Where X is an arbitrary X register.)
Update the runtime system to specialize that kind of put_list
instruction.
|
|
* maint:
Fix type create_option() in mnesia
|
|
Fix type create_option() in mnesia
|
|
* maint:
Fix max atom size overflow on 64-bits Erlang by lowering the MAX_ATOM_TABLE_SIZE
Fix integer overflow when set a large maximum value for atom table
|
|
Fix integer overflow when set a large maximum value for atom table
OTP-14796
|
|
|
|
* bjorn/compiler/coverage:
v3_codegen: Remove check of operand for bs_context_to_binary
beam_jump: Eliminate a repeated clause
beam_asm: No longer allow iolists as contents in chunk/2
beam_utils_SUITE: Cover more lines in beam_utils
guard_SUITE: Add a test case to cover beam_dead:turn_op/1
Recognize 'nil' as a literal in beam_utils:bif_to_test/3
Cover more code in beam_bsm:btb_opt_1/3
Add test to cover a line in v3_kernel:opt_single_valued/3
|
|
* maint:
Avoid falling measurements testcases on slow machines
stdlib: string optimize special case for ASCII
stdlib: Minor unicode_util opts
|
|
* dgud/stdlib/optimize-string-lists:
Avoid falling measurements testcases on slow machines
stdlib: string optimize special case for ASCII
stdlib: Minor unicode_util opts
OTP-14670
|
|
Minor grammar tweak in ETS documentation
|
|
|
|
=== OTP-19.2.3.1 ===
Changed Applications:
- erts-8.2.2.1
Unchanged Applications:
- asn1-4.0.4
- common_test-1.13
- compiler-7.0.3
- cosEvent-2.2.1
- cosEventDomain-1.2.1
- cosFileTransfer-1.2.1
- cosNotification-1.2.2
- cosProperty-1.2.1
- cosTime-1.2.2
- cosTransactions-1.3.2
- crypto-3.7.2
- debugger-4.2.1
- dialyzer-3.0.3
- diameter-1.12.1
- edoc-0.8.1
- eldap-1.2.2
- erl_docgen-0.6.1
- erl_interface-3.9.2
- et-1.6
- eunit-2.3.2
- gs-1.6.2
- hipe-3.15.3
- ic-4.4.2
- inets-6.3.5
- jinterface-1.7.1
- kernel-5.1.1
- megaco-3.18.1
- mnesia-4.14.3
- observer-2.3
- odbc-2.12
- orber-3.8.2
- os_mon-2.4.1
- otp_mibs-1.1.1
- parsetools-2.1.4
- percept-0.9
- public_key-1.3
- reltool-0.7.2
- runtime_tools-1.11
- sasl-3.0.2
- snmp-5.2.4
- ssh-4.4
- ssl-8.1
- stdlib-3.2
- syntax_tools-2.1.1
- tools-2.9
- typer-0.9.11
- wx-1.8
- xmerl-1.3.12
|
|
|
|
|
|
* sverker/mbcs-pool-stats/ERL-88/OTP-14795:
Fix erlang:memory
Remove duplicate stats for 'fetch'
Do not include new stats for 'allocator_sizes'
Add more cpool stats
erts: Add statistics for cpoll fetch attempts
|
|
|
|
Avoid unicode_util module call for ASCII strings
|
|
Exit early for Latin-1
|
|
|
|
* ingela/ssl/ERL-521/OTP-14794:
ssl: Make sure all possible data is delivered
|
|
|
|
Conflicts:
lib/ssl/src/ssl_connection.erl
|
|
* ingela/ssl/cleaner-code:
ssl: Add gracefullness to dtls code
ssl: Remove old softupgrade code
ssl: Use genstamtem properly
|
|
The bs_context_to_binary instruction only allows a register operand.
v3_codegen has a test to ensure that the operand is a register.
That test is no longer necessary. There used to be a possibility
that optimizations in sys_core_fold and the inliner could change
the operand for bs_context_to_binary to a binary literal. Since
09112806c15a81b that can no longer happen, because no more
optimizations are run after the introduction of the
bs_context_to_binary instruction.
|
|
|
|
|
|
|
|
Often the decode functions return a function_clause error, but not
always, and the errors have not been consistent between modifications
of the base64 module.
Now the errors are returned as they happen--no attempt to make them
look nice is done. The alternative, to ensure that, for example,
{badarg, Culprit} is always returned upon bad input, was deemed
pointless.
|
|
Using /bits instead of /binary is faster when constructing binaries.
|
|
It is sometimes faster to use binary_to_list on input, at least when
not considering time for garbage collections. The three functions all
return a list, and the temporary list created by binary_to_list should
be reclaimed very fast. The implementation from before is thus kept.
|
|
A few test cases with zeroes are added. They were not handled correctly
before.
The access of DECODE_MAP is moved into the inlined function b64d, for
symmetry.
The function b64e is also inlined. The speed-up is small, but
measurable.
Note: encode(List), decode(List) and mime_decode(List) no longer call
list_to_binary. This can break code that calls the functions with
I/O-lists as input.
|
|
* maint:
dialyzer: Extend the map implementation's handling of ?unit
dialyzer: Use string:find() instead of string:str()
|
|
* hasse/dialyzer/maps_anon_fun/OTP-14743:
dialyzer: Extend the map implementation's handling of ?unit
dialyzer: Use string:find() instead of string:str()
|
|
* maint:
public_key: Fix failing pkix_verify_hostname_subjAltName_IP TC
|
|
* hans/ssh/public_key/fix_bad_cert_merge:
public_key: Fix failing pkix_verify_hostname_subjAltName_IP TC
|
|
Fixed handling of URL paths that contain space (%20) characters.
Change-Id: Ic09691e35c70ee005af7637a6ec3ae588097bec1
|
|
The create_option() type in mnesia lacks the user_properties field
which is used by mnesia in various places.
|
|
|
|
|
|
* maint:
Update HOWTO with wxWidgets build examples
https should be mapped to url and not seealso
Update kernel appup for OTP-20.2
|