Tool News
 
 
 

Tool News

Products Info
Downloads
Tools FAQs
MESC TOOL NEWS: MESCT-NC308WA-000501D

PC-Version
NC308WA, NC30WA, NC79WA, NC77WA
Precautions

Please take note of the following problem in using C compilers (with assembler and integrated development environment) NC308WA, NC30WA, NC79WA, and NC77WA:


  1. Versions Concerned
    The following PC versions of C compilers are concerned in this problem:
    NC308WA V.1.00 Release 1--V.2.00 Release 2for M16C/80 series MCUs
    NC30WA V.1.00 Release 1--V.3.20 Release 2for M16C/60 and M16C/20 series MCUs
    NC79WA V.1.00 Release 1--V.3.20 Release 2for 7900 series MCUs
    NC77WA V.3.00 Release 1--V.5.20 Release 2for 77xx series MCUs


  2. Problem
    If an optimize option is used, Windows' error message "This program has performed an illegal operation . . . ." may appear.

  3. Conditions
    This problem occur if the following three conditions are satisfied:
    (1)Any of optimize options -O, -O1 through -O5, -OR, and -OS is chosen.
    (2)The branch instruction is described in C language.[Example 1]
    (3)An unconditional branch instruction exists in the assembly source file obtained by compiling the C source program and is immediately followed by its branch destination.[Example 2]
    [Example 1: C Source Program]
    -------------------------------------------------------------
     void func(void)
     {
         unsigned char    i;
    
         for (i=0;i<2;i++){
             if (i==0) return;
                 switch(i){
                     case 1: 
                         return;
                     case 2:
                          return;
                     default:
                          func2();
                          return;  /* Here the error message may appear */
                 }
         }
     }
    -------------------------------------------------------------
    
    In this example, using optimize option -O may cause the problem to occur; if not, the problem will not arise.
    [Example 2: Assembly Source]
    -------------------------------------------------------------
          bra  L1
     L1:
    -------------------------------------------------------------
    
    Even if the above conditions are all satisfied, no error may be detected depending on how the C compiler performs the optimize processing, and no error indicates no problem.

  4. Workaround
    Don't use any of optimize options -O, -O1 through -O5, -OR, and -OS.

  5. Schedule of Fixing Problem
    We plan to fix this problem in our next release.




© 2008. Renesas Technology Corp., All rights reserved. Privacy | Legal