Skip to content

perf(umbp): give ranged get/put separate scratch arenas - #581

Merged
isytwu merged 1 commit into
refactor/umbp-backend-agnosticfrom
perf/umbp-ranged-scratch-split
Aug 19, 2026
Merged

isytwu merged 1 commit into
refactor/umbp-backend-agnosticfrom
perf/umbp-ranged-scratch-split

Conversation

@isytwu

@isytwu isytwu commented Aug 19, 2026

Copy link
Copy Markdown
Collaborator

What

Remote BatchGetRanges and BatchPutRanges shared one scratch arena and a
single mutex held across the whole network round-trip, so a remote ranged get
and put serialized against each other.

This gives each direction its own RDMA-registered arena and mutex:

  • DistributedClient allocates a GET arena and a PUT arena (each sized by
    ranged_scratch_size) and registers both.
  • PoolClientConfig carries ranged_get_scratch_* / ranged_put_scratch_*;
    BatchGetRanges / BatchPutRanges each take their own arena + mutex.

A remote ranged get and put now overlap; two same-direction ops still
serialize on that direction's mutex (unchanged).

Results (in-process 2-node bench, mlx5 RoCE, mixed remote get+put)

threads single arena separate arenas
4 2.35 GiB/s 3.82 GiB/s (+63%)
8 2.18 GiB/s 3.42 GiB/s (+57%)

Tests

test_umbp_pool_client_ranges (7/7): adds SplitRemotePutThenGetRoundTrips
and SplitConcurrentGetPutDoNotClobber (concurrent get/put, byte-for-byte
verify). cross_node_smoke / pool_client_batch_put / medium_selection
still pass.

🤖 Generated with Claude Code

Remote BatchGetRanges and BatchPutRanges shared one scratch arena and a
single mutex held across the whole network round-trip, so a remote ranged
get and put serialized against each other. Allocate a separate RDMA-
registered arena and mutex per direction (DistributedClient owns both,
each sized by ranged_scratch_size) so load/offload overlap instead of
blocking: mixed remote get+put throughput improves ~60% at 4-8 threads;
same-direction behavior is unchanged.

Also adds concurrency correctness tests: a separate-arena remote
put-then-get round-trip and a concurrent get/put no-clobber check.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@isytwu isytwu self-assigned this Aug 19, 2026
@isytwu
isytwu requested a review from TianDi101 August 19, 2026 06:11
@isytwu
isytwu merged commit 09cd290 into refactor/umbp-backend-agnostic Aug 19, 2026
@isytwu
isytwu deleted the perf/umbp-ranged-scratch-split branch August 19, 2026 11:57
TianDi101 pushed a commit that referenced this pull request Sep 3, 2026
Remote BatchGetRanges and BatchPutRanges shared one scratch arena and a
single mutex held across the whole network round-trip, so a remote ranged
get and put serialized against each other. Allocate a separate RDMA-
registered arena and mutex per direction (DistributedClient owns both,
each sized by ranged_scratch_size) so load/offload overlap instead of
blocking: mixed remote get+put throughput improves ~60% at 4-8 threads;
same-direction behavior is unchanged.

Also adds concurrency correctness tests: a separate-arena remote
put-then-get round-trip and a concurrent get/put no-clobber check.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant