Hi there,
My concern is this.
For example:
TR0 = 0; // reset the timer
while( TR0 == 0 ); // wait for the flag to be set.
i++; // get out of the loop and increment
}
What is SDCC going to do in this case.
Will it say that line corr. to "i++" as unreachable code.
But how does the compiler know that?
Regards,
Vineet.
On 3/22/07, Jean-Paul <[EMAIL PROTECTED]> wrote:
Le Mercredi 21 Mars 2007 16:15, Vineet Golchha a écrit:
> Hello group,
> Have recently started using the SDCC compiler for 8051 controllers.
> I found two warnings coming up when I compile the code.
>
> 1. warning 126 : unreachable code.
> 2. warning 59 : conditional flow changed by optimizer.
>
> Queries:
>
> 1.Can anyone tell me what this means?
1. For example, if you write :
while (1 < 0)
{
try_this_one();
...
}
then you'll never have a chance to try_this_one().
> 2.Also can they be ignored?
It's up to you.
Regards
Jean-Paul
>
>
> Best Regards,
> Vineet.
--
Never jump into a loop!
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share
your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Sdcc-user mailing list
Sdcc-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sdcc-user
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Sdcc-user mailing list
Sdcc-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sdcc-user