AnsweredAssumed Answered

register problem

Question asked by xiaobo zheng on Jun 21, 2017
Latest reply on Jun 26, 2017 by Martin Kovar

Hello :

 we want to load mcsr register to general register(r25) ,  and then transmit r25 to a local variable.

__attribute__((section(".srec_rom"))) // richard help
void fn_Srec_EccErrorHandler(void)
{  
    register  unsigned long mcsr __asm("r25") ;
 __asm("mfspr r25,572 ");

 if ((mcsr&0x000000ff)==11)
 {
  ;
 }else{
  ;
 }

}

why this can not be compiled?  

Outcomes