nim-libp2p-experimental/libp2p/muxers/mplex
Jacek Sieka 6f1ecc8df7
streamline socket read/write hot path (#473)
* streamline socket read/write hot path

This avoids some unnecessary memory copying on the hot path of noise /
mplex, as well as getting rid of a few futures - profiling shows that
this is one of the main culprits of small memory allocations, which
makes sense - this is where gossip fan-out happens.

* fewer futures (and corresponding closures) when sending lpchannel
messages
* avoid data copies when encrypting and framing noise messages
* avoid copying tuple when reading noise data (poor c codegen)
* fix setting eof flag in secure read

* write noise frames in one go

...and closing secure socket once is enough
2020-12-09 08:56:40 -06:00
..
coder.nim streamline socket read/write hot path (#473) 2020-12-09 08:56:40 -06:00
lpchannel.nim streamline socket read/write hot path (#473) 2020-12-09 08:56:40 -06:00
mplex.nim adding libp2p tag to logScope (#465) 2020-12-01 11:34:27 -06:00