Font Size: a A A

Research On Loop Distribution Technology For Shenwei GCC Compiler System

Posted on:2022-05-07Degree:MasterType:Thesis
Country:ChinaCandidate:M Y ChenFull Text:PDF
GTID:2518306326452494Subject:Master of Engineering
Abstract/Summary:PDF Full Text Request
Compiler system,as a converter from high-level programming language to machine code,is a bridge connecting almost all software and hardware.The execution efficiency of the code generated by the compiling system directly affects the performance provided by the hardware architecture.This article is oriented to the characteristics of the Shenwei processor architecture and instruction system,and further uses the hardware performance of the Shenwei processor as the main research content.The main research content is the transplantation and optimization of the open source GCC compiler.The research of Shenwei processor and Shenwei GCC compilation system deeply analyzes the impact of loop distribution technology on the performance of the compiler.According to the main characteristics of loop distribution technology,optimize the performance of Shenwei GCC compilation.The main work and innovation include the following content :(1)A new circular distribution algorithm based on the inter-region dependency graph is proposed.The original cyclic distribution algorithm is based on the memory access relationship of instructions for corresponding division and merging.During the merging process,instructions that have the same memory access area will be merged into the same area,but this merging strategy may cause excessive merging and fail For the distribution of regions,this paper proposes a strongly connected merging algorithm based on the inter-region dependency graph,so as to minimize the merged region and ensure the effectiveness of the circular distribution.(2)A cyclic distribution optimization method based on vector cost model guidance is proposed.Constructed a cost model for Shenwei GCC vectorized compilation and instruction characteristics,and introduced the cost model into the loop distribution process,which solved the possible program performance loss caused by the current compiler's inability to evaluate the performance of loop distribution,and improved The program optimization effect of implementing cyclic distribution transformation in the compiler.The work of this article has been implemented in the Shenwei GCC compiler.The SPEC2006 standard test set test shows that the average performance of fixed-point programs is increased by 3%,the average performance of floating-point programs is increased by 5%,the overall average performance is increased by 4%,and the highest acceleration effect has reached 13%,And the negative acceleration caused by the original circulation distribution is effectively eliminated,which verifies the correctness and effectiveness of the work in this paper.
Keywords/Search Tags:GCC compiler, automatic vectorization, loop distribution, dependency graph, cost model
PDF Full Text Request
Related items