From 0184c2e0438ac42c44d14e92b13e2807e0a670b3 Mon Sep 17 00:00:00 2001 From: Lukas Larsson Date: Tue, 18 Sep 2018 15:27:01 +0200 Subject: erts: Remove a copy of distribution data payload Before this change the inet driver was in list mode and thus the data from it had to be copied when received by the dist entry. This change puts the tcp port in binary mode and makes the any refc binary created by it be used all the way to the process where it is decoded. Thus eliminating one copy of the entire message payload. --- lib/kernel/src/inet_tcp_dist.erl | 1 + 1 file changed, 1 insertion(+) (limited to 'lib') diff --git a/lib/kernel/src/inet_tcp_dist.erl b/lib/kernel/src/inet_tcp_dist.erl index c37212b0f9..c5a114a9ef 100644 --- a/lib/kernel/src/inet_tcp_dist.erl +++ b/lib/kernel/src/inet_tcp_dist.erl @@ -212,6 +212,7 @@ do_accept(Driver, Kernel, AcceptPid, Socket, MyNode, Allowed, SetupTime) -> [{active, true}, {deliver, port}, {packet, 4}, + binary, nodelay()]) end, f_getll = fun(S) -> -- cgit v1.2.3