GPIR: Enabling Practical Private Information Retrieval with GPUs

Hyesung Ji, Hyunah Yu, Jongmin Kim, Wonseok Choi, G. Edward Suh, Jung Ho Ahn

TL;DR

GPIR is a highly optimized, GPU-accelerated framework designed to make lattice-based Private Information Retrieval (PIR) practical for real-world deployment. By introducing a stage-aware hybrid execution model that bypasses the "cache-capacity wall" and optimizing data layouts for matrix multiplications, GPIR achieves up to a 297.2× throughput improvement over previous state-of-the-art implementations.

What Problem Does This Paper Address?

Private Information Retrieval (PIR) allows a client to download a record from a public database without the server learning which record was requested. While highly desirable for privacy-preserving applications like private DNS resolution or visual search, single-server lattice-based PIR is notoriously slow. To hide the query index, the server must homomorphically process the entire database for every single request, incurring massive computational and memory overhead.

To achieve high throughput, servers must process queries from multiple clients concurrently using multi-client batching. However, the authors reveal that batching fundamentally alters the hardware bottlenecks on GPUs:

  1. The Cache-Capacity Wall: Batching expands the intermediate working sets during query expansion and reduction, causing data to spill out of the GPU's L2 cache into the much slower DRAM.
  2. Data Layout Conflicts: Cryptographic operations prefer data layouts optimized for Number-Theoretic Transforms (NTTs), whereas the row-selection phase reduces to large-scale General Matrix Multiplications (GEMMs), which require entirely different data layouts to achieve high hardware efficiency.

Methods

GPIR tackles these bottlenecks through three core architectural optimizations:

  • Stage-Aware Hybrid Execution: Instead of using a one-size-fits-all kernel, GPIR dynamically switches strategies based on the execution stage. For shallow tree depths where data fits inside the L2 cache, it uses fine-grained operation-level kernels to maximize GPU occupancy. For deeper stages where digit decomposition causes memory spikes, it switches to fused stage-level kernels that keep intermediate data entirely within registers and shared memory.
  • Optimized Transposed-Layout RowSel: GPIR explicitly transposes the query ciphertexts into a GEMM-friendly layout ($k$-major or $m/n$-major) prior to the row selection phase, enabling efficient thread-block tiling.
  • Fine-Grained $p$-Dimension Pipelining: To eliminate the latency overhead introduced by data transposition, GPIR partitions the computation along the polynomial ($p$) dimension using prime-level streams and $N$-chunked kernel launches. This allows the transposition of one data chunk to overlap perfectly with the GEMM execution of another.
  • Scalable Multi-GPU Orchestration: GPIR shards the database across multiple GPUs and utilizes high-bandwidth interconnects (like NVLink) to perform low-overhead all-gather operations on expanded queries.
OnionPIRv2 computation process.

Datasets

The system was evaluated using simulated database configurations matching the standard OnionPIRv2 protocol parameters. The benchmarks included database sizes of 1 GB, 2 GB, and 4 GB consisting of 16 KB records, configured to provide 128-bit cryptographic security.

Key Insights and Ideas

  • Batching Amplifies Memory Spikes: Digit decomposition (Dcp) temporarily expands the number of polynomials by a factor of $\ell$ (typically 5). Under multi-client batching, these transient spikes overlap and quickly breach the GPU's L2 cache capacity, turning short-lived memory expansions into severe DRAM bottlenecks.

    Operation-wise working set variation across ExpandQuery and ColTor phases under different batch sizes.
  • The Occupancy vs. Bandwidth Asymmetry: The authors demonstrate that maximizing thread occupancy is critical for L2-cache-resident workloads to hide instruction latency. However, once a workload becomes DRAM-bandwidth-bound, performance saturates at much lower occupancies. Consequently, fusing kernels to reduce DRAM traffic is far more beneficial than maintaining high occupancy.

  • Hiding Grid Saturation: Standard GEMM kernels launch massive thread grids that saturate the GPU, preventing concurrent execution of transposition kernels even if placed in separate CUDA streams. Fine-grained chunking is mandatory to create the scheduling headroom needed for effective pipelining.

Key Results

GPIR was evaluated on modern GPU architectures, including the NVIDIA RTX 5090 and H100 NVL.

  • Massive Throughput Gains: GPIR achieves up to 297.2× higher throughput compared to PIRonGPU, and up to 123.8× over ShiftPIR.
  • DRAM Traffic Reduction: The hybrid execution model successfully mitigates the cache-capacity wall, reducing DRAM transactions by up to 1.83× for query expansion and 1.52× for column tournaments.
  • Compute-Bound Efficiency: The layout optimizations successfully pushed the RowSel phase into a compute-bound regime, achieving 86.88% of the GPU's peak theoretical integer throughput.
  • Excellent Multi-GPU Scaling: Using four NVLink-connected H100 GPUs, GPIR achieved a 3.76× near-linear speedup for throughput scaling and maintained near-constant performance when scaling database capacity up to 16 GB.
Roofline analysis of each PIR phase on an RTX 5090 with a 2 GB DB.

Limitations and Future Work

Despite scaling efficiently across multiple GPUs, GPIR is ultimately bounded by the aggregate physical DRAM capacity of the available GPUs. Because homomorphic encryption introduces a roughly 4× storage overhead for plaintext data, hosting exceptionally large databases (e.g., hundreds of gigabytes) entirely in GPU memory remains cost-prohibitive.

The authors suggest that future work should explore tightly integrated CPU-GPU architectures (such as the NVIDIA Grace Hopper Superchip) to leverage high-bandwidth host-memory offloading as a practical fallback when databases exceed onboard GPU capacity.

Summary updated

BibTeX
@inproceedings{ji2026gpir,
  author = {Hyesung Ji and Hyunah Yu and Jongmin Kim and Wonseok Choi and G. Edward Suh and Jung Ho Ahn},
  title = {{GPIR: Enabling Practical Private Information Retrieval with GPUs}},
  booktitle = {ICS},
  year = {2026},
  doi = {10.1145/3797905.3807844},
}
Figure