Privacy-preserving machine learning has become an important long-term pursuit in this era of artificial intelligence (AI). Fully Homomorphic Encryption (FHE) is a uniquely promising solution, offering provable privacy and security guarantees. Unfortunately, computational cost is impeding its mass adoption. Modern solutions are up to six orders of magnitude slower than plaintext execution. Understanding and reducing this overhead is essential to the advancement of FHE, particularly as the underlying algorithms evolve rapidly. This paper presents a detailed characterization of OpenFHE, a comprehensive open-source library for FHE, with a particular focus on the CKKS scheme due to its significant potential for AI and machine learning applications. We introduce CryptOracle, a modular evaluation framework comprising (1) a benchmark suite, (2) a hardware profiler, and (3) a predictive performance model. The benchmark suite encompasses OpenFHE kernels at three abstraction levels: workloads, microbenchmarks, and primitives. The profiler is compatible with standard and user-specified security parameters. CryptOracle monitors application performance, captures microarchitectural events, and logs power and energy usage for AMD and Intel systems. These metrics are consumed by a modeling engine to estimate runtime and energy efficiency across different configuration scenarios, with error geomean of $-7.02\%\sim8.40\%$ for runtime and $-9.74\%\sim15.67\%$ for energy. CryptOracle is open source, fully modular, and serves as a shared platform to facilitate the collaborative advancements of applications, algorithms, software, and hardware in FHE. The CryptOracle code can be accessed at https://github.com/UnaryLab/CryptOracle.
翻译:隐私保护的机器学习已成为人工智能时代一项重要的长期追求。全同态加密(FHE)是一种极具前景的解决方案,能提供可证明的隐私与安全保障。然而,计算成本阻碍了其大规模应用。现代方案比明文执行慢多达六个数量级。理解并降低这一开销对于FHE的发展至关重要,尤其是在底层算法快速演进的背景下。本文对OpenFHE——一个全面的开源FHE库——进行了详细表征,并特别聚焦于CKKS方案,因其在人工智能和机器学习应用中具有显著潜力。我们提出了CryptOracle,一个模块化评估框架,包含:(1) 基准测试套件、(2) 硬件分析器、以及(3) 预测性能模型。基准测试套件涵盖三个抽象层次的OpenFHE内核:工作负载、微基准测试和原语。分析器兼容标准及用户指定的安全参数。CryptOracle监控应用性能,捕获微架构事件,并记录AMD和Intel系统的功耗与能量使用。这些度量由建模引擎用于估算不同配置场景下的运行时间和能效,其中运行时间的误差几何平均值为$-7.02\%\sim8.40\%$,能量的误差几何平均值为$-9.74\%\sim15.67\%$。CryptOracle是开源的、完全模块化的,并作为一个共享平台,促进FHE中应用、算法、软件和硬件的协同进步。CryptOracle代码可通过https://github.com/UnaryLab/CryptOracle获取。