Append to the raw SWA cache. Once full, it slides by one row. */
| 8539 | |
| 8540 | static bool weights_model_map_decode_static_supported(const ds4_weights *w) { |
| 8541 | if (!w) return false; |
| 8542 | if (DS4_MODEL_FAMILY == DS4_MODEL_FAMILY_GLM_DSA) { |
| 8543 | return g_glm_streaming_runtime_static_map_enabled; |
| 8544 | } |
| 8545 | for (uint32_t il = 0; il < DS4_N_LAYER; il++) { |
| 8546 | const ds4_layer_weights *l = &w->layer[il]; |
| 8547 | if (!l->ffn_gate_exps || !l->ffn_up_exps || !l->ffn_down_exps) continue; |
| 8548 | if (!weights_streaming_layer_experts_uniform(w, il)) { |
| 8549 | return false; |
| 8550 | } |
| 8551 | } |
| 8552 | return true; |
| 8553 | } |
| 8554 | |
| 8555 | static void model_map_span_vec_include_output(ds4_model_map_span_vec *spans, const ds4_weights *w) { |
| 8556 | model_map_span_vec_include_one(spans, w->output_hc_base); |
| 8557 | model_map_span_vec_include_one(spans, w->output_hc_fn); |
no test coverage detected