Manuscript Offprint

arXiv:2611.04253

UMLoad: Fast On-Demand Model Loading on Unified Memory Architecture

Zimeng Wang, Jinrong Yang, Rong Chen

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

On-demand model loading dominates response latency for interactive on-device AI, yet unified memory architectures (UMAs)—now common on edge devices—should make it cheap by placing weights in memory the GPU already sees. However, frameworks still use the loading flow built for discrete GPUs, leaving significant inefficiencies. This paper presents UMLoad, a system-level model-loading accelerator that decouples a framework's logical allocations from their physical page backing. UMLoad uses on-demand reconstruction to eliminate the weight copy while preserving copy independence, and GPU-assisted page zeroing to accelerate runtime allocation while preserving its security guarantee. Implemented on Intel, AMD, and NVIDIA UMA platforms and evaluated with llama.cpp, PyTorch, and vLLM across six models, UMLoad reduces average loading time by 36.6%–71.9% over vanilla and 19.9%–62.7% over pipelined loaders, and cuts mean LLM-routing time to first token (TTFT) by 51.3%–59.3% and model-backed tool completion latency by 10.2%–31.6%.

1 Introduction

On-device AI is moving from isolated tasks to applications that combine many models, pairing general-purpose large language models (LLMs) with specialized ones for speech, vision, retrieval-augmented generation (RAG), and sensing. AI use at the edge is therefore on-demand, in both which model runs and when. Model choice is dynamic, based on task requirements [62] and cost-quality trade-offs [50], making it hard to know which models to keep in memory. Invo-cation timing varies with bursty user interactions [10] and reactive agent execution [73], making advance loading difficult. On memory-constrained devices, competing applications can evict model weights and inference state, requiring restoration when the model is invoked again [78]. When the selected model is not resident, loading enters the request's critical path.

Model loading can dominate cold-start response latency on mobile devices [75], and measurements across commercial smartphones show substantial model-preparation delays [74]. We measure response latency from user input to the first user-visible result: end-to-end completion time for non-streaming tasks and time to first token (TTFT) for streamed text responses [3]. Loading costs are especially exposed when inference consists of a short subtask; long-context prefill and lengthy generation can narrow the gap. In the four evaluated on-demand workloads, model loading accounts for 29.0%–

Figure

Figure 1. (a) Model-loading contribution to response latency: end-to-end completion time for non-streaming tasks and TTFT for streaming tasks. Percentages indicate the fraction spent on model loading. Weight-file sizes are 3.7 GB (Chat), 1.7 GB (Vision), 4.5 GB (TTS), and 6.5 GB (ImgGen). (b) Step-by-step illustration of model loading on UMA.

Figure

Figure 2. Breakdown of Qwen3-1.7B model loading, with 3.7 GB of weights and a 6 GB KV-cache reservation, using vanilla PyTorch, PyTorch+Pipeline, and PyTorch+UMLoad. Tests use an Intel Arc Xe-LPG integrated GPU, with a main-memory bandwidth of 89.6 GB/s and an SSD bandwidth of 15.75 GB/s.

80.9% of response latency (Figure 1(a), detailed in §7.4).

An architectural trend offers an opening to attack this cost. Edge devices increasingly adopt a unified memory architecture (UMA), where the CPU and GPU share one physical memory pool, as in Apple M-series, AMD APUs, Intel Core Ultra, and NVIDIA GB10 [2, 5, 22, 49]. UMA suits these workloads: it lets memory-limited devices hold larger models and longer contexts, and in principle removes CPU–GPU transfer from loading, as the GPU already sees weights in memory.

In practice, frameworks retain the three-step loading flow designed for discrete GPUs (Figure 1(b)): file I/O reads weights into the page cache; weight transfer allocates GPU buffers and performs host-to-device (H2D) copies of weights into them; and runtime allocation reserves memory for the key-value (KV) cache and compute buffers. On UMA, this creates two inefficiencies (Figure 2). First, weight transfer is redundant: it preserves buffer independence and loader portability, but duplicates weights already in shared mem-ory, adding copy latency and doubling their peak memory (3.7 GB extra for Qwen3-1.7B). Second, runtime allocation forces synchronous page zeroing: GPU allocations draw from system memory, which the OS must zero to prevent cross-process leaks. Zeroing the 6 GB KV cache takes 0.63 s, as the CPU achieves under a third of the 89.6 GB/s memory bandwidth.

Existing solutions do not close this gap. NVIDIA GDS [46] streams weight files from SSD directly into GPU memory on supported configurations. On DGX Spark (GB10), however, GDS supports only compatibility mode, preventing use of its native storage-to-GPU DMA path [47]. Asynchronous loading [14, 16, 35, 60] overlaps file I/O with weight transfer, but the copy remains exposed in our UMA measurements—file I/O is only 61% of the 0.97 s transfer in Figure 2 (“Pipeline”)—and staging buffers add to peak memory use (§2.3). Zero-copy interfaces [44] offer the right abstraction, but deliver inconsistent performance across frameworks and platforms and require intrusive, per-framework changes to the loader. Besides weight transfer, synchronous page zeroing remains a runtime-allocation bottleneck on the tested platforms (§2.2). UMA thus calls for a loading mechanism that (G1) eliminates weight transfer rather than overlapping it, thereby also avoiding the staging memory that pipelined loaders need; (G2) accelerates synchronous page zeroing on the allocation path while preserving its security semantics; and (G3) generalizes across UMA platforms and integrates with existing inference frameworks with little or no modification.

Our approach. We present UMLoad, a system-level model-loading accelerator for UMA devices. UMLoad reuses source pages on CPU to eliminates weight transfer (G1) and uses GPU-assisted zeroing to accelerate runtime allocation (G2). It integrates with existing inference frameworks across UMA platforms with little or no modification (G3).

Eliminating weight transfer transparently. Reusing source pages must preserve independent CPU and GPU buffers. Direct sharing allows later CPU writes to affect GPU contents. Unconditional ownership transfer is also insufficient: CPU contents must remain accessible, but sources without file backing cannot be reconstructed after handoff. UMLoad uses on-demand reconstruction: it transfers exclusive ownership of file-backed pages in an aligned, huge-page layout to the GPU and reconstructs the CPU source in separate pages only upon later CPU access. This preserves copy independence while supporting ordinary GPU reads and writes. The aligned, contiguous huge-page mapping preserves efficient GPU address translation. During model loading, the CPU rarely accesses these pages afterward, so reconstruction is almost never triggered, preserving copy independence with virtually no additional memory overhead (§4).

Accelerating synchronous page zeroing. Offloading page zeroing to the GPU shifts the bottleneck from zeroing bandwidth to CPU orchestration: page acquisition, GPU mapping, and cache maintenance remain substantial. UMLoad combines two techniques to turn fast GPU zeroing into fast allocation. First, it splits each allocation request into page batches and pipelines CPU work with GPU zeroing across batches, overlapping CPU and GPU execution. However, CPU work can still outlast GPU execution and leave the GPU waiting between batches. Second, it shortens CPU stages by preparing GPU mapping resources ahead of time to reduce per-batch mapping work and parallelizing cache maintenance. Together, these techniques allow allocation throughput to approach the GPU's zeroing throughput. Throughout, pages are still zeroed before use, preserving the security guarantee (§5).

Implementation and results. We implement UMLoad on Intel and AMD without framework changes, and extend it to NVIDIA Jetson AGX Orin with minor changes to the framework (due to the closed-source CUDA runtime). In the overall evaluation with llama.cpp, PyTorch, and vLLM across six models, per-platform average loading-time reductions are 36.6%–71.9% over vanilla and 19.9%–62.7% over pipelined loaders. UMLoad's peak memory during loading is 1.01−1.02×1.01-1.02\times the weight-file size, compared with 1.1−2.0×1.1-2.0\times for pipelined and vanilla loading. In application case studies, UMLoad improves user-perceivable response latency by reducing mean LLM-routing TTFT by 51.3%–59.3% and model-backed tool completion latency by 10.2%–31.6%.

Contributions. We summarize our contributions as follows:

  • A characterization of on-demand workloads on UMA that identifies two inefficiencies and explains why existing solutions fail to address them ( §2§2).

  • Two techniques for transparent model loading on UMA: on-demand reconstruction, which eliminates weight transfer while preserving copy independence ( §4§4), and GPU-assisted page zeroing, which accelerates runtime memory allocation while preserving its security semantics ( §5§5).

• An implementation across three UMA platforms ( §6§6) and an evaluation that demonstrates the advantage and efficacy of UMLoad ( §7§7).

References (54)