diff options
| author | eunhhu <[email protected]> | 2026-09-26 05:48:40 +0100 |
|---|---|---|
| committer | eunhhu <[email protected]> | 2026-09-26 05:48:40 +0100 |
| commit | c7ae77cdf4623c3eb07935081510478be9063024 (patch) | |
| tree | 79430358736adab332b4d5bb61c9e7b78e67a30f /benchmarks/http/run.py | |
| parent | 7771461a93f993425f97d4e05c91e64d17179e60 (diff) | |
| download | pure-c7ae77cdf4623c3eb07935081510478be9063024.tar.gz pure-c7ae77cdf4623c3eb07935081510478be9063024.zip | |
Shard pure-serve across cores
A burst now looks at the store once (pure_store_pin) instead of once per
request; another shard's commit ends before its answer is sent, so a
request made after that answer still reads it. With this alone one thread
serves 125k small keep-alive reads per second, as many as axum on three
cores, with a shorter p99.
--threads N runs a shard per thread: its own SO_REUSEPORT listener, epoll
set, runtime domain, app and store handle. Writer sessions of the tree
store now take turns inside a process with a mutex (the file lock belongs
to the process and does not keep threads apart), and revisions settle
concurrent edits of a key. A module with states runs on one thread. Three
shards serve 151k reads per second; they still commit one by one, so
durable writes and 1 MiB reads are better on one thread for now, which
stays the default. Note 075 records the numbers.
Diffstat (limited to 'benchmarks/http/run.py')
| -rw-r--r-- | benchmarks/http/run.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/benchmarks/http/run.py b/benchmarks/http/run.py index 96f4bc0..8ce1474 100644 --- a/benchmarks/http/run.py +++ b/benchmarks/http/run.py @@ -72,6 +72,8 @@ def main(): '--store', d, '--port', '0', '--budget', str(args.budget)], 'pure-serve': lambda d: [PURE / 'build/pure-serve', '--module', args.module, '--store', d, '--port', '0', '--budget', str(args.budget)], + 'pure-serve-3': lambda d: [PURE / 'build/pure-serve', '--module', args.module, '--store', d, '--port', '0', + '--budget', str(args.budget), '--threads', '3'], 'axum-memory': lambda d: [axum, '--port', '0'], 'axum-durable': lambda d: [axum, '--port', '0', '--durable', d], 'axum-atomic': lambda d: [axum, '--port', '0', '--atomic', d], |
