Skip to main content
Waltz is Firedancer’s collection of network protocol implementations and I/O primitives, providing high-performance networking capabilities for validator operations. It includes QUIC, HTTP/2, TLS, gRPC, and low-level network stack components.

Overview

Waltz provides production-grade implementations of modern network protocols optimized for Firedancer’s high-throughput requirements. The components are designed to work with Tango’s IPC framework and support zero-copy operations where possible.
Waltz protocols are built for performance-critical paths in validator operations, particularly TPU (Transaction Processing Unit) ingress over QUIC.

Core Protocols

QUIC (quic/)

RFC 9000/9001 compliant QUIC implementation:Overview:
Features:
  • 0-RTT connection establishment: Reduced handshake latency
  • Connection multiplexing: Multiple streams per connection
  • Loss recovery: Selective acknowledgment
  • Congestion control: Cubic/BBR algorithms
  • Connection migration: IP/port changes without reconnection
Memory management:
  • Pre-allocated connection slots
  • Uniform stream buffers
  • Configurable limits via fd_quic_limits_t
  • Workspace-backed allocation
Lifecycle:
API example:
Use cases:
  • Solana TPU (Transaction Processing Unit) ingress
  • Validator-to-validator communication
  • RPC over QUIC
  • High-throughput packet delivery
Performance:
  • Single-threaded, non-blocking
  • Scales via multiple instances
  • RX steering by connection ID
  • Zero-copy where possible

HTTP/2 (h2/)

HTTP/2 protocol implementation:Components:
Features:
  • Binary framing protocol
  • Stream multiplexing
  • Header compression (HPACK)
  • Server push
  • Flow control
Stream management:
  • Multiple concurrent streams
  • Priority and dependency
  • Stream state tracking
  • Graceful shutdown
Buffer abstractions:
  • fd_h2_rbuf: Ring buffer interface
  • fd_h2_rbuf_ossl: OpenSSL backend
  • fd_h2_rbuf_sock: Socket backend

gRPC (grpc/)

gRPC client implementation:Components:
Features:
  • Unary and streaming RPCs
  • Protocol buffer serialization
  • HTTP/2 transport
  • Metadata support
Use cases:
  • External service integration
  • Monitoring and observability
  • Control plane communication

TLS (tls/)

TLS 1.3 encryption layer:Integration:
  • Used by QUIC for encryption
  • Standalone TLS connections
  • Certificate management
  • Session resumption
Cipher suites:
  • AES-GCM (hardware accelerated)
  • ChaCha20-Poly1305
  • Forward secrecy (ECDHE)
Certificate handling:
  • X.509 certificate parsing (Ballet x509)
  • Certificate chain validation
  • Private key operations

IP Layer (ip/)

IPv4/IPv6 packet processing:Features:
  • Packet parsing and generation
  • Checksum calculation (hardware offload)
  • Fragmentation/reassembly
  • MTU handling
Supported:
  • IPv4 over Ethernet (EN10MB)
  • IPv6 (partial support)
  • UDP transport

Neighbor Discovery (neigh/)

ARP/NDP resolution:Functions:
  • MAC address resolution
  • Neighbor cache management
  • ARP request/reply
  • IPv6 Neighbor Discovery

Routing (resolv/)

DNS resolution and routing:Features:
  • DNS A/AAAA record lookup
  • Caching resolver
  • Timeout and retry logic

MIB (mib/)

Management Information Base:Metrics:
  • Network statistics
  • Connection state
  • Error counters
  • Performance monitoring

Async I/O (aio/)

Asynchronous I/O framework:Components:
Abstractions:
  • Non-blocking I/O operations
  • Event-driven packet delivery
  • Multiple backend support
Backends:
  • Tango (mcache/dcache)
  • PCAP-NG files (capture/replay)
  • Network sockets
PCAP-NG support:
Tango integration:

XDP (xdp/)

AF_XDP (eXpress Data Path) integration:Features:
  • Kernel bypass networking
  • Zero-copy packet I/O
  • High-performance RX/TX
  • Hardware queue steering
Benefits:
  • Lower latency than sockets
  • Higher throughput
  • CPU efficiency
  • Still in kernel (vs. DPDK)

eBPF (ebpf/)

eBPF program integration:Components:
Use cases:
  • XDP program loading
  • Packet filtering
  • Load balancing
  • DDoS mitigation

UDP Sockets (udpsock/)

High-performance UDP socket wrapper:Features:
  • Multi-queue support
  • SO_REUSEPORT load balancing
  • Socket options optimization
  • Error handling

RTT Estimation (fd_rtt_est.h)

Round-trip time estimation:Algorithm:
Usage:
  • Congestion control
  • Timeout calculation
  • Connection quality monitoring

Token Bucket (fd_token_bucket.h)

Rate limiting via token bucket:Implementation:
Use cases:
  • Connection rate limiting
  • Bandwidth throttling
  • QoS enforcement
  • DDoS mitigation

OpenSSL Integration (openssl/)

OpenSSL library integration:Features:
  • Cryptographic operations
  • TLS handshake
  • Certificate operations
  • Hardware acceleration

Configuration

QUIC Configuration

Performance Features

  • Zero-copy: Direct memory access via Tango dcache
  • Kernel bypass: AF_XDP for high-performance networking
  • Hardware offload: Checksum, TSO, LRO when available
  • Multi-queue: Parallel RX/TX queues
  • NUMA awareness: Memory locality optimization

Network Topology

Typical Firedancer networking:
Flow:
  1. NIC receives packets (XDP)
  2. Waltz QUIC decrypts and demuxes
  3. Tango IPC passes to verify tiles
  4. Ballet performs signature verification
  5. Continue through Disco pipeline

MTU & Sizing

Usage Examples

Platform Support

Linux:
  • AF_XDP (kernel 4.18+)
  • eBPF (kernel 4.15+)
  • io_uring (kernel 5.1+)
  • SO_REUSEPORT (kernel 3.9+)
Hardware offloads:
  • Checksum offload (IP, TCP, UDP)
  • TSO (TCP Segmentation Offload)
  • LRO (Large Receive Offload)
  • RSS (Receive Side Scaling)

Header Files

  • Disco - Uses Waltz for network tile operations
  • Tango - IPC framework for inter-tile communication
  • Ballet - Cryptographic primitives for TLS/QUIC