<?xml version="1.0" encoding="UTF-8"?><?xml-stylesheet type="text/xsl" href="static/style.xsl"?><OAI-PMH xmlns="http://www.openarchives.org/OAI/2.0/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/ http://www.openarchives.org/OAI/2.0/OAI-PMH.xsd"><responseDate>2026-11-30T17:30:59Z</responseDate><request verb="GetRecord" identifier="oai:repository.rice.edu:1911/118527" metadataPrefix="dim">https://repository.rice.edu/server/oai/request</request><GetRecord><record><header><identifier>oai:repository.rice.edu:1911/118527</identifier><datestamp>2025-09-16T20:46:39Z</datestamp><setSpec>com_1911_8299</setSpec><setSpec>col_1911_13110</setSpec></header><metadata><dim:dim xmlns:dim="http://www.dspace.org/xmlns/dspace/dim" xmlns:doc="http://www.lyncode.com/xoai" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.dspace.org/xmlns/dspace/dim http://www.dspace.org/schema/dim.xsd">
   <dim:field mdschema="dc" element="contributor" qualifier="advisor">Jermaine, Christopher M.</dim:field>
   <dim:field mdschema="dc" element="creator">Yao, Jiawen</dim:field>
   <dim:field mdschema="dc" element="date" qualifier="accessioned">2025-05-30T21:06:40Z</dim:field>
   <dim:field mdschema="dc" element="date" qualifier="available">2025-05-30T21:06:40Z</dim:field>
   <dim:field mdschema="dc" element="date" qualifier="created">2025-05</dim:field>
   <dim:field mdschema="dc" element="date" qualifier="issued" lang="en_US">2025-04-25</dim:field>
   <dim:field mdschema="dc" element="date" qualifier="submitted">May 2025</dim:field>
   <dim:field mdschema="dc" element="date" qualifier="updated">2025-05-30T21:06:40Z</dim:field>
   <dim:field mdschema="dc" element="identifier" qualifier="uri">https://hdl.handle.net/1911/118527</dim:field>
   <dim:field mdschema="dc" element="description" qualifier="abstract">The rapid growth in the size and complexity of large language models has imposed
severe challenges on memory management, particularly when these models are
deployed on GPUs with limited memory. This thesis introduces a fine-grained paging
mechanism that dynamically offloads and reloads tensors at the granularity of
individual operations, thereby mitigating out-of-memory (OOM) issues during the
inference and prefill phase of transformer-based models. Instead of traditional static,
layer-based offloading methods, the proposed approach uses compile-time, simulationbased
memory allocation to optimize GPU memory usage, making runtime possible
under severe memory constraints.
This work is based off of the Einsummable system, a framework that represents
tensor computations using Einstein summation notation. Einsummable transforms
high-level mathematical specifications into an optimized execution pipeline through a
series of intermediate representations, notably the taskgraph and the memgraph.
The taskgraph captures the data dependencies and operational flow of tensor computations,
while the memgraph extends this representation by incorporating detailed
memory location information and managing offload-reload operations. The transformation
from taskgraph to memgraph is achieved through a simulated execution
process — the core of this thesis — that relies on two key components: an allocation
horizon, which pre-allocates memory for future operations, and an execution horizon,
which tracks the simulated execution progress of the computation.
A key contribution of this thesis is the design and implementation of specialized
memory allocation routines—simMalloc, simMallocForceReld, and simMallocOffld.
These routines not only allocate memory for tensor outputs but also manage dependencies
by inserting offload and reload nodes into the memgraph whenever GPU
memory resources depletes. By leveraging full knowledge of the simulated execution
order, our offload-reload heuristic selects tensors for offloading based on their
computed reuse distance, thereby deferring memory transfers until they are most
convenient. This future-aware strategy mitigates the frequency and impact of memory
transfers compared to reactive approaches, enabling a finer control over GPU
memory usage.
Extensive experimental evaluations were conducted using two configurations of
NVIDIA GPUs — Tesla P100 and V100 — to benchmark the performance of the
proposed system against state-of-the-art techniques such as ZeRO-Inference. The
evaluation focused on the prefill stage of inference in LLaMA models with 7B and 65B
parameters, a phase known to be particularly memory-bound. The results demonstrate
that the fine-grained paging mechanism supports a broader range of configurations,
successfully executing inference tasks across varying batch sizes and sequence
lengths. While the finer granularity of tensor-level management introduces some
communication overhead due to more frequent offloading and reloading, the overall
improvements in memory utilization and reduction in OOM errors outweigh these
costs.
In summary, this thesis makes a contribution to the field of deep learning by
addressing the critical challenge of GPU memory constraints through a fine-grained
paging mechanism. Future work will explore further optimizations to reduce communication
overhead, overall computation latency, and GPU RAM utilization.</dim:field>
   <dim:field mdschema="dc" element="format" qualifier="mimetype">application/pdf</dim:field>
   <dim:field mdschema="dc" element="language" qualifier="iso" lang="en_US">eng</dim:field>
   <dim:field mdschema="dc" element="rights" lang="en_US">Copyright is held by the author, unless otherwise indicated. Permission to reuse, publish, or reproduce the work beyond the bounds of fair use or other exemptions to copyright law must be obtained from the copyright holder.</dim:field>
   <dim:field mdschema="dc" element="subject">Machine Learning Systems</dim:field>
   <dim:field mdschema="dc" element="subject">Memory Management</dim:field>
   <dim:field mdschema="dc" element="subject">Large Language Models</dim:field>
   <dim:field mdschema="dc" element="title">Fine-Grained Paging Mechanism for Offloading-Reloading Tensor for LLM</dim:field>
   <dim:field mdschema="dc" element="type">Thesis</dim:field>
   <dim:field mdschema="dc" element="type" qualifier="material">Text</dim:field>
   <dim:field mdschema="thesis" element="degree" qualifier="department">Computer Science</dim:field>
   <dim:field mdschema="thesis" element="degree" qualifier="discipline" lang="en_US">Engineering</dim:field>
   <dim:field mdschema="thesis" element="degree" qualifier="grantor">Rice University</dim:field>
   <dim:field mdschema="thesis" element="degree" qualifier="level">Masters</dim:field>
   <dim:field mdschema="thesis" element="degree" qualifier="name">Master of Science</dim:field>
   <dim:field mdschema="others" element="access-status">open.access</dim:field>
</dim:dim>
</metadata></record></GetRecord></OAI-PMH>