Changes between Version 57 and Version 58 of Orio
- Timestamp:
- 06/13/08 08:16:50 (15 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Orio
v57 v58 7 7 == Overview == 8 8 9 '''Orio''' is an extensible annotation system, implemented in Python, that aims at improving both performance and productivity by enabling software developers to insert annotations into their source code (in C /C++) that trigger a number of low-level performance optimizations on a specified code fragment. The tool generates many tuned versions of the same operation using different optimization parameters, and performs an empirical search for selecting the best among multiple optimized code variants.9 '''Orio''' is an extensible annotation system, implemented in Python, that aims at improving both performance and productivity by enabling software developers to insert annotations into their source code (in C language) that trigger a number of low-level performance optimizations on a specified code fragment. The tool generates many tuned versions of the same operation using different optimization parameters, and performs an empirical search for selecting the best among multiple optimized code variants. 10 10 11 11 == Download == … … 72 72 [[BR]][[BR]] 73 73 74 As the simplest case, Orio can be used to speed up code performance by performing a ''source-to-source transformation'' such as loop unrolling and memory alignment optimizations. First, Orio takes a C /C++code as input, which contains syntactically structured comments utilized to express various performance-tuning directives. Orio scans the annotated input code and extracts all annotation regions. Each annotation region is then passed to the code transformation modules for potential optimizations. Next, the code generator produces the final code with various optimizations being applied.74 As the simplest case, Orio can be used to speed up code performance by performing a ''source-to-source transformation'' such as loop unrolling and memory alignment optimizations. First, Orio takes a C code as input, which contains syntactically structured comments utilized to express various performance-tuning directives. Orio scans the annotated input code and extracts all annotation regions. Each annotation region is then passed to the code transformation modules for potential optimizations. Next, the code generator produces the final code with various optimizations being applied. 75 75 76 76 Furthermore, Orio can also be used as an ''automatic performance tuning'' tool. The system uses its code transformation modules and code generator to generate an optimized code version for each distinct combination of performance parameters. And then, the optimized code version is empirically executed and measured for its performance, which is subsequently compared to the performances of other previously tested code variants. After iteratively evaluating all code variants under consideration, the best-performing code is generated as the final output of Orio. … … 86 86 === Annotation Language Syntax === 87 87 88 Orio annotation is denoted as a stylized C /C++comment that starts with '`/*@`' and ends with `@*/`. For instance, the annotation `/*@ end @*/` is used to indicate the end of an annotated code region. The following simple grammar illustrates the fundamental structure of Orio annotations.88 Orio annotation is denoted as a stylized C comment that starts with '`/*@`' and ends with `@*/`. For instance, the annotation `/*@ end @*/` is used to indicate the end of an annotated code region. The following simple grammar illustrates the fundamental structure of Orio annotations. 89 89 90 90 <annotation-region> ::= <leader-annotation> <annotation-body> <trailer-annotation> [[BR]] … … 92 92 <trailer-annotation> ::= `/*@ end @*/` [[BR]] 93 93 94 An ''annotation region'' consists of three main parts: ''leader annotation'', ''annotation body'', and ''trailer annotation''. The annotation body can either be empty or contain C /C++code that may include other nested annotation regions. A leader annotation contains the ''module name'' of the code transformation component that is loaded dynamically by Orio. A high level abstraction of the computation and the performance hints are coded in the ''module body'' inside the leader annotation and are used as input by the transformation module during the transformation and code generation phases. A trailer annotation, which has a fixed form (i.e. `/*@ end @*/`), closes an annotation region.94 An ''annotation region'' consists of three main parts: ''leader annotation'', ''annotation body'', and ''trailer annotation''. The annotation body can either be empty or contain C code that may include other nested annotation regions. A leader annotation contains the ''module name'' of the code transformation component that is loaded dynamically by Orio. A high level abstraction of the computation and the performance hints are coded in the ''module body'' inside the leader annotation and are used as input by the transformation module during the transformation and code generation phases. A trailer annotation, which has a fixed form (i.e. `/*@ end @*/`), closes an annotation region. 95 95 96 96 A concrete example of an annotated application code can be seen in the next subsection.