BIRISCV core is throwing the exception “0x02: Illegal Instruction” when it executes compiler/assembler generated instructions with GP suffix.
Here is firmware log where it detected the 0x02 exception:
In this case, when program counter reaches to the instruction ‘lwgp’:
The core raises the 0x02 exception:
It is to be noted that, the startup assembly file and the Makefile are configured correctly to define __global_pointer.
The following flag disables the GP usage, but results in worse code density:
Is LWGP supported by BIRISCV?
BIRISCV core is throwing the exception “0x02: Illegal Instruction” when it executes compiler/assembler generated instructions with GP suffix.
Here is firmware log where it detected the 0x02 exception: In this case, when program counter reaches to the instruction ‘lwgp’: The core raises the 0x02 exception:
It is to be noted that, the startup assembly file and the Makefile are configured correctly to define __global_pointer.
The following flag disables the GP usage, but results in worse code density:
Your advise is appreciated, thanks