general comment on optimiser pulling out variables

Beta Testing discussion on mikroC PRO for PIC.
Post Reply
Author
Message
Mince-n-Tatties
Posts: 2780
Joined: 25 Dec 2008 15:22
Location: Scotland

general comment on optimiser pulling out variables

#1 Post by Mince-n-Tatties » 06 Jul 2011 22:39

First of all, so far for me release 5.00 is looking like an extraordinarily well polished product. The response turn-around time by the mE team to questions from forum members is also lightning fast.

a general observation & comment about the optimiser (not limited to version 5.00)...

it is often the case that unused variables are silently removed by the optimiser. obviously the least i would expect of the optimiser is to remove unused variables however there looks to be a problem of consistency in the reporting process. Sometimes there is a nice clear warning feedback, something along the lines of "variable x not used removed by optimiser" yet more often than not there is no feedback at all. From my memory sometimes it is reported "variable declared but not used" again this does not appear to be consistent

on the topic of unused variables, it would be my preference to be warned by the optimiser/compiler.

note: i have only tested with default optimiser level four setting.
Best Regards

Mince

User avatar
zristic
mikroElektronika team
Posts: 6608
Joined: 03 Aug 2004 12:59
Contact:

Re: general comment on optimiser pulling out variables

#2 Post by zristic » 11 Jul 2011 09:36

I have read few times this post before trying to answer, but I am still not sure what to say.
It would be great that you give us one very little example of what is confusing you, because there are some possible explanations. Before I take any out of the sleeve, please show me what you mean exactly.
Thanks.

Post Reply

Return to “mikroC PRO for PIC Beta Testing”