arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2501.03245cs.CRcs.ARcs.DC
收藏

gECC:一种基于GPU的椭圆曲线密码学高吞吐量框架

gECC: A GPU-based high-throughput framework for Elliptic Curve Cryptography

Qian Xiong, Weiliang Ma, Xuanhua Shi, Yongluan Zhou, Hai Jin, Kaiyi Huang, Haozhou Wang, Zhengru Wang

AI总结:

本文提出面向GPU的gECC框架,通过批量EC运算、并行化、内存管理及减少IMAD指令等优化,显著提升ECDSA、ECDH与区块链应用性能。

摘要:

椭圆曲线密码学(Elliptic Curve Cryptography,ECC)是一种加密方法,可提供与Rivest-Shamir-Adleman(RSA)等传统技术相当的安全性,但具有更低的计算复杂度和更小的密钥尺寸,因此成为区块链、安全多方计算和数据库安全等应用中具有竞争力的选择。然而,ECC的吞吐量仍受到椭圆曲线(elliptic curve,EC)运算相关显著性能开销的阻碍。本文提出gECC,这是一种面向GPU架构优化的通用ECC框架,专门设计用于在EC运算中实现高吞吐量性能。gECC融合了EC运算的批处理执行以及模运算的微架构级优化。该框架采用Montgomery技巧实现批量EC计算,并结合新颖的计算并行化和内存管理技术,以最大化计算并行度并最小化GPU全局内存的访问开销。此外,我们通过研究模乘的用户代码如何被编译为硬件指令以及这些指令的发射率,分析了模乘中的主要瓶颈。我们发现,模乘的效率高度依赖于整数乘加(Integer Multiply-Add,IMAD)指令的数量。为消除该瓶颈,我们提出通过利用谓词寄存器传递进位信息,并使用加法和减法指令(IADD3)替换IMAD指令,来最小化IMAD指令数量的技术。结果表明,对于ECDSA和ECDH,与最先进的基于GPU的系统相比,gECC分别可实现5.56倍和4.94倍的性能提升。在真实世界的区块链应用中,与最先进的基于CPU的系统相比,我们可实现1.56倍的性能提升。

英文摘要:

Elliptic Curve Cryptography (ECC) is an encryption method that provides security comparable to traditional techniques like Rivest-Shamir-Adleman (RSA) but with lower computational complexity and smaller key sizes, making it a competitive option for applications such as blockchain, secure multi-party computation, and database security. However, the throughput of ECC is still hindered by the significant performance overhead associated with elliptic curve (EC) operations. This paper presents gECC, a versatile framework for ECC optimized for GPU architectures, specifically engineered to achieve high-throughput performance in EC operations. gECC incorporates batch-based execution of EC operations and microarchitecture-level optimization of modular arithmetic. It employs Montgomery's trick to enable batch EC computation and incorporates novel computation parallelization and memory management techniques to maximize the computation parallelism and minimize the access overhead of GPU global memory. Also, we analyze the primary bottleneck in modular multiplication by investigating how the user codes of modular multiplication are compiled into hardware instructions and what these instructions' issuance rates are. We identify that the efficiency of modular multiplication is highly dependent on the number of Integer Multiply-Add (IMAD) instructions. To eliminate this bottleneck, we propose techniques to minimize the number of IMAD instructions by leveraging predicate registers to pass the carry information and using addition and subtraction instructions (IADD3) to replace IMAD instructions. Our results show that, for ECDSA and ECDH, gECC can achieve performance improvements of 5.56x and 4.94x, respectively, compared to the state-of-the-art GPU-based system. In a real-world blockchain application, we can achieve performance improvements of 1.56x, compared to the state-of-the-art CPU-based system.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑