Skip to content

decoder: Define exception to raise when an undefined / illegal instruction is detected #969

Description

@AndreasKrall

Currently it is not possible to define what happens when an undefined / illegal instruction is detected. To define such a behavior an annotation to an exception definition should be defined which specifies that this exception is raised when the decoder has no valid decode. The suggested name is [illegal instruction].

[illegal instruction]
exception UndefinedInstruction () = {
  $GeneralException (ExceptionClass::Uncategorized, 0, PC, 0)
}

I suggest that the decoder generator gives an error, when no exception is defined for hardware generation. For simulator generation the definition of an exception should be optional, but if an exception with the annotation [illegal instruction] is available, the behavior defined in the exception is executed and the simulator does not raise a simulator exception.

Metadata

Metadata

Labels

enhancementNew feature or requestfrontendThis is frontend relatedhardwareRelated to the MiA and hardware generationissThis is ISS related

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions