Skip to main content
QUICK REVIEW

[Paper Review] pHNSW: PCA-Based Filtering to Accelerate HNSW Approximate Nearest Neighbor Search

Zheng Li, Guangyi Zeng|arXiv (Cornell University)|Feb 22, 2026
Advanced Image and Video Retrieval TechniquesComputer Science0 citations
TL;DR

pHNSW combines PCA-based dimensionality reduction with a custom ISA-driven processor to accelerate HNSW ANN search, achieving substantial QPS gains and energy savings while maintaining high recall.

ABSTRACT

Hierarchical Navigable Small World (HNSW) has demonstrated impressive accuracy and low latency for high-dimensional nearest neighbor searches. However, its high computational demands and irregular, large-volume data access patterns present significant challenges to search efficiency. To address these challenges, we introduce pHNSW, an algorithm-hardware co-optimized solution that accelerates HNSW through Principal Component Analysis (PCA) filtering. On the algorithm side, we apply PCA filtering to reduce the dimensionality of the dataset, thereby lowering the volume of neighbor access and decreasing the computational load for distance calculations. On the hardware side, we design the pHNSW processor with custom instructions to optimize search throughput and energy efficiency. In the experiments, we synthesized the pHNSW processor RTL design with a 65nm technology node and evaluated it using DDR4 and HBM1.0 DRAM standards. The results show that pHNSW boosts Queries per Second (QPS) by 14.47x-21.37x on a CPU and 5.37x-8.46x on a GPU, while reducing energy consumption by up to 57.4% compared to standard HNSW implementation.

Motivation & Objective

  • Motivate accelerating high-dimensional ANN search (HNSW) by reducing data dimensionality without sacrificing accuracy.
  • Propose a PCA-based filtering strategy (pHNSW) integrated into the HNSW framework.
  • Design a custom pHNSW processor with an ISA and optimized memory/dataflow to boost throughput and energy efficiency.
  • Evaluate the approach on SIFT1M with realistic off-chip memory configurations to quantify throughput and energy gains.

Proposed method

  • Apply PCA to project high-dimensional data to a lower-dimensional space before neighbor filtering.
  • Perform low-dimensional distance calculations and sorting to select a top-k candidate set per layer.
  • Back-project the top-k low-dimensional candidates to high-dimensional space for exact distance computations.
  • Introduce a hierarchical, layer-specific k value to balance recall and throughput across the HNSW graph layers.
  • Organize off-chip data to enable regular, sequential access of low-dimensional data to reduce irregular memory patterns.
  • Implement a pHNSW processor with a dedicated ISA, custom dist and sort units, and DMA-based data flow to accelerate search.

Experimental results

Research questions

  • RQ1Can PCA-based filtering reduce high-dimensional distance computations in HNSW without substantially harming recall?
  • RQ2How should the top-k parameter be chosen across HNSW layers to balance recall and QPS?
  • RQ3What architectural choices (data layout, custom ISA, parallel distance/sort units) maximize search throughput and energy efficiency for pHNSW?
  • RQ4What are the throughput and energy benefits of the algorithm–hardware co-design on realistic DRAM standards (DDR4 / HBM1.0) with SIFT1M?

Key findings

  • pHNSW achieves recall@10 around 0.92 on SIFT1M with selected layer-wise k values.
  • Single-query QPS improvements over CPU baseline range from 14.47× to 21.37× for DDR4 and HBM configurations respectively, when compared to HNSW on CPU.
  • Compared to GPU baseline, pHNSW attains 5.37× to 8.46× higher QPS.
  • Energy consumption per query is reduced by up to 57.4% relative to standard HNSW hardware implementations, with DRAM access dominating energy usage.
  • The pHNSW processor area is 0.739 mm^2, with notable contributions from on-chip memories (SPM) and the Dist.L/kSort.L compute units.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.