Nandai AI
Sign In

High-Precision Qwen 4 35B-A3B: Q8_0 & Unquantized BF16 Split on 64–192 GB Macs & Dual 3090s

Zero-degradation reference math, multi-GPU row-parallel splitting vs. Ultra unified memory, and hybrid BF16 expert routing architectures.

Need exact FP16/BF16 reference fidelity? Size Q8_0 (37.40 GiB) on 64 GB+ Macs or Dual RTX 3090s, and full BF16 (103.40 GiB) on 192 GB Mac Studio Ultra.

~933 wordsTechArticle + HowTo + Speakable JSON-LDZero-Upload Client RAM
Execution Pipeline ArchitectureLocal Browser RAM & Apple Silicon
01Lock Q8_0 / BF16Select 37.40 GiB Q8_0 or65.20 GiB BF16 MoE02Map Engram PoolRoute 38.20 GiB BF16 Engramto Host DDR5 / UMA03Balance Multi-GPUApply -sm row across Dual3090 or UMA single pool04Preserve FP16 KVKeep QSA attentionunquantized for reference ev…
  1. Step 01 · Lock Q8_0 / BF16

    Select 37.40 GiB Q8_0 or 65.20 GiB BF16 MoE. Q8_0 (8.50 bpw, 34 bytes per 32-element block) delivers virtually indistinguishable perplexity and logprob accuracy relative to BF16 while cutting MoE backbone weight from 65.20 GiB down to 37.40 GiB.

  2. Step 02 · Map Engram Pool

    Route 38.20 GiB BF16 Engram to Host DDR5 / UMA. On 64 GB and 128 GB M4 Max workstations (546 GB/s), Q8_0 streams at a 118.7 tok/s theoretical roofline while leaving 16–80 GiB open for long FP16 QSA KV windows.

  3. Step 03 · Balance Multi-GPU

    Apply -sm row across Dual 3090 or UMA single pool. Dual RTX 3090 (2x 24 GB = 48 GB GDDR6X) comfortably fits Q8_0 (37.40 GiB) plus 128K Q8_0 KV (2.91 GiB) with Host-RAM Engram offload, avoiding expensive data-center cards.

  4. Step 04 · Preserve FP16 KV

    Keep QSA attention unquantized for reference evals. True unquantized BF16 totals 103.40 GiB (65.20 GiB MoE + 38.20 GiB Engram) and reads 7.80 GB per token—exceeding 64 GB systems unless Engram lives in Host RAM on a 96–128 GB rig.

1. Q8_0 Block Arithmetic: Why 8.50 bpw Matches BF16 Evaluation Integrity

Engineering teams auditing safety classifiers, financial parsing extractions, or compiler theorem proving frequently forbid 4-bit weight compression out of concern for subtle logprob shifts on edge-case tokens. Q8_0 solves that requirement without paying full 16-bit memory footprints. Each 32-element tensor block stores 32 signed 8-bit integers paired with one 16-bit floating-point scale factor (34 bytes per 32 weights = 8.50 bits per weight).

Because 255 discrete quantization buckets capture smooth Gaussian weight distributions with minimal clipping error, Q8_0 preserves essentially identical KL-divergence and downstream benchmark scores as native BF16 while shrinking the 35B MoE backbone from 65.20 GiB down to 37.40 GiB. Per-token active reads settle at 4.60 GB/tok—allowing 546 GB/s M4 Max systems to hit 118.7 tok/s theoretical decode ceilings and 819 GB/s Mac Studio Ultra rigs to reach 178.0 tok/s.

Just as importantly, keeping Q8_0 under 40 GiB unlocks multi-GPU 48 GB setups built from two commodity 24 GB cards rather than requiring $8,000+ 80 GB workstation accelerators.

Bytes_Q8_0(W) = (W / 32) * (2 bytes FP16_scale + 32 bytes int8) = 1.0625 * W bytes
For 35B MoE: 35 * 10^9 * 1.0625 ≈ 37.19 billion bytes (37.40 GiB w/ metadata & alignment)

2. Dual RTX 3090 (48 GB GDDR6X): Layer Split (-sm layer) vs. Row Split (-sm row)

A pair of RTX 3090 GPUs delivers 48 GB total GDDR6X VRAM and 936 GB/s per device—still one of the most cost-effective on-premises inference servers for Qwen 4 35B-A3B Q8_0. Combined with 64 GB of host DDR5 holding the Engram table (-ot "engram=CPU"), the 37.40 GiB Q8_0 MoE backbone divides cleanly at ~18.70 GiB per card, leaving roughly 9 GB combined headroom for 128K Q8_0 KV cache (2.91 GiB) and CUDA scratch.

Choosing between pipeline layer splitting (-sm layer) and tensor-parallel row splitting (-sm row) determines multi-card efficiency. Under layer splitting, GPU 0 processes layers 0–19 sequentially while GPU 1 sits idle, then ships intermediate hidden activations over PCIe to GPU 1 for layers 20–39; total effective bandwidth equals a single card (936 GB/s, yielding ~203.5 tok/s theoretical Q8_0 roofline) with negligible synchronization latency.

Under tensor-parallel row splitting (-sm row), both cards compute halves of every matrix concurrently, raising aggregate bandwidth toward 1,872 GB/s—though requiring two PCIe or NVLink all-reduce synchronizations per layer. Systems equipped with a 3-slot NVLink bridge gain measurably from -sm row, whereas standard PCIe Gen4 x8/x8 motherboards often benchmark cleaner and more predictably under -sm layer.

Dual RTX 3090 48 GB Execution Modes on Qwen 4 35B-A3B Q8_0
Split TopologyInter-GPU Traffic PatternRecommended Hardware Topology
Layer Pipeline (-sm layer)1 hidden state transfer per token at boundaryBest on PCIe Gen4 x8/x4 boards; zero all-reduce stalls
Row Tensor Parallel (-sm row)2 all-reduce syncs per transformer blockBest with NVLink bridge or Gen5 x16/x16 PCIe root
128K Q8_0 KV + Host Engram37.40 + 2.91 + 0.75 = 41.06 GiB VRAMFits 48 GB cleanly (~20.5 GiB per 3090)

3. Full Unquantized BF16 Residency on 192 GB Mac Studio Ultra

Deploying Qwen 4 35B-A3B completely unquantized in native BF16 eliminates every possible rounding artifact across weights, activations, and attention caches. The 35B MoE backbone occupies 65.20 GiB and the 20.5B PLE Engram table occupies 38.20 GiB, totaling 103.40 GiB on disk and in RAM with 7.80 GB active read per generated token.

A 192 GB Mac Studio Ultra (M2 Ultra or M3 Ultra at 819 GB/s unified memory bandwidth) absorbs that full 103.40 GiB footprint with 88.6 GiB to spare—enough to mount an unquantized 1,048,576-token FP16 QSA KV cache (40.25 GiB) and still maintain 48 GiB free for macOS, Xcode, and test harnesses. At 7.80 GB per token over 819 GB/s, theoretical batch-1 decode sits at an interactive 105.0 tok/s without touching a single quantization parameter.

Meanwhile, 128 GB M4 Max MacBook Pro owners can still execute unquantized BF16 up to 256K–512K contexts (~114–124 GiB total if Engram streams via APFS mmap and OS reserves are minimal), though Q8_0 (37.40 GiB + quantized/FP16 KV) generally leaves healthier thermal and app headroom on 128 GB laptops.

4. Hybrid GPU/CPU BF16 Expert Routing for Offline Eval Workstations

What if a team needs bit-exact BF16 verification on a desktop equipped with 128 GB of host DDR5 RAM and a single 24–32 GB RTX GPU? Selective tensor routing (-ot patterns) allows hot attention, GDN, and shared MoE layers (~15–20 GiB in BF16) to stay pinned on the RTX GPU while routing cold sparse MoE experts plus the 38.20 GiB Engram table into dual-channel DDR5 host memory.

Because batch-1 MoE generation activates only ~3B parameters per token rather than all 35B, streaming routed BF16 experts off 90 GB/s DDR5 drops speed compared to full VRAM (~12–20 tok/s rather than 100+ tok/s) yet remains fast enough for overnight evaluation suites, determinism unit tests, and gold-standard logprob calibration against quantized checkpoints.

Actionable Checklist
  • Always compare Q4_K_M / UD-IQ4_XS outputs against Q8_0 or BF16 on fixed temperature=0 seeds.
  • Use -ctk f16 -ctv f16 on Q8_0/BF16 evals so KV quantization never confounds weight evals.
  • On Dual RTX 3090 rigs without NVLink, benchmark -sm layer against -sm row before locking.
  • Use /tools/gguf-vram-calculator to verify 192 GB Ultra vs 128 GB M4 Max headroom.

5. Reproducible Reference Evaluation Protocol in Local Sandboxes

When publishing internal benchmark gates comparing local Q4_K_M against reference BF16 or Q8_0, log exact GGUF SHA-256 checksums, llama.cpp commit hash, FlashAttention toggle state, and KV cache data type alongside KL-divergence or exact-match scores. Combining ML-DSA-65 or SHA-256 signed verification logs guarantees reproducibility across Mac Studio and Linux GPU clusters.

Notice how unified memory Macs simplify cross-quant audits: a single 128 GB M4 Max can hold both Q8_0 (37.40 GiB) and UD-IQ4_XS (20.40 GiB) back-to-back in OS file cache, switching models in seconds via zero-copy mmap() for instant side-by-side output diffs.

# 192 GB Mac Studio Ultra Unquantized BF16 Full-Fidelity Launch:
llama-server -m Qwen4-35B-A3B-BF16.gguf -c 262144 -ctk f16 -ctv f16 -fa on -ngl 99

Reference Precision Workstations: Q8_0 (37.40 GiB) & Unquantized BF16 (65.20 + 38.20 GiB)

Reference Precision Workstations: Q8_0 (37.40 GiB) & Unquantized BF16 (65.20 + 38.20 GiB)
Precision & Split StrategyTotal GPU + Host MemoryCompatible Hardware & Theoretical Roofline
Q8_0 + Host Engram (128K FP16 KV)37.40 GiB GPU + 5.25 GiB KV = 43.40 GiB64 GB M4 Max (118.7 tok/s) · Dual RTX 3090 w/ Q8_0 KV
Q8_0 + Host Engram (1M FP16 KV)37.40 GiB GPU + 40.25 GiB KV = 78.40 GiB128 GB M4 Max (118.7 tok/s) · 192 GB Ultra (178.0 tok/s)
BF16 MoE + Host BF16 Engram (128K)65.20 GiB GPU + 38.20 GiB Host + 5.25 GiB KV96–128 GB M4 Max (70.0 tok/s) or 96 GB Pro GPU
Full Unified BF16 (All Resident, 1M)103.40 GiB + 40.25 GiB FP16 KV = 144.40 GiB192 GB Mac Studio Ultra (105.0 tok/s theoretical)
Hybrid GPU/CPU BF16 Expert SplitHot layers GPU + cold routed experts CPUAllows 64 GB host + 24 GB GPU to run BF16 evals offline

Connected Workflows & Technical References

Launch pre-configured interactive sandboxes or read paired Academy, Guide, and GGUF specifications.

Model Q8_0 / BF16 Residency →
FOUNDER_999_LOCK · 67% OFF ALL-IN-ONE PRO

Run Every Studio Unlimited at $9.99/mo (Web Cloud + 5 Apple Silicon Macs)

Consolidate $130+/mo of separate writing, PDF, citation, cutout, video, and 1-second charting subscriptions into one local-first workspace — backed by a 14-day refund window and 1-click cancel.

Publisher & Creator Partner Network
Embed Zero-Upload Tools & Earn 40% Recurring

Add our 1-line Shadow DOM widget to your blog or share your partner link for 40% monthly / 30% annual recurring revenue.

More in Local Apple Silicon AI, Zero-Upload Privacy & Post-Quantum Web Security (8 Sibling Playbooks)

All 84 Articles →
FAQ · DIRECT ANSWERS

Local Apple Silicon AI, Zero-Upload Privacy & Post-Quantum Web Security — FAQ

05 Questions
Does Q8_0 actually match BF16 accuracy on Qwen 4 35B-A3B?
Q8_0 (8.50 bpw with FP16 block scales) preserves virtually identical perplexity and logprobs to BF16 across code and math tasks while shrinking the 35B MoE backbone from 65.20 GiB down to 37.40 GiB.
Can Dual RTX 3090 (48 GB total) run Qwen 4 Q8_0 completely in VRAM?
Yes. With -ot "engram=CPU" keeping the 20.5B Engram table in DDR5, the 37.40 GiB Q8_0 MoE backbone fits across two 3090s with ~9 GB open for 128K Q8_0 KV and CUDA scratch.
Which Mac holds full unquantized BF16 weights plus 1M FP16 KV?
A 192 GB Mac Studio Ultra holds the 65.20 GiB BF16 MoE backbone, 38.20 GiB BF16 Engram table, and 40.25 GiB 1M FP16 KV cache (143.65 GiB) natively at a 105.0 tok/s theoretical roofline.
Should I use -sm layer or -sm row on Dual RTX 3090 GPUs?
Use -sm row when connected via NVLink or fast PCIe Gen5 slots for higher aggregate bandwidth; use -sm layer on slower PCIe x8/x4 risers to eliminate inter-layer sync stalls.
How much Host DDR5 RAM is needed for BF16 hybrid CPU/GPU runs?
Budget at least 96–128 GB of system DDR5 RAM when splitting the 38.20 GiB BF16 Engram table plus cold MoE experts onto the host CPU.
Founder Pro $9.99/mo · 67% Off1-tap Stripe Checkout · Instant ?ref= Free Months · 40% Recurring Partner Payouts
1. Subscribe in 1 TapFOUNDER_999_LOCK

Unlock All 19 Pro Studios + Mac App

Lock $9.99/mo Founder Pro (reg. $29.99 — 67% off), $119/yr Web Annual (-34%), or $299/yr 5-Mac + Web Pro.

Redeem Code
2. Get 6 Months FreeZERO OTP

Mint Your ?ref= Link Instantly

Give friends 67% off ($9.99/mo). Every paid friend adds 30 days of Pro free to your account (up to 6 months).

Dashboard: /refer · Rules

3. Creator & Publisher Cash90-DAY COOKIE

Earn 40% Monthly · 30% Annual

Earn 40% recurring monthly until cancel + 30% annual & every renewal, or embed our free tools with data-ref.