aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/dist.h
diff options
context:
space:
mode:
authorRickard Green <[email protected]>2012-08-20 13:48:29 +0200
committerRickard Green <[email protected]>2012-12-03 21:18:08 +0100
commit56cef897ca3ad2377e34a6ea5800a54a28cbeb6e (patch)
tree0cbb2eba5b3de84cc8d22577af454f4ac2f38885 /erts/emulator/beam/dist.h
parent7e789df8dd9c7d86e9cc354521a37aa598aa5ec8 (diff)
downloadotp-56cef897ca3ad2377e34a6ea5800a54a28cbeb6e.tar.gz
otp-56cef897ca3ad2377e34a6ea5800a54a28cbeb6e.tar.bz2
otp-56cef897ca3ad2377e34a6ea5800a54a28cbeb6e.zip
Optimize management of port tasks
Diffstat (limited to 'erts/emulator/beam/dist.h')
-rw-r--r--erts/emulator/beam/dist.h9
1 files changed, 2 insertions, 7 deletions
diff --git a/erts/emulator/beam/dist.h b/erts/emulator/beam/dist.h
index 7de8786c4a..2bc3d9c881 100644
--- a/erts/emulator/beam/dist.h
+++ b/erts/emulator/beam/dist.h
@@ -204,13 +204,8 @@ void erts_schedule_dist_command(Port *prt, DistEntry *dist_entry)
id = dep->cid;
}
- if (!erts_smp_atomic_xchg_mb(&dep->dist_cmd_scheduled, 1)) {
- (void) erts_port_task_schedule(id,
- &dep->dist_cmd,
- ERTS_PORT_TASK_DIST_CMD,
- (ErlDrvEvent) -1,
- NULL);
- }
+ if (!erts_smp_atomic_xchg_mb(&dep->dist_cmd_scheduled, 1))
+ erts_port_task_schedule(id, &dep->dist_cmd, ERTS_PORT_TASK_DIST_CMD);
}
#endif