ScalableHD: Scalable and High-Throughput Hyperdimensional Computing Inference on Multi-Core CPUs

Dhruv Parikh, Viktor K. PrasannaarXiv 2025 · DOI

Hyperdimensional Computing (HDC) is a brain-inspired paradigm that represents data using massive vectors, typically with dimensions $D \ge 10,000$. While HDC is praised for its robustness and inherent parallelism, it often encounters a "memory wall" when implemented on standard general-purpose CPUs. This paper introduces ScalableHD, a high-performance framework designed to overcome these bottlenecks and deliver massive throughput gains on multi-core CPU architectures.

The Challenge: The Memory Wall in HDC

Modern HDC models, such as TrainableHD, require frequent access to large "base" and "class" hypervector matrices. On standard CPUs, naive parallelization often leads to severe performance degradation. The processor frequently stalls, waiting for data to move from high-latency RAM to the cache. Furthermore, modern multi-socket servers utilize Non-Uniform Memory Access (NUMA) architectures. Without coordinated thread placement, uncoordinated data access across sockets can lead to significant latency penalties.

System Architecture

ScalableHD addresses these challenges through a hardware-aware design that optimizes data movement and thread locality. The framework employs a two-stage pipelined execution model, splitting the inference process into Feature Encoding (Stage I) and Similarity Search (Stage II).

Overview of the ScalableHD framework architecture, illustrating the pipeline from application to hardware-aware execution on multi-core CPUs.

As shown in Figure 1, the framework takes input data $X$ and model parameters $B, M$, processing them through the ScalableHD engine. This engine is supported by two critical optimization layers: Memory Tiling and NUMA-Aware W2C (Worker-to-Core) Binding. These layers ensure that the workload is efficiently mapped onto the underlying Multi-Core Multi-Threaded (MCMT) CPU architecture.

Methods and Execution Variants

To handle different operational requirements, ScalableHD offers two execution variants:

  1. ScalableHD-S (Small Batch): Optimized for low-latency scenarios. It parallelizes computation across the dimensions of the hypervectors.
  2. ScalableHD-L (Large Batch): Optimized for high-throughput scenarios. It parallelizes work across input samples and utilizes an all-to-all communication pattern between pipeline stages.

A core innovation of ScalableHD is its use of Streaming and Tiling. Instead of processing entire matrices at once, the framework streams "tiles" (data blocks) through lock-free queues between stages. This approach keeps intermediate data within the CPU's L3 cache, drastically reducing expensive trips to main memory.

Data partitioning and tiling strategy for input matrix X, base matrix B, and intermediate hypervector matrix H, highlighting the differences between ScalableHD-L and ScalableHD-S.

Figure 2 illustrates how the input matrix $X$ and base matrix $B$ are partitioned into tiles of size $n \times f$ and $f \times d$, respectively. This tiling strategy allows Stage I workers to produce chunks of the intermediate matrix $H$ that are immediately consumed by Stage II workers, facilitating efficient cache utilization.

Hardware-Aware Optimizations

Beyond tiling, ScalableHD implements NUMA-Aware Binding. By pinning "producer" threads (Stage I) and "consumer" threads (Stage II) to the same physical cores or NUMA nodes, the framework ensures that data streamed between stages remains "local" to the processor, avoiding the high latency of inter-socket communication.

Evaluation and Results

The framework was evaluated across eight diverse classification datasets, including image recognition (MNIST), human activity recognition (PAMAP2), and biosignal analysis (EMOTION).

Key results include:

  • Throughput Gains: ScalableHD achieved up to a 10x speedup in samples per second compared to the state-of-the-art TorchHD library on AMD EPYC platforms.
  • Near-Linear Scalability: The framework demonstrated exceptional scalability; doubling the core count resulted in nearly double the throughput, even for memory-intensive workloads.
  • Optimization Impact: Ablation studies revealed that memory tiling alone provided up to a 2.8x speedup, while the combination of tiling and NUMA-aware binding yielded a 6.1x improvement for small-batch variants.

Conclusion

ScalableHD demonstrates that HDC inference can be highly efficient on general-purpose CPUs when the implementation is hardware-aware. By treating HDC as a memory-bound streaming task rather than a purely compute-bound one, the authors achieve significant performance breakthroughs. Future work includes developing autotuning mechanisms for tile sizes and extending the framework to heterogeneous CPU-GPU systems.

Summary updated

BibTeX
@misc{parikh2025scalablehd,
  author = {Dhruv Parikh and Viktor K. Prasanna},
  title = {{ScalableHD: Scalable and High-Throughput Hyperdimensional Computing Inference on Multi-Core CPUs}},
  year = {2025},
  eprint = {2506.09282},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2506.09282},
}
Figure