10 releases

0.1.9 Feb 22, 2024
0.1.8 Feb 22, 2024

#785 in Network programming

Download history 63/week @ 2024-07-29 34/week @ 2024-09-09 28/week @ 2024-09-16 125/week @ 2024-09-23 56/week @ 2024-09-30 137/week @ 2024-10-07 82/week @ 2024-10-14 16/week @ 2024-10-21 18/week @ 2024-10-28 8/week @ 2024-11-04

131 downloads per month

MIT license

38KB
711 lines

Machnet Rust Bindings

Crates.io Docs.rs Build GitHub License

This repository contains the Rust FFI bindings for Machnet.

Machnet provides an easy way for applications to reduce their datacenter networking latency via kernel-bypass (DPDK-based) messaging. Distributed applications like databases and finance can use Machnet as the networking library to get sub-100 microsecond tail latency at high message rates, e.g., 750,000 1KB request-reply messages per second on Azure F8s_v2 VMs with 61 microsecond P99.9 round-trip latency.

We support a variety of cloud (Azure, AWS, GCP) and bare-metal platforms, OSs, and NICs, evaluated in PERFORMANCE_REPORT.md.

Prerequisites

clang is required to build the Rust bindings. You can install it using the following command:

sudo apt-get update && sudo apt-get install -y clang

It also requires that libmachnet_shim.so is built and installed on the system. You can check out the Machnet repo for the details. Use the build_shim.sh to automatically build and install the libmachnet_shim.so library.

Getting Started

To use the Machnet Rust bindings, add the following to your Cargo.toml:

[dependencies]
machnet = "0.1.9"

Demo

We have a simple msg_gen application that uses the Machnet stack. It is a message generator application that sends variable size messages to a server and receives them back.

For 1 kilobyte message sizes, Rust and C++ show almost identical latencies of 53 and 52 microseconds respectively, indicating their comparable and fast performance.

Open Source Project

This project is an open-source initiative under Microsoft. We welcome contributions and suggestions from the community! See CONTRIBUTING.md for more details.

Microsoft

No runtime deps

~0–1.9MB
~37K SLoC