compiler lock up "internal error #413 please report to metrowerks"

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

compiler lock up "internal error #413 please report to metrowerks"

2,416 Views
jah
Contributor I
i have the following compiler for the mc9s08rd60dwe
codewarrior development studio for freescale hc(s)083.1 service pk fsicebase ver2

running on win xp + sp2


in a working and established main.c i add the code "while(1);"



and the compiler locks up and will not complete, it compiles w/o the while statement, and this code is used in several of our products for a year. i am using the while statement as a debug aid. the code does odd things when i place it in other areas of the code but it compiles. in the building screen (i only selected the compile icon) the Stop button has no effect?
Labels (1)
0 Kudos
Reply
7 Replies

641 Views
jah
Contributor I
i might also add if i add the following to main.c
int i=1;
while(i);



the compiler takes the statement ok w/o error.
0 Kudos
Reply

641 Views
bigmac
Specialist III
Hello Jah,
 
I have previously gotten a compiler warning when using the while(1)... construct, but not compiler lockup.  So I substituted the for( ; ; )... construct and this avoided the warning.  I wonder if the compiler does not like there being nothing done within the infinite loop - I actually had some code within the loop.
 
Regards,
Mac
 
0 Kudos
Reply

641 Views
jah
Contributor I
for( ; ; )

did not work but

while(true==1)

did work

rough and wooly compiler

Message Edited by jah on 2006-09-15 09:33 AM

0 Kudos
Reply

641 Views
bigmac
Specialist III
Hello jah,
 
I am most surprised that the for() loop construct did not work, since this is used by the CW generated, default main() function, whenever a new project is created.  There has to be another reason.  As a matter of curiosity, what error or warning do you get for this method?
 
I guess that while(true==1) would be the same as writing while(1==1).
 
Regards,
Mac
 
0 Kudos
Reply

641 Views
jah
Contributor I
yes the for( ; ; ) did not work but the while(j==0) or while(true==1) works. in some of my other builds there is no error so down stream in the code there is some small black spot that triggers this.

i get "internal error #413" and some reference to a missing glbreg.c file on an F: drive. i never had a F: drive, nor do i want one.

is this only on codewarrior 3.0 and fixed on 5.0????

Message Edited by jah on 2006-09-15 10:50 AM

0 Kudos
Reply

641 Views
rocco
Senior Contributor II
Hi, jah:

What are your optimization settings? Have you tried turning optimizations off?

It could be that CodeWarrior is having problems while optimizing, and the code optimizes to nothing.
0 Kudos
Reply

641 Views
jah
Contributor I
the while(1) causes the compiler is trying to remove dead code and gets into problems.

where is the adj for the compiler.
0 Kudos
Reply