Age | Commit message (Collapse) | Author |
|
Since the API for headers/trailers seem to be very awkward to
work with when using non-blocking io the feature is dropped
for now. See unix_efile.c for more details.
|
|
|
|
|
|
|
|
Since sendfile could in theory be used to send to any type
of file descriptor in *nix, it is a better fit to have it
in file.
|
|
Have to figure out how to represent progress in header writing when
using non-blocking, not sure how to do this.
|
|
This is needed because aync job will not call free_sendfile
if there is an async_ready callback.
|
|
|
|
Tests for when a gen_tcp:send/recv is ordered while a
sendfile is in progress.
|
|
|
|
This is needed because otherwise there could be scenarios
when the efile driver blocks a fd and then crashes without
the inet driver ever finding out. Now when the process
crashes the port will close and we can cleanup in the inet
driver.
|
|
Because the sending process has to be the controlling process
of the tcp socket used to send data it is not possible to use
the file_server
|
|
It is not possible to use the maximum size_t/off_t for the chunks
as that causes sendfile to return einval. 3GB seems to work on all
*nix platforms.
|
|
|
|
|
|
|
|
|
|
Ignore fd is a feature used by sendfile to temporarily remove
all driver_select calls on that fd so that another driver can
select on it. It also delays all actions which sends or receives
data in that fd until in the fd is no longer ignored.
Only the controlling_process should use the feature as it is otherwise
possible that the ignore will never be cleaned up and hence create
a memory leak in the driver.
An ignored driver will not detect that an fd has been closed until
it is unignored.
|
|
|
|
|
|
|
|
|
|
When there are no async threads sendfile will use the
ready_output select on the socket fd to know when to send
data.
The file_desc will also be put in the sending sendfile_state
which buffers all other commands to that file until the
sendfile is done.
|
|
Move sendfile data to invoke data instead of file_descr.
Remove usage of ready_output when doing a send.
If told to send 0 bytes, file_sendfile now sends the entire file
for linux.
|
|
outputv will always be used so removed output to decrease
confusion.
|
|
Move the command handling to outputv in preparation for
header and trailer inclusion in the sendfile api.
Use the standard efile communication functions for sendfile.
|
|
Created erlang fallback for sendfile in gen_tcp and
moved sendfile from file to gen_tcp. Also created testcases
for testing all different options to sendfile.
For info about how sendfile should work see the BSD man pages
as they contain a more complete API than other *nixes.
|
|
|
|
Allow Erlang code to use sendfile() where available by wrapping it as
file:sendfile/4 and file:sendfile/2.
sendfile(2) - Linux man page:
"sendfile() copies data between one file descriptor and another.
Because this copying is done within the kernel, sendfile() is more
efficient than the combination of read(2) and write(2), which would
require transferring data to and from user space."
|
|
|
|
* bjorn/remove-regexp-module/OTP-9737:
stdlib: Remove the deprecated regexp module
|
|
* ia/ssl/renegotiation-dos-attack/OTP-9739:
Mitigate Computational DoS attack
|
|
|
|
On my Linux computer, building the entire Erlang/OTP system
with hipe disabled took about 8 minutes. With hipe enabled,
but without any native code, the build took about 23 minutes,
i.e. more than 3 times slower. (The computer has 4 cores, and
I used 'make -j6'.)
On my eight-core Mac (running 'make -j10') there was only a slight
slowdown when hipe was enabled.
The culprit is hipe_unified_loader:post_beam_load/1, which will be
called every time a module is loaded (even if the module contains no
native code). If post_beam_load/1 is called in a hipe-enabled
emulator, it will block multi-scheduling, even if no work needs to be
done. Apparently the cost for blocking multi-scheduling can vary
greatly, depending on the operating system and system load.
As a quick and conservative fix, don't call post_beam_load/1 unless
some native code has been previously loaded.
|
|
|
|
This reverts commit e21ff9b0b69219ab3853be7e80813156113152b7.
|
|
|
|
|
|
* dgud/observer/gui/OTP-4779:
[observer] Implemented basic tracing functionality
[observer] Work around wxWidgets windows bug
[observer] Rework tracing part of the gui
[observer] Fix portability bugs
[observer] Improve process_info window
[observer] Misc cleanup and fixes
[observer] Clean up code
[observer] Add a [d]ets viewer, tv replacement
[observer] Started on a wx gui
|
|
* pan/osx_gcc_fixes:
Fix typo in erts/configure.in
Make OTP build w/alternative gcc on MacOS Lion
OTP-9712
|
|
* pan/binary_match_scope/OTP-9701:
Remove remaining gcc 4.6 assigned-but-not-used warnings from erts
Remove GCC 4.6 set-but-not-used warning from erl_bif_binary
Make binary:match with scope return correct values
|
|
* sverk/hipe-without-fpe/OTP-9724:
otp_build: Disable FPE by default on Linux
stdlib: Make sure qlc_SUITE:otp_6964 restores backtrace_depth
erts: Add test for inf/NaN intermediate float results
hipe,erts: Allow hipe without floating point exceptions
hipe: Fix bug in hipe_rtl_lcm:calc_killed_expr_bb
erts: Rename macros used by float instructions without FPE
|
|
* sa/dialyzer-behaviours:
Wrap up behaviours patch for Dialyzer
Detection of callback-spec discrepancies
Allow none() as return value in callbacks
Behaviour callback discrepancy detection for Dialyzer
Add lookup function for callbacks
Store callbacks in codeserver and PLT
Collect callback definitions during compilation
Update inets results
OTP-9731
|
|
Use ttb which does most of the work already.
|
|
* ia/public_key/ssl/git-ignore:
Updated public_key and ssl ignores
|
|
* lukas/common_test/make_cth_non_alpha/OTP-9449:
Remove alpha notice since CTH are now final
|
|
* peppe/common_test/css_and_xhtml:
Make absolute paths in log files relative
Fix bad error printout
Copy default CSS file to log directory before test run
Add CSS stylesheet for the text and tables in Common Test and Test Server
OTP-9706
|
|
* lars/orber/remove-seed-in-testcases/OTP-9728:
[orber] Remove usage of ssl:seed/1
|
|
Enable warnings by default, add two options for suppressing them,
fix warning formatting and update testsuites.
|
|
|