Running Trillion-Parameter Models Without GPUs: Persistent Memory Inference in Practice
When model parameters reach the trillion scale, inference systems face a combined "capacity wall" and "bandwidth wall": accelerator memory is limited and expensive, while even quantized trillion-parameter models can weigh hundreds of gigabytes to terabytes. This article examines a GPU-free architecture built on large-capacity persistent memory, dynamic memory caching, and CPU inference, explaining why it can run trillion-parameter models at all, why throughput remains low, and which optimizations are realistically achievable.
When model parameters reach the trillion scale, the first obstacle for an inference system is often not raw compute shortage, but the overlap of a “capacity wall” and a “bandwidth wall”: accelerator memory has limited capacity and high per-unit cost, while even after low-bit quantization, the weights of an extremely large model can still reach hundreds of gigabytes or terabytes. This has driven interest in a general-purpose approach centered on “large-capacity persistent memory + dynamic memory caching + CPU inference.” This article is not a review or endorsement of any specific product; instead, it examines this route from an architectural, performance, and engineering perspective—why it can run at all, why it runs slowly, and how to optimize it within limits.
1. Background: The Capacity-Bandwidth Conflict in Trillion-Parameter Models
Take a 2.8-trillion-parameter model as an example. At just 1 bit per parameter, the theoretical floor for weights is roughly 350GB; at 3-bit quantization, it is about 1.05TB. A real system must also store quantization metadata, alignment padding, runtime buffers, context caches, and intermediate activations, so actual usage is higher. Conventional accelerator memory cannot provide such capacity at low cost, while ordinary SSDs, though plentiful, suffer from block-device access granularity, latency, and poor random-read efficiency—making them unsuitable as the primary medium for layer-by-layer weight streaming.
Persistent memory sits between dynamic memory and solid-state storage: it is non-volatile, offers large capacity, and supports memory-semantic access, but its bandwidth and latency are generally inferior to dynamic memory. Keeping model weights resident in persistent memory while placing hot weights, activations, and context caches in dynamic memory forms a tiered inference architecture. It solves the “it fits” problem, but not automatically the “it runs fast” problem. The core tension: autoregressive generation typically reads a large amount of weights for every token produced. If each token requires scanning about 350GB of weights, then 1 token/second implies roughly 350GB/s of effective read bandwidth—far beyond what ordinary persistent memory can sustain. Low throughput, therefore, is not a tuning mistake but a structural outcome determined by medium bandwidth and the model’s read volume.
2. Anatomy of the Architecture: Tiered Storage and the CPU Inference Path
A typical general-purpose design can be abstracted into four tiers:
- Weight repository tier: Large-capacity persistent memory stores the complete quantized weights. Non-volatility reduces loading costs and lets model capacity exceed dynamic memory limits.
- Hot cache tier: Dynamic memory caches frequently accessed weight blocks, token embeddings, selected layer weights, activations, and the context cache. Cache hit rate directly determines actual throughput.
- Compute tier: Server-grade multi-core CPUs perform matrix-vector multiplications, attention computation, and dequantization. Going GPU-free does not mean there is no compute bottleneck—core count, memory channels, NUMA affinity, and vector instruction support all affect performance.
- Scheduling and runtime tier: Responsible for layer-by-layer weight loading, prefetching the next layer, managing direct-access or page-cache access paths, and controlling concurrency and context length.
In one reported experiment, on a server-grade processor with around 40 cores combined with large-capacity persistent and dynamic memory, 1-bit quantization with persistent memory exposed as a separate data space yielded an initial generation speed of about 0.85 tokens per second. After adjusting the access path so that frequently used data benefited more from dynamic memory caching, speed improved to about 1.50 tokens per second. Another test with 3-bit quantization achieved roughly 0.75 tokens per second, taking about 18.5 hours to generate 50,000 tokens. These figures should be read as observations under specific experimental conditions, not as a general performance guarantee for this route. They demonstrate two things: capacity is feasible, but throughput remains at offline or validation-grade levels.
A pseudo-configuration sketch (illustrative only, not any real interface):
Inference tier configuration sketch (pseudocode):Weight storage tier: large-capacity persistent memoryHot cache tier: dynamic memoryAccess path: direct-access path or system page-cache path (choose one)Quantization width: 1-bit or 3-bitMax context tokens: 50000Prefetch strategy: layer-by-layer double bufferingThread strategy: bind per NUMA node and balance memory channels
3. Why Throughput Is Low: Five Key Bottlenecks
First, the medium’s bandwidth ceiling. In a GPU-free setup, weight reads rely on system memory and persistent memory channels. Each generated token requires scanning a large volume of weights, and insufficient bandwidth directly translates into fewer tokens per second. Quantization reduces read volume but does not eliminate the fundamental layer-by-layer scan pattern.
Second, access latency and page faults. Persistent memory latency is higher than dynamic memory. If access is random and prefetching is insufficient, the CPU stalls frequently. A direct-access path reduces data copies and page-cache overhead, but in inference workloads with clear hotspots, bypassing the general cache can lower hit rates; conversely, enabling the page cache keeps hot data in dynamic memory but adds page-management overhead. The two paths should be chosen based on workload measurements.
Third, dequantization overhead. Low-bit quantization eases storage and bandwidth pressure but increases dequantization and format-conversion costs. A 1-bit scheme minimizes capacity but may require a more complex compute path; a 3-bit scheme offers better accuracy but roughly triples weight volume and read pressure. Quantization width is not “lower is better”—it requires balancing capacity, accuracy, and compute overhead.
Fourth, context cache growth. In long-context inference, the context cache grows with token count. At the 50,000-token scale, cache footprint and access frequency are both significant. If the cache is frequently evicted to persistent memory, throughput drops further. Paging, compression, per-layer reuse, or limiting concurrent context lengths are needed.
Fifth, NUMA and thread scheduling. On multi-socket servers, latency varies depending on which memory node a core accesses. If threads are not on the same NUMA node as the persistent or dynamic memory they touch, cross-node access amplifies latency. More threads are not always better either—excessive concurrency contending for memory bandwidth degrades both per-request and aggregate throughput.
4. Optimization Path: From “It Runs” to “Usable Offline Inference”
1. Tiered placement and hotspot identification. Don’t treat all data equally. Token embeddings, the output layer, frequently accessed attention weights, and recently used context caches can live in dynamic memory, while cold layer weights stay in persistent memory. Sample per-layer access frequency to adjust cache quotas dynamically. Hotspot identification should be based on real request distributions, not just guesses from model structure.
2. Choose the access path per workload. Direct-access paths suit sequential scans where copy overhead is a concern; the page-cache path suits workloads with concentrated hotspots and repeated access. In practice, run A/B tests and observe cache hit rate, page faults, effective bandwidth, and token latency rather than fixing one mode.
3. Layer-wise prefetching and double buffering. Inference proceeds layer by layer, so the next layer’s weights can be prefetched into dynamic memory while the current layer computes, with double buffering hiding part of the load latency. Prefetch granularity should match memory channels and cache capacity: too large and it crowds out the context cache; too small and it fails to form an effective pipeline.
4. Co-design quantization format and compute kernels. Quantization width, group size, outlier handling, and dequantization kernel implementation all affect performance. Prioritize contiguous memory access and reduce random cross-channel jumps; use higher precision for hot layers and lower precision for cold ones. Accuracy evaluation must cover actual business tasks, not just perplexity.
5. Context cache management. For long contexts, use paged caching, per-attention-head compression, recent-window retention, and eviction of stale blocks. With many concurrent requests, cap per-request context length or queue requests to prevent cache thrashing from collapsing overall throughput.
6. Parallelism and affinity tuning. Bind worker threads to NUMA nodes so they access local dynamic memory and local persistent memory channels; balance memory channel usage to avoid a single channel becoming the bottleneck. Under multi-request concurrency, assign different requests to different nodes to reduce cross-node bandwidth contention.
7. Establish monitoring metrics. At minimum, track average bytes read per token, dynamic memory hit rate, persistent memory effective bandwidth, page fault rate, dequantization time, context cache usage, thread wait time, and the ratio of cross-NUMA accesses. Without these, optimization degenerates into blind parameter tweaking.
5. Deployment Guidance and Limits of Applicability
For capacity planning, estimate the theoretical weight floor as “parameter count × quantization width ÷ 8,” then add metadata, alignment, context cache, and runtime headroom—usually with a significant margin. Validate the tiered caching and prefetching logic on a small model first, then scale up; run single-request benchmarks before multi-concurrency stress tests; ensure output correctness and stability before chasing token speed.
If you host experiments or supporting production systems in the cloud, generic offerings such as container platforms, object storage, and monitoring/alerting can manage images, model files, and runtime metrics—but the core inference architecture still hinges on persistent memory capacity, dynamic memory caching, and CPU memory bandwidth. This route best suits offline batch generation, research validation, low-concurrency long-context tasks, and cost-sensitive, latency-tolerant scenarios; it is not suitable for online, low-latency, high-concurrency, interactive inference services. The conclusion: GPU-free inference with persistent memory can break through capacity limits and get extremely large models running, but bandwidth and latency constraints mean it remains a verifiable, offline-capable engineering approach rather than a replacement for general-purpose high-performance inference.
