aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2018-08-09Merge branch 'maint'Ingela Anderton Andin
2018-08-09Merge branch 'ingela/maint/ssl/ECC/ERIERL-210/OTP-15203' into maintIngela Anderton Andin
* ingela/maint/ssl/ECC/ERIERL-210/OTP-15203: ssl: Make sure that a correct cipher suite is selected
2018-08-09ssl: Make sure that a correct cipher suite is selectedIngela Anderton Andin
The keyexchange ECDHE-RSA requires an RSA-keyed server cert (corresponding for ECDHE-ECDSA), the code did not assert this resulting in that a incorrect cipher suite could be selected. Alas test code was also wrong hiding the error.
2018-08-09Relax add_table_copy restrictionDan Gudmundsson
Allow to add replicas even if all other replicas are down when the other replicase are not stored on disk.
2018-08-09Omit include path debug info for +deterministic buildsJohn Högberg
Compiling the same file with different include paths resulted in different files with the `+deterministic` flag even if everything but the paths were identical. This was caused by the absolute path of each include directory being unconditionally included in a debug information chunk. This commit fixes this by only including this information in non-deterministic builds.
2018-08-09Fix caching of NIF environment when executing dirtyRickard Green
2018-08-09Merge branch 'maint'Björn Gustavsson
* maint: Fix violation of documentation rules
2018-08-09Fix violation of documentation rulesBjörn Gustavsson
In the documentation, we don't use contractations such as "don't" or "that's". We also avoid abbreviations. "i.e." should be written out as "that is". In this case it is better to omit it altogether. 629ad2e0971ef introduced the violation.
2018-08-09Fixed #Ref ordering bugSimon Cornish
2018-08-09Test #Ref ordering in lists and etsSimon Cornish
2018-08-09Merge branch 'maint'Rickard Green
* maint: Fixed #Ref ordering bug Test #Ref ordering in lists and ets
2018-08-09Merge pull request #1902 from dotsimon/ref_ordering_bugRickard Green
Ref ordering fix (ERL-690) OTP-15225
2018-08-09Merge branch 'maint'Björn Gustavsson
* maint: Fix side-effect optimization when compiling from Core Erlang Conflicts: lib/compiler/src/sys_core_fold.erl
2018-08-09Merge pull request #1910 from ↵Björn Gustavsson
bjorng/bjorn/compiler/letrec-side-effect-fix/ERL-658/OTP-15188 Fix side-effect optimization when compiling from Core Erlang
2018-08-09ssl: Error handling improvmentIngela Anderton Andin
2018-08-09Merge branch 'maint'Ingela Anderton Andin
2018-08-09Merge branch 'ingela/ssl/error-state/ERL-685/OTP-15216' into maintIngela Anderton Andin
* ingela/ssl/error-state/ERL-685/OTP-15216: ssl: Correct close handling
2018-08-08Merge pull request #1913 from elbrujohalcon/patch-2Rickard Green
Add clarification on nil type OTP-15222
2018-08-08Add clarification on nil typeBrujo Benavides
As explained by @psyeugenic on Slack: > empty list `[]` is regarded as a separate type from `list()`, `[]` < `list()` > i.e. nil is `[]`
2018-08-08Merge pull request #1909 from fenollp/doc_cmp_atomsRickard Green
Document how atoms are ordered OTP-15220
2018-08-08Fix bug in binary matchingBjörn Gustavsson
The compiler generates incorrect code for the following example: decode_binary(_, <<Length, Data/binary>>) -> case {Length, Data} of {0, _} -> %% When converting the match context back to a binary, %% Data will be set to the entire original binary, %% that is, to <<0>> instead of <<>>. {{0, 0, 0}, Data}; {4, <<Y:16/little, M, D, Rest/binary>>} -> {{Y, M, D}, Rest} end. The problem is the delayed sub binary creation optimization, which is not safe to do in this case. This commit introduces a heuristic that will disable the delayed sub binary creation optimization for this example. Unfortunately, the heuristic may turn off the optimization when it would actually be safe. In the OTP codebase, the optimization is turned off in two instances, once in string.erl and once in dets_v9.erl. https://bugs.erlang.org/browse/ERL-689
2018-08-08Merge pull request #1904 from michalmuskala/mm/get-stacktrace-to-buildBjörn Gustavsson
Rewrite erlang:get_stacktrace calls to primop when safe
2018-08-08Merge branch 'maint'Björn Gustavsson
* maint: Eliminate double computation of next var beam_validator: Fix false diagnostic for a receive nested in a try
2018-08-08Merge pull request #1903 from michalmuskala/mm/useless-callBjörn Gustavsson
Eliminate double computation of next var
2018-08-08Merge pull request #1907 from bjorng/bjorn/compiler/fragile/ERL-684Björn Gustavsson
beam_validator: Fix false diagnostic for a receive nested in a try OTP-15218
2018-08-08Fix side-effect optimization when compiling from Core ErlangJohn Högberg
When an expression is only used for its side effects, we try to remove everything that doesn't tie into a side-effect, but we went a bit too far when we applied the optimization to funs defined in such a context. Consider the following: do letrec 'f'/0 = fun () -> ... whatever ... in call 'side':'effect'(apply 'f'/0()) 'ok' When f/0 is optimized under the assumption that its return value is unused, side:effect/1 will be fed the result of the last side-effecting expression in f/0 instead of its actual result. https://bugs.erlang.org/browse/ERL-658 Co-authored-by: Björn Gustavsson <[email protected]>
2018-08-08Do NOT disc_load from ram_copies when master_node is setDan Gudmundsson
Setting master_nodes to a node with ram_copies replica and that node had not loaded the table, could cause it load an empty table, even though (non master) nodes had disc_replicas. This meant that tables where unexpected empty after multiple failures happened. When this happen do not load the table and wait for user to force_load it on some node, preferably with a disk copy.
2018-08-08Eliminate one more unmatched_return warningKostis Sagonas
2018-08-07Fixed #Ref ordering bugSimon Cornish
2018-08-07Test #Ref ordering in lists and etsSimon Cornish
2018-08-07Optimize binary matchJosé Valim
The idea is to use memchr on the first lookup for binary:match/2 and also after every match on binary:matches/2. We only use memchr in case of matches because benchmarks showed that using memchr even when we had false positives could negatively affect performance. This speeds up binary matching and binary splitting by 4x in some cases and by 70x in other scenarios (when the last character in the needle does not occur in the subject). The reason to use memchr is that it is highly specialized in most modern operating systems, often defaulting to SIMD operations. The implementation uses the reduction count to figure out how many bytes should be read with memchr. We could increase those numbers but they do not seem to make a large difference.
2018-08-07ssl: Make sure that a correct cipher suite is selectedIngela Anderton Andin
The keyexchange ECDHE-RSA requires an RSA-keyed server cert (corresponding for ECDHE-ECDSA), the code did not assert this resulting in that a incorrect cipher suite could be selected. Alas test code was also wrong hiding the error.
2018-08-07ssl: Correct close handlingIngela Anderton Andin
Transport accepted sockets that are in the error state, was not closed properly.
2018-08-07Document how atoms are orderedPierre Fenoll
2018-08-07Eliminate double computation of next varMichał Muskała
My compiler benchmarks on modules with huge functions, show the next_free_variable_name call to be expensive. It turns out one of the 3 calls to the function was completely ignored.
2018-08-07Merge branch 'maint'Ingela Anderton Andin
2018-08-07Merge branch 'ingela/ssl/typos' into maintIngela Anderton Andin
* ingela/ssl/typos: ssl: Fix typos
2018-08-07Merge branch 'maint'Siri Hansen
2018-08-07Merge pull request #1906 from elbrujohalcon/patch-3Siri Hansen
Update documentation for ct:timetrap/1
2018-08-07Merge pull request #1872 from sunboshan/patch-1Siri Hansen
Fix kernel_app doc logger_level defaults
2018-08-07ssl: Fix typosIngela Anderton Andin
2018-08-06beam_validator: Fix false diagnostic for a receive nested in a tryBjörn Gustavsson
When nesting a receive in a try/catch, there could be a false diagnostic that a fragile term is used. https://bugs.erlang.org/browse/ERL-684
2018-08-06ssl: Make sure that a correct cipher suite is selectedIngela Anderton Andin
The keyexchange ECDHE-RSA requires an RSA-keyed server cert (corresponding for ECDHE-ECDSA), the code did not assert this resulting in that a incorrect cipher suite could be selected. Alas test code was also wrong hiding the error.
2018-08-06Update documentation for ct:timetrap/1Brujo Benavides
Even when `ct:sleep/1` accepts `Millisecs` as floats, `ct:timetrap/1` does not. If you try to use it in a test, you get the following error: ```erlang {invalid_time_format,0.1} ```
2018-08-06Merge branch 'maint'Siri Hansen
2018-08-06Merge pull request #1807 from milmazz/improve-cover-html-pagesSiri Hansen
Improve Cover HTML page OTP-15213
2018-08-05Rewrite erlang:get_stacktrace calls to primop when safeMichał Muskała
This allows taking advantage of further optimisations, like the raw_raise instruction for code that can't upgrade (yet) to the new stacktrace syntax for compatibility reasons. The rewrite is only done when it is safe - when the get_stacktrace call is the very first thing the handler does.
2018-08-03Merge branch 'maint'Raimo Niskanen
* maint: Updated OTP version Prepare release Fix NIF stack recursion bug and enforce a limit
2018-08-03Merge branch 'maint-20' into maintRaimo Niskanen
* maint-20: Updated OTP version Prepare release Fix NIF stack recursion bug and enforce a limit Conflicts: OTP_VERSION lib/asn1/doc/src/notes.xml lib/asn1/vsn.mk otp_versions.table
2018-08-03josevalim/jv-preserve-map-same-value/PR-1889/OTP-15211Lukas Larsson
Do not allocate a new map when the value is the same