Font Size: a A A

The Research On Program Optimization And Program Transformation Method

Posted on:2015-03-07Degree:MasterType:Thesis
Country:ChinaCandidate:X L ZhangFull Text:PDF
GTID:2268330428999870Subject:Computer software and theory
Abstract/Summary:PDF Full Text Request
Program optimization and program transformation is a hot research issue in the area of compiler. This article provides tools and support for program optimization and program transformation on the level of source code、compiler’s abstract syntax tree and compiler’s internal representation. This article presents a C to C/CUDA program transformation tool, a tool for separating structure array and a structure analysis algorithm for heap-allocated memory object. These tools and algorithm can parallelize program, improve the data locality of program and provide support for memory optimization.1、A tool for C to C/CUDA program transformationProgram parallelization an important way to improve the performance of program in the program optimization. This article implements a script-driven、C to C/CUDA program transformation tool named DPOET and based on POET, which is also a program transforation tool. When using DPOET for program transformation, users only need to list the template code, it’s paramaters and the target code in a dpoet script. Then the DPOET can translate the script into POET script, then call the POET to complete the trasformation. It’s very easy to using DPOET.2、A tool for separating structure arrayThe structure arrays can reduce the data locality of the program, then impact the peformance of the program. To separate the structure array, this article presents a tool based on the Clang AST of LLVM complier. Without changing the sematics of the program, this tool can separate the structure array into multiple arrays.3、A Structure analysis algorithm for heap-allocated memory objectWhen doing memory optimization for two heap-allocated memory objects, it needs their structure information to guarantee that they are independent. In C program, the developers can use pointer, so they can construct a heap object that has any depth. We cannot get the structure information of this object just by the pointer that points to it or just by it’s first node. To this end, this article presents a field-sensitive、 flow-sensitive and context-sensitive structure analysis algorithm for heap-allocated memory object. The algorithm has two parts:a field-sensitive and flow-sensitive intra-procedural algorithm and a context-sensitive inter-procedural algorithm.
Keywords/Search Tags:program parralelization, data locality, separating structure array, memory optimization, structure analysis
PDF Full Text Request
Related items