Age | Commit message (Collapse) | Author | |
---|---|---|---|
2017-12-01 | Merge branch 'maint' | Ingela Anderton Andin | |
2017-12-01 | Merge branch 'ingela/ssl/timing' into maint | Ingela Anderton Andin | |
* ingela/ssl/timing: ssl: Align timing just in case | |||
2017-12-01 | Merge branch 'peterdmv/inets/fix-httpc/OTP-14799' | Péter Dimitrov | |
* peterdmv/inets/fix-httpc/OTP-14799: inets: Fix httpc path handling | |||
2017-12-01 | Merge branch 'john/erts/efile-nif' | John Högberg | |
OTP-14256 OTP-14797 | |||
2017-11-30 | Merge branch 'maint' | Rickard Green | |
* maint: Clarification in doc of unicode:characters_to_list/2 | |||
2017-11-30 | Merge branch 'rickard/unicode-doc/ERL-516/OTP-14798' into maint | Rickard Green | |
* rickard/unicode-doc/ERL-516/OTP-14798: Clarification in doc of unicode:characters_to_list/2 | |||
2017-11-30 | Clarification in doc of unicode:characters_to_list/2 | Rickard Green | |
2017-11-30 | stdlib: Add base64 benchmarks | Hans Bolinder | |
2017-11-30 | Don't assume efile driver is present | John Högberg | |
2017-11-30 | Make file:sendfile/5 follow its documented error behavior | John Högberg | |
2017-11-30 | Remove doc for sendfile/5 use_threads option | John Högberg | |
The option no longer does anything; systems that lack support for non-blocking sendfile(2) will use the Erlang fallback. | |||
2017-11-30 | Update file performance advice | John Högberg | |
The parts relating to drivers/ports are now obsolete, and the provided example was far noisier than it had to be; the only relevant metric is the number of calls and it's up to the user to decide how those will be reduced. One could argue for its complete removal, but I'm inclined to leave it be. | |||
2017-11-30 | Use tcp_inet as an example driver instead of efile | John Högberg | |
2017-11-30 | Remove all mention of efile_drv from DTrace docs | John Högberg | |
efile_drv is gone and so is the need for file-specific DTrace. The new implementation works fine with the normal tracing mechanism so there's nothing preventing anyone from making an erl_tracer nif that forward these events to DTrace. | |||
2017-11-30 | Stop testing use_threads in sendfile_SUITE | John Högberg | |
The option no longer does anything at all. | |||
2017-11-30 | Skip efile_SUITE:iter_max_files on Windows | John Högberg | |
2017-11-30 | Tighten timings in dirty_*if_SUITE:dirty_scheduler_exit | John Högberg | |
There doesn't seem to be any science behind the long delays, and the (newly introduced) dry run forces us to eat them twice, so they've been shortened to more reasonable values. | |||
2017-11-30 | Fix dirty_*if_SUITE after file rewrite | John Högberg | |
Code loading is done through dirty IO now, causing the dirty_scheduler_exit tests to fail as they block their own progress by invoking erts_debug:dirty_io(wait, _); the spawned processes will exit normally before we have a chance to kill them. To get around this, we perform a dry run to ensure that all required code is loaded. It isn't particularly pretty (or fast) but it saves us the hassle of maintaining a module list (cf. embedded mode). | |||
2017-11-30 | Stop testing the artificial size limit on writes | John Högberg | |
The old driver didn't fall back to using write(2) if writev(2) failed due to the combined length of the iov overflowing a ssize_t, but the new one doesn't have any problems with it so we failed this test with a case_clause error on 32-bit machines. | |||
2017-11-30 | Stop using prim_file directly in test_server | John Högberg | |
Files opened with the file module are not guaranteed to work with prim_file, even when opened in raw mode. | |||
2017-11-30 | get_cwd/1 on non-existent drives should error out | John Högberg | |
2017-11-30 | Reads that draw from both buffer and file must work | John Högberg | |
2017-11-30 | Fix incorrect assumption about process activity | John Högberg | |
The tests assume that the most active process will be the current one, which is no longer true since the delayed_write option now uses a wrapper process for much of its work. The timeout for this test has been increased to account for the lack of delayed_write; 60s was enough for everything except the debug build on some machines. | |||
2017-11-30 | Volume-relative paths must work on Windows | John Högberg | |
2017-11-30 | Operations on closed raw files should return EINVAL | John Högberg | |
2017-11-30 | Use lexemes/2 instead of the deprecated tokens/2 | John Högberg | |
2017-11-30 | Remove port subtest in qlc_SUITE:sort | John Högberg | |
This subtest revolves around the possibility that the underlying port can be killed, which is nonsense now that the file suite no longer uses ports for anything. | |||
2017-11-30 | Remove disk_log_SUITE:evil | John Högberg | |
This test revolves around the possibility that the underlying port can be killed, which is nonsense now that the file suite no longer uses ports for anything. | |||
2017-11-30 | Remove efile_SUITE:async_dist | John Högberg | |
This test is irrelevant as the new implementation doesn't use async threads. | |||
2017-11-30 | Ensure that trailing slashes are ignored on list_dir | John Högberg | |
2017-11-30 | Ensure that root paths are translated to our preferred form | John Högberg | |
2017-11-30 | Tighten timings in delayed_write | John Högberg | |
The cumulative wait time was as long as the delay itself in the flush-on-size test, causing the test to pass because the write managed to time out. | |||
2017-11-30 | pread/2 must always return a list of results | John Högberg | |
2017-11-30 | Test opening raw files in the same manner as regular ones | John Högberg | |
2017-11-30 | Add microbenchmarks for file:read/2 and file:write/2 | John Högberg | |
2017-11-30 | Account for new behavior in tests that touch prim_file | John Högberg | |
This also hides the module behind ?PRIM_FILE to make testing new implementations less painful. | |||
2017-11-30 | Reimplement efile_drv as a dirty NIF | John Högberg | |
This improves the latency of file operations as dirty schedulers are a bit more eager to run jobs than async threads, and use a single global queue rather than per-thread queues, eliminating the risk of a job stalling behind a long-running job on the same thread while other async threads sit idle. There's no such thing as a free lunch though; the lowered latency comes at the cost of increased busy-waiting which may have an adverse effect on some applications. This behavior can be tweaked with the +sbwt flag, but unfortunately it affects all types of schedulers and not just dirty ones. We plan to add type-specific flags at a later stage. sendfile has been moved to inet_drv to lessen the effect of a nasty race; the cooperation between inet_drv and efile has never been airtight and the socket dying at the wrong time (Regardless of reason) could result in fd aliasing. Moving it to the inet driver makes it impossible to trigger this by closing the socket in the middle of a sendfile operation, while still allowing it to be aborted -- something that can't be done if it stays in the file driver. The race still occurs if the controlling process dies in the short window between dispatching the sendfile operation and the dup(2) call in the driver, but it's much less likely to happen now. A proper fix is in the works. -- Notable functional differences: * The use_threads option for file:sendfile/5 no longer has any effect. * The file-specific DTrace probes have been removed. The same effect can be achieved with normal tracing together with the nif__entry/nif__return probes to track scheduling. -- OTP-14256 | |||
2017-11-30 | Add a mutable binary buffer type (prim_buffer) | John Högberg | |
2017-11-30 | Change resource_monitors' lock order | John Högberg | |
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. | |||
2017-11-30 | Add enif_ioq_peek_head | John Högberg | |
This introduces a way to retrieve erlang terms from NIF IO queues without having to resort to copying. OTP-14797 | |||
2017-11-30 | Merge branch 'maint' | Sverker Eriksson | |
2017-11-30 | Merge PR-1636 from nox/enif-realloc | Sverker Eriksson | |
Document enif_realloc and pointer alignment guarantees | |||
2017-11-30 | Update syntax_tools to support the stacktrace variable | Björn Gustavsson | |
2017-11-30 | Add documentation for the new stacktrace syntax | Björn Gustavsson | |
2017-11-30 | Use the new syntax in more test suites | Björn Gustavsson | |
2017-11-30 | Add syntax in try/catch to retrieve the stacktrace directly | Björn Gustavsson | |
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 -> . . . | |||
2017-11-30 | erl_parse: Use a new pat_expr rule for pattern expressions | Björn Gustavsson | |
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. | |||
2017-11-30 | Stop trying to maximize the use of x(0) | Björn Gustavsson | |
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. | |||
2017-11-30 | Merge branch 'maint' | Dan Gudmundsson | |
* maint: Fix type create_option() in mnesia | |||
2017-11-30 | Merge pull request #1647 from aboroska/fix-mnesia-type-create_option | Dan Gudmundsson | |
Fix type create_option() in mnesia |