一句话:通过分析 TFHE 子任务亲和性并离线调度,减少 PIM 中的远程数据访问,实现显著加速。
全同态加密 TFHE 计算密集,内存内处理(PIM)虽具高内部带宽,但已有 TFHE 加速器主要挖掘并行性而忽视数据亲和性,导致过多远程数据访问(RDA),在 PIM 上性能下降。本文提出面向 PIM 的基于亲和性的优化方法:对 TFHE 进行算法级优化以利用 PIM 内部带宽,分析其子任务的亲和性模式,并设计离线调度器,在保持足够并行度的同时最小化 RDA。为验证实用性,作者在现有 PIM-HBM 设备上做最小硬件修改,构建 FPGA 原型 PIM 系统并评估。实验表明,在真实基准上相比已有 TFHE 加速器取得 4.24–209× 加速。
Processing-in-memory (PIM) architectures are promising for accelerating intensive workloads due to their high internal bandwidth. This paper introduces a technique for accelerating Fully Homomorphic Encryption over the Torus (TFHE), a promising yet intensive application, on a realistic PIM system. Existing TFHE accelerators focus on exploiting parallelism, often overlooking data affinity, which leads to performance degradation in PIM due to excessive remote data accesses (RDAs). To address this, we present an affinity-based approach that optimizes the computation of TFHE on PIM. We apply algorithmic optimizations to TFHE, enabling PIM to effectively leverage its high internal bandwidth. We analyze the affinity patterns in the sub-tasks of TFHE and develop an offline scheduler that exploits our analysis to find optimal scheduling, minimizing RDAs while maintaining sufficient parallelism. To demonstrate the practicality of our work, we design a variant of an existing PIM-HBM device with minimal hardware modifications, and perform evaluations over a real FPGA-based PIM system. Our experiments demonstrate that our affinity-based optimizations outperform prior TFHE accelerators by 4.24-209× for real-world benchmarks.