User Tools

Site Tools



This shows you the differences between two versions of the page.

Link to this comparison view

code_gen_options [2014/05/30 11:49] (current)
Line 1: Line 1:
 +There are a number of options to the AlphaZ ScheduledC code generator, for example, we can choose to allocate a multi-dimensional array as a one dimensional array or not. 
 +To configure options to be used by the code generator, an instance of an CodeGenOptions object must be created first using the following commands.
 +<code perl>
 +options = createCGOptionForScheduledC();​
 +Another command is used to set up the array flatten option
 +<code perl>
 +# Multi-dimensional arrays are allocated as a one-dimensional array when flatten option is not zero
 +setCGOptionFlattenArrays(CodeGenOptions option, int flatten)
 +There are options specific for tiled code, so if we want to generate tiled code using ScheduledC, we must create an instance of the TiledCodeGenOptions.
 +TiledCodeGenOptions extends CodeGenOptions,​ and thus it can be used in place of CodeGenOptions as well. The command is the following
 +<code perl>
 +toptions = createTiledCGOptionForScheduledC();​
 +The tiled code generator provides an optimization that it can select one group of statements and isolate it. The command used to set this optimization up is 
 +<code perl>
 +# When optimize is not zero, the tiled code generator selects one group of statements to isolate.
 +setTiledCGOptionOptimize(TiledCodeGenOptions option, int optimize)
code_gen_options.txt ยท Last modified: 2014/05/30 11:49 (external edit)