23 min read
librats vs libp2p: what a 5 MB peer-to-peer node buys you
Benchmarking librats, my C++ peer-to-peer library, against js-libp2p: 22x less memory, a 9.3x small-message gap, and a dead heat on bulk throughput.
5 articles
Benchmarking librats, my C++ peer-to-peer library, against js-libp2p: 22x less memory, a 9.3x small-message gap, and a dead heat on bulk throughput.
librats is an MIT-licensed peer-to-peer library: encrypted transport, mainline DHT discovery, NAT traversal and pub/sub in 5 MB for C++, Node.js, Python and Android.
Linking MinGW binaries fully statically with CMake to drop the libgcc_s_seh-1.dll and libstdc++-6.dll runtime dependencies from your Windows build.
Detecting CPU architecture (x86, x86_64, ARM, ARM64) at compile time with portable C/C++ preprocessor macros across GCC, Clang and MSVC.
GStreamer from C/C++: building H264/MP4 decode pipelines, gst-launch-1.0 basics, appsink/appsrc buffer manipulation and camera capture.