prefill: with --peer-device the fused experts stay off even when the peer declines the prompt path (#531 follow-up)
fused_ring() turns the fused ring sizing off for any --peer-device session (core::peer_portable), but the layer's fused choice tested the peer's prompt-path state (m.pp), which is null when set_peer declines (no P2P, the buffers do not fit, --peer-prefill-rows 0). Both now follow the flag, so a peer session's prompt path is MMQ with the MMQ ring and buffers it was sized for. Without --peer-device nothing changes.
This commit is contained in:
1 parent
5743d8dc35
commit
60768eb41e
1 file changed
+5
-2
@@ -1969,8 +1969,11 @@ bool Prefill::run(const int64_t* tokens, int64_t n, int64_t pos0, std::string& e
|
||||
const bool use_mmq = mmq_plan().any && mmq_plan().layer[(size_t) l];
|
||||
const int mmq_gt = lay.native ? lay.fmt[(size_t) l].gu_type : 42;
|
||||
const int mmq_dt = lay.native ? lay.fmt[(size_t) l].d_type : 42;
|
||||
const bool fused_nat = use_mmq && stream_all && !m.pp && lay.native && fused::native_supported(mmq_gt, mmq_dt);
|
||||
const bool fused_l = (use_mmq && stream_all && !m.pp && !lay.native && fused::enabled()) || fused_nat;
|
||||
// --peer-device: MMQ only, whether or not the peer took the prompt path (set_peer can decline), as
|
||||
// fused_ring() sized the ring and the buffers for it
|
||||
const bool no_peer = !core::peer_portable();
|
||||
const bool fused_nat = use_mmq && stream_all && no_peer && lay.native && fused::native_supported(mmq_gt, mmq_dt);
|
||||
const bool fused_l = (use_mmq && stream_all && no_peer && !lay.native && fused::enabled()) || fused_nat;
|
||||
size_t n_order = 0; // the routed experts (the debug report; unknown when fused)
|
||||
bool peer_now = false; // multi-GPU: the peer computed rows of this layer (MMQ path only)
|
||||
if (fused_l) {
|
||||
|
||||
Reference in new issue
Block a user