Addison Mayberry

IAR Inline Assembly Error

Discussion created by Addison Mayberry on Jul 19, 2012
I just upgraded to the latest version of IAR Kickstart (code-limited). When I tried recompiling my code (which includes a lot of inline assembly), I got a large number of errors where there were none before. I found the issue, and reproduced it in the simple program below:  

int main()
{  
      asm("test_label:\n");
      asm("jmp test_label\n");
      return 0;


This generates two errors on the second asm line, saying: "Unknown symbol in inline assembly: 'test_label'", and "Syntax error in inline assembly: 'Error[54]: Expression can not be forward.'" I'm really surprised, as this code follows all the conventions as far as I know. Any thoughts on what could be going on?

Outcomes