mirror of
https://github.com/kvcache-ai/Mooncake.git
synced 2026-11-05 01:17:55 +00:00
[PR #855] [CLOSED] [WIP]feat(rdma): add parallel memory region registration support #1869
Labels
No labels
ascend
auto-closed
bug
bug
CI/Build
Common
documentation
enhancement
feature request
good first issue
help wanted
high priority
MetaX
nightly-failure
pull-request
PyTorch Backend
question
RFC
Roadmap
stale
Store
Tests
Transfer Engine
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
kvcache-ai/Mooncake#1869
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/kvcache-ai/Mooncake/pull/855
Author: @staryxchen
Created: 9/17/2025
Status: ❌ Closed
Base:
main← Head:feat/add-parallel-mr-registration📝 Commits (3)
ea4cd87feat(rdma): add parallel memory region registration support0aa5f89format and remove some comment3015f10fix(config): change parallel memory region registration to default disabled📊 Changes
3 files changed (+76 additions, -12 deletions)
View changed files
📝
mooncake-transfer-engine/include/config.h(+1 -0)📝
mooncake-transfer-engine/src/config.cpp(+9 -0)📝
mooncake-transfer-engine/src/transport/rdma_transport/rdma_transport.cpp(+66 -12)📄 Description
Summary
This PR introduces a configurable parallel memory region registration feature with significant performance improvements for pre-allocated memory scenarios, while maintaining backward compatibility.
I conducted several tests to validate performance (test code is also attached).
perf.tar.gz
Test Configuration
MC_DISABLE_PARALLEL_REG_MRnot set (parallel registration enabled)MC_DISABLE_PARALLEL_REG_MR=1(sequential registration)Performance Results
Pre-allocated Memory Scenario
Non-pre-allocated Memory Scenario
I had the AI summarize and analyze the test results. Below is the AI's output:
Key Performance Findings
Pre-allocated Memory (500GB)
Non-pre-allocated Memory (500GB)
Analysis
Pre-allocated memory benefits from parallel registration because:
Non-pre-allocated memory performs better with sequential registration because:
Conclusion
The parallel memory registration optimization provides significant performance benefits for pre-allocated memory scenarios, with up to 8x improvement in unregistration performance. However, for large non-pre-allocated memory allocations, sequential registration performs better due to reduced resource contention and kernel overhead.
The
MC_PARALLEL_REG_MRconfiguration option provides the flexibility to choose the optimal strategy based on the specific use case and memory allocation patterns of the application.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.