This is usually an indication that your code is running away.
When it stops and gives this error, the program counter will probably not be in the area of memory where your program is placed.
Assuming you are compiling or assembling code and downloading into the part then the most likely cause of this problem is an interrupt that is not trapped or a table jump that doesn't go where you expect.