Add Ascend Cache IO aggregation copy path#1038
Open
NaganooMei wants to merge 10 commits into
Open
Conversation
added 10 commits
June 17, 2026 15:03
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.
Purpose
This PR adds an optional Ascend CacheStore IO aggregation path for small H2D/D2H shard copies.
The default CacheStore path submits one async copy per tensor fragment. For workloads with many small fragments per shard, the submission overhead can become noticeable. This PR introduces an Ascend-only aggregation stream that treats one CacheStore shard as one IO object, stages the contiguous host buffer once, and uses FFTS SDMA descriptors to scatter/gather between the staging buffer and device tensor addresses.
The feature is disabled by default and only available when building with
PLATFORM=ascend/RUNTIME_ENVIRONMENT=ascend.Modifications
StreamOptionsandMakeSharedStream(options)so CacheStore can request a feature-specific Ascend stream while keeping the original stream interface available.CopyStreamas the outer stream pool owner, but allow special CacheStore streams to manage their own internal lanes.AscendIoAggregationStreamandAscendShardIOAggregator.FftsSdmaDispatcherfor building and launching FFTS SDMA copy descriptors.cache_io_aggregationcache_io_aggregation_pipeline_depthcache_io_aggregation_max_ready_lanesPLATFORM=ascendenables ordinary Ascend backend plus IO aggregation code.cache_io_aggregation: falsekeeps the original Ascend copy path.Test
PLATFORM=ascend.cache_io_aggregation=false.cache_io_aggregation=true.