Repository navigation
Highlights
- Single-pass GPU-batched continuous batching (
B = 1..4) across all 4 engine families: Concurrent HTTP streams on Qwen4 (qwen4_moe), Qwen3.6 / Hybrid MoE (qwen3_5_moe,qwen3_next), Standard MoE (qwen3moe,qwen2moe,mixtral,olmoe), and Dense GQA (qwen3,llama,mistral,qwen2) now decode together in a single GPU weight-read pass per step with independent lazily allocated KV, DeltaNet, QSA, and PLE caches and zero state-snapshot/restore copying. Solo requests keep the zero-overhead fast path (MTP / N-gram speculative decode and GPU greedy burst). - 1-dispatch persistent dense multi-slot megakernel (
dense_persistent_multi_slot): Fuses Embedding, all transformer layers, Final RMSNorm, Batched LM Head, and Per-Slot Argmax into one Metal 4 persistent dispatch with 16 KB threadgroup-SRAM activation caching (1.52xwall /1.63xdecode scaling onLlama-3.2-1B-Instruct-Q8_0,1.30xonQwen3-0.6B-Q4_K_M, bit-exact parity vsB = 1). - Native 8-bit (
Q8_0) Metal 4 kernels for Standard MoE:Q8_0,F16,BF16, andF32Standard MoE GGUF checkpoints stay at full 8-bit precision (68 B / 64 weights, zero 4-bit down-quantization) across persistent decode, MMA prefill, and multi-slot batching.
Verified Results (Apple M3 Ultra, Metal 4)
| Engine Family | Verified Model | Concurrent B = 4 Scaling |
Verification |
|---|---|---|---|
| Qwen4 Hybrid MoE | mlx-community/Qwen4-35B-A3B-4bit-text |
1.69x-1.71x wall (82.1-84.2 agg tok/s) |
4 independent PLE + DeltaNet + QSA streams + /v1/messages |
| Qwen3.6 Hybrid MoE | mlx-community/Qwen3.6-35B-A3B-4bit |
1.49x-1.67x wall (1.90x-1.95x pure decode) | Exact B = 2 GPU unit parity + 4-stream HTTP |
| Standard MoE (Native Q8) | Q8_0 qwen3moe GGUF (quant_bits=8) |
Single-pass B = 1..4 (68 B / 64 weights) |
Exact B = 2 argmax parity vs sequential B = 1 |
| Dense GQA (1-Dispatch Persistent) | Llama-3.2-1B-Q8_0 / Qwen3-0.6B-Q4_K_M / Qwen3-4B-4bit |
1.52x (246.8) / 1.30x (242.4) / 1.14x (94.5 agg tok/s) |
Bit-exact slot0 parity vs B = 1 |
All 20 Rust and Metal 4 GPU unit tests pass (cargo test --release -- --test-threads=1, zero compiler warnings).
Install / Upgrade
# Homebrew
brew upgrade srbryers/tap/sinter
# Or direct Apple Silicon installer
curl -fsSL https://raw.githubusercontent.com/srbryers/sinter/main/scripts/install.sh | sh