blapcb
Full Member level 3
- Joined
- Jan 7, 2007
- Messages
- 188
- Helped
- 2
- Reputation
- 4
- Reaction score
- 0
- Trophy points
- 1,296
- Location
- Planet earth (most of the time)
- Activity points
- 2,766
Which compiler optimizations are "safe" and which are "dangerous"?
It is very easy to hit "High" on the compiler optimization options and it will definitely reduce code. However, it can also lead to unexpected results (or so I understand) if certain coding techniques are not followed.
My question is, are there any specific optimization options ("transformations") that are considered "safe" (i.e. not expected to introduce any risk) and others that are considered "risky"?
PS - I am using IAR Embedded Workbench for MSP430
Thanks
It is very easy to hit "High" on the compiler optimization options and it will definitely reduce code. However, it can also lead to unexpected results (or so I understand) if certain coding techniques are not followed.
My question is, are there any specific optimization options ("transformations") that are considered "safe" (i.e. not expected to introduce any risk) and others that are considered "risky"?
PS - I am using IAR Embedded Workbench for MSP430
Thanks