DEV Community

Gaspard Kirira
Gaspard Kirira

Posted on

Vix.cpp v2.7.0 benchmark: 112k req/s locally on an HP EliteBook

Vix.cpp v2.7.0 benchmark: 112k req/s locally on an HP EliteBook

I have been working on the v2.7.0 release of Vix.cpp, and I wanted to share a small benchmark from the current release build.

This benchmark was not done on a cloud server or a dedicated benchmark machine. It was run locally on my laptop.

Machine

Platform        : linux
Architecture    : x86_64
Kernel version  : 6.17.0-35-generic
Hostname        : softadastra-HP-EliteBook-x360-1030-G3
CPU count       : 8
Page size       : 4096 bytes
Enter fullscreen mode Exit fullscreen mode

Build mode

The project was built in release mode with benchmark mode enabled:

vix build --preset release --build-target all -v --clean -- -DVIX_BENCH_MODE=ON
Enter fullscreen mode Exit fullscreen mode

The server was running with:

Vix.cpp v2.6.0
Threads: 8/8
Mode: run
Status: ready
HTTP: http://localhost:8080/
Enter fullscreen mode Exit fullscreen mode

The benchmark endpoint was simple:

curl http://127.0.0.1:8080/bench
# OK
Enter fullscreen mode Exit fullscreen mode

Benchmark command

wrk -t8 -c800 -d30s --latency http://127.0.0.1:8080/bench
Enter fullscreen mode Exit fullscreen mode

Results

Running 30s test @ http://127.0.0.1:8080/bench
  8 threads and 800 connections

Latency:
  Avg:   7.31ms
  Stdev: 16.26ms
  Max:   606.15ms

Latency Distribution:
  50%:  6.51ms
  75%:  7.59ms
  90%:  8.73ms
  99%: 12.19ms

Requests:
  3,386,276 requests in 30.09s
  112,539.11 requests/sec
Enter fullscreen mode Exit fullscreen mode

Notes

The result I care about most here is not only the 112k req/s, but also the latency distribution.

At 800 concurrent connections, the p99 latency stayed around 12.19ms, which is a good signal for the current direction of the HTTP runtime.

This is still an early benchmark, and I will continue testing with different concurrency levels, different endpoints, and more realistic workloads.

For now, this is a good sign for the v2.7.0 release direction.

The goal with Vix.cpp is simple: make C++ development feel simpler, faster, and more modern without hiding the power of the language.

Top comments (0)