[GH-ISSUE #156] [Feature Request] support tensor parallelism for multi gpu setup #84

Closed
opened 2026-11-04 01:39:43 +07:00 by bsakaguchi · 9 comments
Owner

Originally created by @megakilo on GitHub (Sep 29, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/156

As of today (v0.1.25), strata supports only layer split. I wonder if tensor split (tensor parallelism) can be added for homogeneous GPUs. This could improve the computation with a small cost of VRAM.

Originally created by @megakilo on GitHub (Sep 29, 2026). Original GitHub issue: https://github.com/Niko1221/Strata/issues/156 As of today (v0.1.25), strata supports only layer split. I wonder if tensor split (tensor parallelism) can be added for homogeneous GPUs. This could improve the computation with a small cost of VRAM.
Author
Owner

@Niko1221 commented on GitHub (Sep 29, 2026):

Thanks for the suggestion. For now multi-GPU means the layer split plus the secondary expert caches. Decode is mostly limited by the experts, so tensor parallelism of the dense part would gain less here than on a dense model. We'll keep this open as a feature request.

<!-- gh-comment-id:5898199074 --> @Niko1221 commented on GitHub (Sep 29, 2026): Thanks for the suggestion. For now multi-GPU means the layer split plus the secondary expert caches. Decode is mostly limited by the experts, so tensor parallelism of the dense part would gain less here than on a dense model. We'll keep this open as a feature request.
Author
Owner

@Niko1221 commented on GitHub (Sep 30, 2026):

Closing as not planned for now: decode is limited by the experts, so tensor parallelism of the dense part gains little here. Multi-GPU work continues in the layer split (#216). It stays on our backlog.

<!-- gh-comment-id:5910289329 --> @Niko1221 commented on GitHub (Sep 30, 2026): Closing as not planned for now: decode is limited by the experts, so tensor parallelism of the dense part gains little here. Multi-GPU work continues in the layer split (#216). It stays on our backlog.
Author
Owner

@MaKla89 commented on GitHub (Oct 17, 2026):

Just for completenes' sake: Would tensor parallel decode allow for asymmetrical GPU-setups (1 x Fast GPU, 1 x rather slow) to provide a benefit over just using only the fast one?

<!-- gh-comment-id:6237197781 --> @MaKla89 commented on GitHub (Oct 17, 2026): Just for completenes' sake: Would tensor parallel decode allow for asymmetrical GPU-setups (1 x Fast GPU, 1 x rather slow) to provide a benefit over just using only the fast one?
Author
Owner

@megakilo commented on GitHub (Oct 17, 2026):

Just for completenes' sake: Would tensor parallel decode allow for asymmetrical GPU-setups (1 x Fast GPU, 1 x rather slow) to provide a benefit over just using only the fast one?

It will run but at the slower card rate. So TP is best for homogenous cards.

<!-- gh-comment-id:6238692391 --> @megakilo commented on GitHub (Oct 17, 2026): > Just for completenes' sake: Would tensor parallel decode allow for asymmetrical GPU-setups (1 x Fast GPU, 1 x rather slow) to provide a benefit over just using only the fast one? It will run but at the slower card rate. So TP is best for homogenous cards.
Author
Owner

@MaKla89 commented on GitHub (Oct 17, 2026):

5. > Just for completenes' sake: Would tensor parallel decode allow for asymmetrical GPU-setups (1 x Fast GPU, 1 x rather slow) to provide a benefit over just using only the fast one?

    It will run but at the slower card rate. So TP is best for homogenous cards.

Hmmm... I thought that was exactly what happens when you choose layer split. At least with dense models, my asymmetrical GPUs worked "meh" in layer split but fairly well in tensor split. I'm not very knowledgeable about these things, though. Thanks!

<!-- gh-comment-id:6240005297 --> @MaKla89 commented on GitHub (Oct 17, 2026): > 5\. > Just for completenes' sake: Would tensor parallel decode allow for asymmetrical GPU-setups (1 x Fast GPU, 1 x rather slow) to provide a benefit over just using only the fast one? > > > It will run but at the slower card rate. So TP is best for homogenous cards. Hmmm... I thought that was exactly what happens when you choose layer split. At least with dense models, my asymmetrical GPUs worked "meh" in layer split but fairly well in tensor split. I'm not very knowledgeable about these things, though. Thanks!
Author
Owner

@megakilo commented on GitHub (Oct 17, 2026):

5. > Just for completenes' sake: Would tensor parallel decode allow for asymmetrical GPU-setups (1 x Fast GPU, 1 x rather slow) to provide a benefit over just using only the fast one?

    It will run but at the slower card rate. So TP is best for homogenous cards.

Hmmm... I thought that was exactly what happens when you choose layer split. At least with dense models, my asymmetrical GPUs worked "meh" in layer split but fairly well in tensor split. I'm not very knowledgeable about these things, though. Thanks!

Layer split takes turns to run on cards like a relay race so when it's your faster card’s turn (to handle the assigned layers), it runs fast. TP is running multiple cards in sync. So the slowest one limits the total speed. It's like two horses run together.

<!-- gh-comment-id:6240634937 --> @megakilo commented on GitHub (Oct 17, 2026): > > 5\. > Just for completenes' sake: Would tensor parallel decode allow for asymmetrical GPU-setups (1 x Fast GPU, 1 x rather slow) to provide a benefit over just using only the fast one? > > > > > > It will run but at the slower card rate. So TP is best for homogenous cards. > > Hmmm... I thought that was exactly what happens when you choose layer split. At least with dense models, my asymmetrical GPUs worked "meh" in layer split but fairly well in tensor split. I'm not very knowledgeable about these things, though. Thanks! Layer split takes turns to run on cards like a relay race so when it's your faster card’s turn (to handle the assigned layers), it runs fast. TP is running multiple cards in sync. So the slowest one limits the total speed. It's like two horses run together.
Author
Owner

@chriskerley78910 commented on GitHub (Oct 26, 2026):

@Niko1221 I don't entirely understand. How are the experts a limiting factor?

<!-- gh-comment-id:6407603607 --> @chriskerley78910 commented on GitHub (Oct 26, 2026): @Niko1221 I don't entirely understand. How are the experts a limiting factor?
Author
Owner

@jackieveev commented on GitHub (Oct 27, 2026):

Same. Its a pity that strata not support tensor split, waiting for it!

<!-- gh-comment-id:6431756670 --> @jackieveev commented on GitHub (Oct 27, 2026): Same. Its a pity that strata not support tensor split, waiting for it!
Author
Owner

@xXRex45Xx commented on GitHub (Oct 27, 2026):

9. @Niko1221 I don't entirely understand. How are the experts a limiting factor?

In my understanding, qwen3.8 flash next only has 6B parameters active. And most of the time (especially when you have VRAM hit rate > 75% on one of your cards), most computation will be done on a single gpu. The other gpus will not have to run much computing. It might seem that using tp so all gpu will have to work at the same time will increase prefill and decode speed. But that's not the case. TP uses allreduce to sync the gpus after once per layer on every token (qwen3.8 flash next, may differ per models) and allreduce is a heavy computation. So on every token, you are essentially adding more computation. With dense models, this would make sense since the computing allreduce will take much shorter time instead of each gpu waiting for the other on every token. But if you're using an moe model with very small active parameters and most of the active experts are sitting on one gpu, the gpus will be faster taking turns and using allreduce will only bring additional computation which will essentially slow it down. Also, gpu to gpu communication is bounded by pcie (32-64GB/s maybe even less if you are using old pcie gen) unless you have nvlink (160GB/s - 3TB/s and is not cheap). TP will make multiple communications (48 times in the case of qwen3.8 flash next) between gpus per token and all reduce will be computed for each communication while layer split will only do one communication per gpu on every token. So tp will make it slower not faster. I might be wrong on some details but I think that's the gist of it.

<!-- gh-comment-id:6433690367 --> @xXRex45Xx commented on GitHub (Oct 27, 2026): > 9\. [@Niko1221](https://github.com/Niko1221) I don't entirely understand. How are the experts a limiting factor? In my understanding, qwen3.8 flash next only has 6B parameters active. And most of the time (especially when you have VRAM hit rate > 75% on one of your cards), most computation will be done on a single gpu. The other gpus will not have to run much computing. It might seem that using tp so all gpu will have to work at the same time will increase prefill and decode speed. But that's not the case. TP uses allreduce to sync the gpus after once per layer on every token (qwen3.8 flash next, may differ per models) and allreduce is a heavy computation. So on every token, you are essentially adding more computation. With dense models, this would make sense since the computing allreduce will take much shorter time instead of each gpu waiting for the other on every token. But if you're using an moe model with very small active parameters and most of the active experts are sitting on one gpu, the gpus will be faster taking turns and using allreduce will only bring additional computation which will essentially slow it down. Also, gpu to gpu communication is bounded by pcie (32-64GB/s maybe even less if you are using old pcie gen) unless you have nvlink (160GB/s - 3TB/s and is not cheap). TP will make multiple communications (48 times in the case of qwen3.8 flash next) between gpus per token and all reduce will be computed for each communication while layer split will only do one communication per gpu on every token. So tp will make it slower not faster. I might be wrong on some details but I think that's the gist of it.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Niko1221/Strata#84
No description provided.