Skip to content

llama-modchip v3.2.1 — 16×8 VNNI Panel GEMM & Inkling-2-Mini AVX-512 Fusion (+144.6% Prefill / +27.8%–33.4% Decode)

Choose a tag to compare

@synchopate synchopate released this 27 Nov 18:22
· 3 commits to main since this release

Release v3.2.1 — 16×8 VNNI Panel GEMM & Bounded-Error Inkling-2-Mini AVX-512 Fusion (+144.6% Prefill / +27.8%–+33.4% Decode), Non-Temporal mul_mat Streaming, & 11.3× Batched HARP-Cache Acceleration

Release Date: November 2026

Highlights

  1. 16×8 A-Packed Broadcast-B VNNI Panel GEMM (MODCHIP_GEMM_TILE=1) & Bounded-Error (<1 ULP) Inkling-2-Mini AVX-512 Graph Fusion (src/llama-inkling2-fused.h, src/models/inkling2.cpp, ggml/src/ggml-cpu/arch/x86/quants.c, MODCHIP_INK2_FUSE=1, default ON):
    • 16-Row On-the-Fly A-Packed + {1to16} Broadcast-B ILP-8 VNNI Panel GEMM (ggml_gemm_panel_{iq4_nl,mxfp4,q8_0}_q8_0, MODCHIP_GEMM_TILE=1 default ON): L1d-resident blocking (KB=12, JB=64, 38 KB stack, zero register spills, zero AVX-512DQ instructions, unlimited K % 32 == 0), verified to <= 5.4e-7 max relative error against exact FP64 across 4.1M independent stress checks, plus AVX-512 VNNI 1x{8,4,3,2} IQ4_NL dot kernels.
    • 12-Bit Inkling-2 / Inkling-2-Mini Graph Fusion (MODCHIP_INK2_FUSE_MASK=0xEFF default ON; standalone norm_rms bit 8 opt-in via 0xFFF): Collapses ~4,300+ per-token cross-CCD threadpool barriers and intermediate DRAM passes across fused SiTU (0x001), L2 row clip + scale + log-tau (0x002), depth-attention mix() (0x004), shortconv + 4-lag dynamic taps (0x008), loop control (0x010 / AVX-512F 0x200), relative-bias gather (0x020), gated attention (0x040), final logit softcap + unpad (0x080), fused N=1 multi-output Q8_0 attention + lm_head GEMV (0x400), and fused N=1 IQ4_NL/MXFP4 MoE pipeline (0x800, GGML_TYPE_I32 route_pack).
    • Cross-Platform & Repack Safety: Runtime AVX-512F/BW/DQ/VNNI/F16C/FMA dispatch (__builtin_cpu_supports + <cpuid.h> F16C check for GCC 10+ compatibility) with clean scalar fallback and compile-time -DMODCHIP_INK2_DISABLE_AVX512 isolation (0 %zmm in -avx2). Strict modchip_ink2::tensor_is_plain_cpu() (extra == nullptr && ggml_backend_buft_is_host()) gates all raw-block fused ops so CPU_REPACK (LLAMA_REPACK_MOE=1), AMX, Metal, CUDA, and Vulkan offloaded tensors fall back cleanly with zero sync stalls. Optional L3/CCD-interleaved physical-core pinning (MODCHIP_PIN_CORES=1, pthread_once, glibc Linux __gnu_linux__ only; silent no-op on musl/Android/macOS/Windows; on musl Alpine builds set OMP_STACKSIZE >= 256K).
    • Verified Zen 5 CPU Speedup & WikiText-2 Parity (published portable v3.2.1 binary llama-bench-modchip-linux-x86_64-avx512, Inkling-2-Mini-Monza-RS-v3-Ultimate.gguf 14.34 GiB, Ryzen 9 9955HX, -p 512 -n 128 -r 3 -t 16 -ngl 0 -fa 1): 227.43 tok/s prefill (+144.6%, 2.45×) and 13.29 tok/s decode (+27.8%) with default MODCHIP_INK2_FUSE=1 LLAMA_NT_STREAM_MM=1 MODCHIP_GEMM_TILE=1 vs. same-binary unfused FUSE=0 NTA=0 TILE=0 (92.98 / 10.40 tok/s; +146.7% / +24.8% vs. FUSE=0 NTA=1 TILE=0 92.19 / 10.65 tok/s), reaching 13.87 tok/s (+33.4%, 94.4% of DDR5 bandwidth ceiling) at -t 8 -lm none with MODCHIP_PIN_CORES=1 (13.80 tok/s mmap; 10.57 tok/s at d=8192 -t 16). Measured WikiText-2 parity: PP512 (5,120 tok) Mean KLD = 0.00183 (99.96% log-PPL corr, 98.08% top-1); 50-chunk N=1 decode (3,200 tok) ΔPPL = +0.003% (Mean KLD = 0.00266, 97.10% top-1, zero directional bias; bit 10 0x400 and bit 7 0x080 measure 0.00000 KLD / 100.00% top-1).
  2. Non-Temporal Decode Streaming for Large mul_mat Matrices (ggml/src/ggml-cpu/ggml-cpu.c, ggml/src/ggml-cpu/arch/x86/quants.c, LLAMA_NT_STREAM_MM=1):
    • Enables non-temporal (_MM_HINT_NTA) weight streaming on decode (nr1 <= 4) for large weight matrices (>= 4 MiB, e.g., lm_head and large Q8_0 attention projections) gated uniformly across all quantized dot kernels (ggml_cpu_nt_stream_active) so LLAMA_NT_STREAM_MM=0 cleanly disables NTA across all quants and multi-token prefill (nr1 > 4) never suffers cache eviction, and widens nr0 >= 32768 decode chunking to chunk_size = 512.
    • Updated unified patches/llama-modchip-v3.2.patch cleanly onto ggml-org/llama.cpp @ 46eb1742d (b12604, SHA256 = 23b45516877cb0e7acb87e6b9c1586e5d5b7e0b1e4b103ffa558c3fd36fa02c8) — verified 156/156 test-llama-archs PASS (including inkling2 & inkling2_loop) and 1,488/1,488 test-backend-ops (MUL_MAT, MUL_MAT_ID, GET_ROWS, CPY) PASS on both -avx2 and -avx512.
  3. Community Runtime, KV-Cache & Gateway Hardening (PRs #51, #53–#61):
    • 11.3× Faster Python HARP-Cache Hashing & O(1) Radix Eviction (kv_cache/fnv_accel.py, kv_cache/harp_cache.py, PRs #56, #59, #61): Native + batched FNV-1a hashing, O(1) radix tree parent tracking, direct LRU scanning, struct packing, full radix-depth collision eviction, and anonymous fallback close() guard (#51).
    • Vectorized EAKV Quantizer (kv_cache/eakv_quantizer.py, PR #55): Vectorized RoPE rotation, batched Q4_0 quantization, and LUT unpacking.
    • Gateway, Readiness, Speculative & Apple Silicon Polish (PRs #53, #54, #57, #58, #60): Distinct content-block indices for native thinking in SSE gateway (#58), accurate macOS vm_stat available memory (#54), C++17 strict-fail RouteCrack build (#60), and graceful offline error handling in scripts/chat.py & apple-silicon/ tools (#53, #57).
    • Zero GGUF checkpoint changes — all v3.0 / v3.1.1 / v3.2.0 GGUF SHA-256s remain 100% identical.
  4. 12 Rebuilt Static-libgomp Portable GLIBC_2.30 Linux x86_64 Binaries, Tarball & Patch (v3.2.1 SHA256SUMS):
    • Built on ubuntu:20.04 (gcc-10/g++-10, GLIBC <= 2.30, static libgomp.a + libstdc++.a + libgcc.a, 0 %zmm in -avx2, 0 vdpbf16ps in -avx512, 0 dynamic libgomp/libstdc++/libssl dependencies):
      • 23b45516877cb0e7acb87e6b9c1586e5d5b7e0b1e4b103ffa558c3fd36fa02c8 llama-modchip-v3.2.patch
      • 6cc390594f9906b18866eb0d3af534fcb2d3fa486d8b7193aa93597c703886c7 llama-server-modchip-linux-x86_64-avx512
      • d4416540f0e7fa50c42048e2ff072b37d85593c3e4bb54cf534a8024f330905b llama-server-modchip-linux-x86_64-avx2 (and llama-server-modchip-linux-x86_64)
      • 011ff32668f891fd14334cfdd47bf574592c062a4f6ec6ce05ac49d9af255cea llama-cli-modchip-linux-x86_64-avx512
      • 85838adb22a95c4f8e645a37b8567889e4cb9c4744c2ebbb2cfd686c66e6f249 llama-cli-modchip-linux-x86_64-avx2 (and llama-cli-modchip-linux-x86_64)
      • 4b923d9a4d7ad804154a890d101255985096abd1c360b7fe430239c068a09588 llama-bench-modchip-linux-x86_64-avx512
      • e0cc573b2cd9cf333d1105edf21b926994cd18d3a60f7985cde0a45df8c5df7f llama-bench-modchip-linux-x86_64-avx2
      • e9b676c7d8012b3831dfef43cf883e94a2788d5ffdd8606f87c09b12fb677f41 llama-perplexity-modchip-linux-x86_64-avx512
      • 397f95e83ced02d864804e4993c666a45ccc640b35c5b99c44ed4dd758ee85aa llama-perplexity-modchip-linux-x86_64-avx2
      • 69fc09f1948c0057c9cc86ff3fd74e80cf9876fe8b19d6f97113e7957ce65573 llama-quantize-modchip-linux-x86_64-avx512
      • 46836e4fd1cb54ab581f6429be77735695dc63dfe15a16d65f4f276a19f767ec llama-quantize-modchip-linux-x86_64-avx2
      • 9403629e54b9134cb3f9784ba77a47b8bb5da81565e8e236e8836e2892477022 llama-modchip-v3.2.1-linux-x86_64.tar.gz

Featured Model: Inkling-2-Mini Monza-RS v3

Inkling-2-Mini Monza-RS v3 — 52 GB to 15 GB Standard GGUF and 2.4x CPU Prefill

Built cleanly from Thinking Machines Lab's thinkingmachines/Inkling-2-Mini (Apache 2.0): Inkling-2-Mini-Monza-RS-v3-Ultimate.gguf (15,398,405,888 B = 14.341 GiB / 15.40 GB, 100% standard upstream llama.cpp b12604+ GGUF, SHA-256 = 5f1df36927b56d761ede5359c1212d8443cee8330269062c0a0a3c96ed616038) is the checkpoint used for the Zen 5 +144.6% prefill / +27.8% decode (+33.4% at -t 8 pinned) figures above.

1-Command Install (SHA-256 verified): ./modchip setup --preset monza && ./modchip chat

Full model card, 102k-token KLD decomposition, paired McNemar / Holm-Bonferroni / uncapped parity scorecard, SHA256SUMS, and ./reproduce_monza_v3_ultimate.sh live on Hugging Face: Synchopate/Inkling-2-Mini-Monza-RS-v3-GGUF