AnsweredAssumed Answered

Problem running code generated with CodeWarrior

Question asked by Pierre SCHMIDT on Oct 26, 2012
Latest reply on Feb 11, 2013 by Lucian Todor

Hello, I modified a project initially written for windriver diab compiler to work with Codewarrior.

 

I then ran the project with the help of cw_icdppcnexus but experienced a problem after startup when the PC goes to the main function: The PC gets 000000h which makes execution continue at a location where there is no executable code

 

So I had a look at the assembly instructions equivalency and compared the original Windriver executable file with the CodeWarrior one. Here is the result:

 

Sans titre.jpg

The window on top is the Codewarrior generated code, the second is from Windriver.

 

Codewarrior generates some extra instructions which make the PC go to 00000h due to SE_BLR instruction (LR is 00000h). After that the code looks very similar for both compilers. Is there a way to disable the generation of those extra instructions?? (does not actually know what those instructions do)

 

Thanks a lot

 

P.SCHMIDT

Outcomes