首页|面向RISC-V适配开发的x86 built-in函数转换方法

面向RISC-V适配开发的x86 built-in函数转换方法

扫码查看
新兴架构RISC-V的生态建设需要将其他架构函数或软件包向RISC-V架构迁移适配.在研究GCC特定架构适配的built-in函数向RISC-V架构迁移时,提出一套x86到RISC-V的built-in函数转换方法,对于非扩展指令集(属非向量类型)built-in函数,采用RISC-V架构下相同功能的built-in或标准库函数替代;对于SSE扩展指令集built-in函数,建立数据类型映射和向量函数操作映射实现向RISC-V架构向量扩展函数或标准库函数的迁移,其中RVV函数迁移方式占比67%.实验结果表明:方法迁移的程序功能正确,方法有效.本文方法对其他扩展指令集built-in函数的迁移提供了指导,且与现有工作相比,更易扩展、覆盖面更广.
An approach to adapting x86 built-in functions for RISC-V development
The construction of the ecosystem for the emerging RISC-V architecture requires the adaptation and migration of functions or software packages from other architectures to RISC-V.In the study of migrating GCC-specific built-in functions to the RISC-V architecture,a method for converting x86 built-in functions to RISC-V was proposed.For non-extension instruction set built-in functions(which belong to non-vector types),functions with the same functionality in the RISC-V architecture or standard library functions were used as replacements.Concerning SSE extension instruction set built-in functions,the migration involves establishing data type mappings and vector function operation mappings to achieve the transition to RISC-V architecture's vector extension functions or standard library functions.Notably,the migration via RVV functions constitutes 67%of the overall approach.Experimental results demonstrate the correctness of program functionality and the efficacy of the proposed method.Additionally,this method provides guidance for the migration of built-in functions from other extension instruction sets,offering broader coverage and enhanced scalability compared to existing approaches.

function migrationbuilt-in functioninstruction set extensionRISC-V migra-tion

丁志远、朱家鑫、吴国全、王伟

展开 >

广西大学计算机与电子信息学院,广西南宁 530004

中国科学院软件研究所软件工程技术研究开发中心,北京 100190

函数迁移 built-in函数 指令扩展集 RISC-V迁移

中国科学院战略性先导科技专项国家自然科学基金联合基金项目

XDA0320000U20A6003

2024

广西大学学报(自然科学版)
广西大学

广西大学学报(自然科学版)

CSTPCD北大核心
影响因子:0.767
ISSN:1001-7445
年,卷(期):2024.49(3)
  • 6