Would like some clarification on the usage of the 0 - 5 levels.
So how do you select Zero to Five for Output settings under Options Menu & how do they fit in with the statements below?
These below are taken from the Program Help
Output settings
By modifying Output Settings, user can configure the content of the output files.
You can enable or disable, for example, generation of ASM and List file.
Also, user can choose optimization level, and compiler specific settings,
which include case sensitivity, dynamic link for string literals setting
(described in mikroPascal PRO for AVR specifics).
Build all files as library enables user to use compiled library (*.mcl) on any AVR MCU.
Code Optimization
Optimizer has been added to extend the compiler usability, cut down the amount of code generated and speed-up its execution. The main features are:
Constant folding
All expressions that can be evaluated in the compile time (i.e. are constant) are being replaced by their results. (3 + 5 -> 7);
Constant propagation
When a constant value is being assigned to a certain variable, the compiler recognizes this and replaces the use of the variable by constant in the code that follows, as long as the value of a variable remains unchanged.
Copy propagation
The compiler recognizes that two variables have the same value and eliminates one of them
further in the code.
Value numbering
The compiler "recognizes" if two expressions yield the same result and can therefore
eliminate the entire computation for one of them.
"Dead code" ellimination
The code snippets that are not being used elsewhere in the programme do not affect the
final result of the application. They are automatically removed.
Stack allocation
Temporary registers ("Stacks") are being used more rationally, allowing VERY complex expressions to be evaluated with a minimum stack consumption.
Local vars optimization
No local variables are being used if their result does not affect some of the global or volatile variables.
Better code generation and local optimization
Code generation is more consistent and more attention is payed to implement specific solutions for the code "building bricks" that further reduce output code size.
Ken