Defined illegal instruction

Peter Bergner bergner@linux.ibm.com
Fri Feb 9 17:21:19 GMT 2024


On 2/9/24 11:03 AM, jacob navia wrote:
> The riscv processor defines an illegal instruction (all zeroes). I do not 
> find the mnemonic used by gas for this. As far as I remember, the x86 also
> has a defined illegal instruction.

I can't speak for riscv or x86, but Power also defines a 32-bit all zero
instruction as an illegal instruction.  We do not have a mnemonic for it
though.  When we want to emit that into the instruction stream, we just
emit a ".long 0" assembler directive.  Maybe the other architectures do
the same thing?

Peter



More information about the Binutils mailing list