Commit 3faad72
fix(wp): keep tiny per-layer weights resident (don't page < 4KB)
DeepSeek V4 introduces tiny per-layer weights used in non-matmul ops
(hyper-connection scale/base {3}/{hc_mix_dim}, attn sinks, expert-prob
bias). The pager paged everything per-layer except a few named tensors, so
these got a null buffer; a paged non-matmul leaf never gets a backend
assigned and ggml_gallocr asserts (buffer_id >= 0) during sched_reserve,
crashing any DeepSeek-V4 paged load. Add a 4KB floor to both the
is_paged_weight predicate and the weight_page_infos registration so tiny
weights stay resident. Standard {n_embd} norms are well above 4KB and
remain paged (27B/LFM behavior unchanged).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014ZRfPpL8XFzk1hep9MMg9P1 parent 978a720 commit 3faad72
1 file changed
Lines changed: 15 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
44 | 52 | | |
45 | 53 | | |
46 | 54 | | |
| |||
1603 | 1611 | | |
1604 | 1612 | | |
1605 | 1613 | | |
| 1614 | + | |
1606 | 1615 | | |
1607 | 1616 | | |
1608 | 1617 | | |
| |||
1743 | 1752 | | |
1744 | 1753 | | |
1745 | 1754 | | |
| 1755 | + | |
| 1756 | + | |
| 1757 | + | |
| 1758 | + | |
| 1759 | + | |
| 1760 | + | |
1746 | 1761 | | |
1747 | 1762 | | |
1748 | 1763 | | |
| |||
0 commit comments