Repository navigation
[Bugfix][TENT] Submit merged staging requests only once - #4797
Merged
Merged
Conversation
9 tasks done
9 of 15 tasks
lhzds
marked this pull request as ready for review
October 26, 2026 18:08
lhzds
requested review from
00fish0,
alogfans,
chestnut-Q,
doujiang24,
dtcccc and
staryxchen
as code owners
October 26, 2026 18:08
wzy-782
added a commit
to wzy-782/Mooncake
that referenced
this pull request
Oct 29, 2026
Conflicts with upstream main, resolved: - transfer_engine_impl.cpp, planTransport (getTransportType before kvcache-ai#4378): upstream added the XPU dma-buf RDMA (kvcache-ai#4378) and same-host XPU IPC (kvcache-ai#4379) routes. A request with a TPU side always stages and never takes either route; XPU and MLU requests behave as upstream. - transfer_engine_impl.cpp, findStagingPolicy: #2's combined TPU/XPU/MLU staging block replaces the old TPU case, with upstream's note on the XPU dma-buf bypass. XPU memory is no longer called never NIC-addressable. - transfer_engine_impl.cpp, submitTransfer: upstream's progress lock (kvcache-ai#4720) around #2's prepareSubmit call with the staged route. - tent/tests/CMakeLists.txt: #1's TPU adapter tests, then #2's engine, staged-route and host-initiator tests. Known failure: EngineFailoverE2E.MergedStagingRequestsShareOneSubmission (kvcache-ai#4797). The test marks the peer buffer as MLU only in the test thread's segment cache, which is thread-local. #2 re-plans a staged request's hop on the ProxyManager thread, whose cache shows host memory, so the hop gets no route.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
When contiguous requests are merged on the staging path, each original request submits the same merged range. Record the staged owner in the existing
merged_task_id_mapso the remaining requests share its completion and failure status. Batch polling then counts the merged length once.Suggested Merge Priority
Module
mooncake-transfer-engine)Type of Change
How Has This Been Tested?
CPU-only Linux build (
USE_TENT=ON,USE_CUDA=OFF,USE_MLU=OFF,BUILD_UNIT_TESTS=ON), based on37642c5a.cmake --build build-cpu --target tent_engine_failover_e2e_test \ request_merge_test tent_runtime_queue_dispatch_test tent_progress_worker_test -j4 ctest --test-dir build-cpu --output-on-failure --timeout 120 \ -R '^(tent_engine_failover_e2e_test|request_merge_test|tent_runtime_queue_dispatch_test|tent_progress_worker_test)$' build-cpu/mooncake-transfer-engine/tent/tests/tent_engine_failover_e2e_test \ --gtest_filter=EngineFailoverE2E.MergedStagingRequestsShareOneSubmission \ --gtest_repeat=20Checklist
./scripts/code_format.shand scoped pre-commit passAI Assistance Disclosure
OpenAI Codex assisted with implementation, tests, validation and this description.