[Feature][QDP] Add MPI-ready distributed amplitude execution scaffolding#1296
[Feature][QDP] Add MPI-ready distributed amplitude execution scaffolding#1296viiccwen wants to merge 26 commits into
Conversation
|
Nice one, will probably take a look on Thursday. |
ryankert01
left a comment
There was a problem hiding this comment.
Hi, nice initiative. Curious of can it be plugging in our current lighting.gpu (penny lane) workflow?
mahout.qdp -> lighting.gpu (by zero copy)
4145efa to
baa6a90
Compare
|
@ryankert01, after researching, I think the main gap is on the From what I can tell, the missing piece is not “can Mahout produce a GPU-resident state?” but “can So my current estimate would be:
So yes: for a proper zero-copy integration, I would expect roughly 3 PRs for a narrow MVP. |
|
@viiccwen I think since it's 3 PRs away and so big. Can we postpone it to the next release? It will be more mature at next release and we can think about its detail. |
Sure, it'll be fine. |
|
@viiccwen do you have a design doc for this? |
|
Also please solve conflicts |
2a2c952 to
14faf38
Compare
|
hey @viiccwen — i think we'll overlap here. i'm planning a follow-up pr for ddp rank-aware sharding in two quick questions:
happy to wait if you're close, otherwise i'll build single-node-first and layer mpi on top later. |
|
This pull request has been automatically marked as stale because it has not had any activity for 30 days. It will be closed in another 7 days if no further activity occurs. Thank you for your contribution. If you'd like to keep this open, leave any comment and the stale label will be removed. You can always ask for help on the Mahout dev mailing list or in GitHub Discussions. |
6eefecf to
16f588f
Compare
5906476 to
d535d97
Compare
|
This branch supports single-process, single-node multi-GPU shard materialization with zero-copy local shard views. It does not yet implement true MPI multi-rank execution or cross-rank GPU-resident zero-copy transport. |
02a6936 to
939027e
Compare
Related Issues
Closes #1295
Part of #1297
Summary
This PR adds the first QDP-native distributed GPU state execution foundation, with amplitude state construction as the first workload.
The implementation is intentionally MPI-ready but does not require MPI or NCCL as mandatory dependencies. The executable path in this PR is a real single-process fallback that runs through the same rank-local planning, runtime, transport, and state boundaries that a future MPI-backed execution path should use.
In other words, this PR is not claiming full
mpirun -n Nsupport yet. It establishes the architecture and a testable fallback boundary that future MPI, CUDA-aware MPI, and NCCL backends can replace or extend.The main architecture boundary is intentionally split into four layers:
Current Capability
This PR currently supports:
DistributedExecutionContextDistributedStatePlanDistributedAmplitudePlanCollectiveCommunicatorLocalCollectiveCommunicatorDistributedStateVector::local_shard_views()device_idto CUDA handle resolution, so shard metadata, active CUDA device context, and allocated buffers stay alignedNotImplementedfor GPU-resident collectivesArchitecture Shape
sequenceDiagram participant Caller as QdpEngine caller participant Engine as QdpEngine participant Ctx as DistributedExecutionContext participant Planner as PlacementPlanner participant StatePlan as DistributedStatePlan participant AmpPlan as DistributedAmplitudePlan participant Runtime as distributed runtime participant Comm as CollectiveCommunicator participant State as DistributedStateVector Caller->>Engine: submit distributed amplitude request Engine->>Engine: validate input and resolve request Engine->>Ctx: construct rank-local execution context Engine->>Planner: build rank-local placement plan Planner-->>Engine: placement + shard ranges Engine->>StatePlan: build shared shard/rank contract StatePlan-->>AmpPlan: wrap for amplitude workload AmpPlan->>Runtime: execute local-rank shard work Runtime->>Runtime: compute local norm contribution Runtime->>Comm: all_reduce_sum_f64(local_norm_sq) Comm-->>Runtime: global norm Runtime->>Runtime: allocate and encode local GPU shards Runtime-->>State: local distributed state State-->>Caller: zero-copy local shard views availableThis PR does not yet support:
Follow-up Work
CollectiveCommunicator.mpirun -n Nlaunch path.DeviceCollectiveCommunicatorbackends.