diff options
author | Rickard Green <[email protected]> | 2013-01-23 14:52:03 +0100 |
---|---|---|
committer | Rickard Green <[email protected]> | 2013-01-23 14:52:03 +0100 |
commit | 6141db8f76d310f648cc8e278cf9b62bf1417ca8 (patch) | |
tree | 4e8e34ff9c53b9ac2650dfb993f2af159acd53f0 /erts/emulator/beam/erl_port.h | |
parent | cc8285ed57ad46fcbbbfb333535ff472dd57ec27 (diff) | |
parent | e3373f0602282040ae7a75b5b7ebbdcae2789c17 (diff) | |
download | otp-6141db8f76d310f648cc8e278cf9b62bf1417ca8.tar.gz otp-6141db8f76d310f648cc8e278cf9b62bf1417ca8.tar.bz2 otp-6141db8f76d310f648cc8e278cf9b62bf1417ca8.zip |
Merge branch 'rickard/r16/port-optimizations/OTP-10336'
* rickard/r16/port-optimizations/OTP-10336:
Bump reductions also for immediate driver calls
Add 'port_count' and 'port_limit' to system_info/1 spec
Fix documentation
Replace use of deprecated functions in test cases
Replace use of driver_send_term() with erl_drv_send_term()
Conflicts:
erts/preloaded/ebin/erlang.beam
Diffstat (limited to 'erts/emulator/beam/erl_port.h')
-rw-r--r-- | erts/emulator/beam/erl_port.h | 39 |
1 files changed, 19 insertions, 20 deletions
diff --git a/erts/emulator/beam/erl_port.h b/erts/emulator/beam/erl_port.h index fb07f3d5bc..65b4cd0bfe 100644 --- a/erts/emulator/beam/erl_port.h +++ b/erts/emulator/beam/erl_port.h @@ -273,29 +273,28 @@ extern erts_smp_atomic_t erts_bytes_in; /* no bytes sent into the system */ (ERTS_PORT_SFLGS_INVALID_LOOKUP \ | ERTS_PORT_SFLG_DISTRIBUTION) - /* * Costs in reductions for some port operations. */ -#define ERTS_PORT_REDS_EXECUTE 10 -#define ERTS_PORT_REDS_FREE 100 -#define ERTS_PORT_REDS_TIMEOUT 400 -#define ERTS_PORT_REDS_INPUT 400 -#define ERTS_PORT_REDS_OUTPUT 400 -#define ERTS_PORT_REDS_EVENT 400 -#define ERTS_PORT_REDS_CMD_OUTPUTV 400 -#define ERTS_PORT_REDS_CMD_OUTPUT 400 -#define ERTS_PORT_REDS_EXIT 300 -#define ERTS_PORT_REDS_CONNECT 40 -#define ERTS_PORT_REDS_UNLINK 40 -#define ERTS_PORT_REDS_LINK 40 -#define ERTS_PORT_REDS_BADSIG 40 -#define ERTS_PORT_REDS_CONTROL 400 -#define ERTS_PORT_REDS_CALL 400 -#define ERTS_PORT_REDS_INFO 100 -#define ERTS_PORT_REDS_SET_DATA 40 -#define ERTS_PORT_REDS_GET_DATA 40 -#define ERTS_PORT_REDS_TERMINATE 200 +#define ERTS_PORT_REDS_EXECUTE (CONTEXT_REDS/4) +#define ERTS_PORT_REDS_FREE (CONTEXT_REDS/400) +#define ERTS_PORT_REDS_TIMEOUT (CONTEXT_REDS/100) +#define ERTS_PORT_REDS_INPUT (CONTEXT_REDS/100) +#define ERTS_PORT_REDS_OUTPUT (CONTEXT_REDS/100) +#define ERTS_PORT_REDS_EVENT (CONTEXT_REDS/100) +#define ERTS_PORT_REDS_CMD_OUTPUTV (CONTEXT_REDS/100) +#define ERTS_PORT_REDS_CMD_OUTPUT (CONTEXT_REDS/100) +#define ERTS_PORT_REDS_EXIT (CONTEXT_REDS/100) +#define ERTS_PORT_REDS_CONNECT (CONTEXT_REDS/200) +#define ERTS_PORT_REDS_UNLINK (CONTEXT_REDS/200) +#define ERTS_PORT_REDS_LINK (CONTEXT_REDS/200) +#define ERTS_PORT_REDS_BADSIG (CONTEXT_REDS/200) +#define ERTS_PORT_REDS_CONTROL (CONTEXT_REDS/100) +#define ERTS_PORT_REDS_CALL (CONTEXT_REDS/50) +#define ERTS_PORT_REDS_INFO (CONTEXT_REDS/100) +#define ERTS_PORT_REDS_SET_DATA (CONTEXT_REDS/100) +#define ERTS_PORT_REDS_GET_DATA (CONTEXT_REDS/100) +#define ERTS_PORT_REDS_TERMINATE (CONTEXT_REDS/50) void print_port_info(Port *, int, void *); void erts_port_free(Port *); |