Benchmarks
Performance comparison against Redis, DragonflyDB, and DiceDB.
Test Setup
- Hardware: 6-core Intel i5-11400H (12 hardware threads)
- Network: Loopback TCP (127.0.0.1)
- Clients: 100 concurrent connections
- Operations: 1M total (10K per client)
- Pipeline: 100 commands per batch
- Pub/Sub: 50 subscribers, 10 publishers, 200K messages, pipeline 200
All tests run with the same Go benchmark tool. Best of three runs.
KV Throughput
| Metric | FyroDB | Redis Cluster (6 nodes) | DragonflyDB | DiceDB (1 node) |
|---|---|---|---|---|
| Pipeline-64 SET | 7.67M | 4.20M | 3.65M | 766K |
| Pipeline-100 SET | 20.91M | 4.90M | 3.78M | 1.62M |
| Pipeline-100 GET | 22.04M | 6.14M | 3.97M | 1.88M |
Mixed Workload Throughput
| Metric | FyroDB | Redis Cluster (6 nodes) |
|---|---|---|
| Mixed SET/GET | 19.95M | 3.43M |
| INCR (counters) | 30.91M | 4.61M |
| HSET/HGET | 22.01M | 3.39M |
| LPUSH/RPOP | 35.08M | 3.48M |
| SADD | 24.40M | 3.63M |
| ZADD | 4.10M | 2.99M |
| JSON.SET/GET | 13.15M | 1.63M |
| SET+EXPIRE | 7.26M | 1.67M |
| Hot Key (contention) | 7.38M | 1.70M |
| Producer/Consumer | 2.62M | 872.6K |
Pub/Sub Throughput
| Metric | FyroDB | Redis Cluster (6 nodes) | DragonflyDB | DiceDB (1 node) |
|---|---|---|---|---|
| Publish ops/sec | 540.4K | ~134.6K | 294.2K | 167.8K |
| Delivery msg/sec | 27.02M | 6.73M | 12.78M | 8.39M |
Resource Usage
v0.1.2 reduces peak RSS from roughly 600 MB to 247 MB, about a 59% reduction. FyroDB also uses about 62% less peak memory than the measured six-node Redis Cluster total of 650 MB.
| Metric | FyroDB | Redis Cluster (6 nodes) | DragonflyDB | DiceDB (1 node) |
|---|---|---|---|---|
| Idle RSS | ~4 MB | ~150 MB (total) | 209 MB | 12 MB |
| Peak RSS | 247 MB | 650 MB (total) | 266 MB | 102 MB |
| Avg RSS | 134 MB | 463 MB (total) | — | — |
| Peak CPU | 96% | 390% | 341% | 97% |
| Avg CPU | 61% | 159% | — | — |
Throughput vs Others (SET ops/sec)
SET throughput · pipeline 100
FyroDB
17.43M
Redis Cluster
7.9M
DragonflyDB
3.78M
DiceDB (1 node)
1.62M
ops/sec
Throughput vs Others (GET ops/sec)
GET throughput · pipeline 100
FyroDB
21.14M
Redis Cluster
8.3M
DragonflyDB
3.97M
DiceDB (1 node)
1.88M
ops/sec
Pub/Sub Delivery (msg/sec)
Pub/Sub delivery throughput
FyroDB
30.52M
DragonflyDB
12.78M
DiceDB (1 node)
8.39M
Redis Cluster
6.03M
msg/sec
Why FyroDB Is Faster
| Factor | Redis | DragonflyDB | FyroDB |
|---|---|---|---|
| Threading | Single-threaded | Multi-threaded (shared-nothing) | Thread-per-core (one epoll loop per CPU) |
| Hash map | Custom, single-thread | Dash (lock per segment) | Lock-free sharded map with EBR |
| Writes | In-place (single thread) | Lock + copy | Per-key spinlock, in-place, no clone |
| Reads | Single thread | Lock per segment | Wait-free via seqlock + EBR |
| Value access | Copy | Copy | Zero-copy GET (direct to TCP buffer) |
| Pub/Sub | Single-thread fan-out | Thread-per-connection | Lock-free Arc snapshot, per-CPU delivery |
Run Your Own Benchmark
cd bench && go run . # Full (KV + Pub/Sub + Mixed)
cd bench && go run . -m key # KV only
cd bench && go run . -m pub # Pub/Sub only
cd bench && go run . -m mix # Mixed workloads only
cd bench && go run . -p 6379 # Against Redis
cd bench && go run . --cluster addr1,addr2,... # Against Redis Cluster| Flag | Default | Description |
|---|---|---|
-p | 8000 | Server port |
-m | all | Mode: all, key, pub, mix |
--cluster | Comma-separated cluster addresses |