单指令多数据(SIMD)扩展部件旨在发掘多媒体程序和科学计算程序的数据级并行,归约操作引起的真依赖给发掘程序中的数据级并行带来了阻碍.但体系结构和指令集的差异,使得面向向量机的归约向量化方法并不适用于SIMD扩展部件.针对上述问题,提出一种面向SIMD扩展部件的归约向量代码生成方法,以及归约的识别方法,利用向量移位指令实现向量代码生成.基于SPEC2006标准测试集的测试结果表明,与未利用归约向量化技术前相比,利用该归约向量化方法后的向量化加速比提高34%,从而验证了该方法的有效性.%Single Instruction Multiple Data(SIMD) aims at exploiting the data-level parallelism of multimedia and scientific calculation.The true dependence caused by reduction operation hinders exploring data-level parallelism.But different architecture and instruction set make reduction vectorization method based on vector machine unsuitable to SIMD.This paper presents a new approach of generating SIMD code with reduction.It presents a method to identify reduction operations,and conducts code generation using vector shift instructions.Experimental result based on SPEC and some other standard test sets shows the validity of this method,with 34% improvement in the vectorization acceleration ratio.
展开▼