检索规则说明:AND代表“并且”;OR代表“或者”;NOT代表“不包含”;(注意必须大写,运算符两边需空一格)
检 索 范 例 :范例一: (K=图书馆学 OR K=情报学) AND A=范并思 范例二:J=计算机应用与软件 AND (U=C++ OR U=Basic) NOT M=Visual
作 者:曹克乾 赵荣彩 王磊[1] CAO Keqian;ZHAO Rongcai;WANG Lei(Research Institute of Frontier Information Technology,Zhongyuan University of Technology,Zhengzhou Henan 450007,China)
机构地区:[1]中原工学院前沿信息技术研究院,郑州450007
出 处:《计算机应用》2022年第S01期221-225,共5页journal of Computer Applications
摘 要:低精度浮点数常用于深度学习加速,目前申威平台缺乏对低精度浮点数的支持,数学库的设计往往需要结合数据类型与处理器特点定制算法才能发挥出最大优势,旨在为申威1621平台设计一套支持半精度计算的超越函数。通过分析各类浮点数特性,结合申威1621的结构特点提出一种基于回乘取余查表算法。首先,对函数的定义域进行归约,生成精简的数据表;然后将回乘取余后的数值按照sign、exponent、mantissa三部分拆分计算索引;最后,查表返回结果。测试结果表明,使用回乘取余查表算法实现的半精度超越函数,相较于基于多项式近似、移位相加等算法的申威数学库及GLIBC开源数学库,性能分别提升了116%和215%。在精度需求不高的应用中既保证了正确性又大幅度提升了数学函数计算效率。Low-precision floating-point numbers are often used to accelerate deep learning.While designing the mathematic library,algorithms are usually customized based on the characteristic of data type and processor to improve precision or performance.Shenwei can not support low-precision floating-point system.To design a set of transcendental functions supporting half-precision computation,the characteristics of various floating-point numbers were analyzed and combined with the characteristics of Shenwei 1621,and a Multi-Back-Remainder based on Table Lookup(MBRTL)algorithm was proposed.First,the domain of the function was reduced to generate a simplified data table.Then,the value calculated with MBRTL was divided into three parts:sign,exponent,and mantissa to get the index.Finally,the result was looked up from the table and returned.The experimental results show that the performance of the half-precision transcendental function implemented with MBRTL is 116%and 215%higher than thoise of the Shenwei mathematic library and GLIBC mathematic library which were implemented based on polynomial approximation,shift-addition,etc.The correctness and efficiency of half-precision transcendental function were greatly improved in applications with no high precision requirement.
分 类 号:TP311.5[自动化与计算机技术—计算机软件与理论]
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在链接到云南高校图书馆文献保障联盟下载...
云南高校图书馆联盟文献共享服务平台 版权所有©
您的IP:3.17.73.81