32#ifndef __ARCH_RISCV_FAULTS_HH__
33#define __ARCH_RISCV_FAULTS_HH__
245 :
InstFault(
"Illegal instruction", inst),
259 :
InstFault(
"Unimplemented instruction", inst),
273 :
InstFault(
"Illegal floating-point rounding mode", inst),
325 panic(
"Unknown privilege mode %d.", prv);
RegVal trap_value() const override
AddressFault(const Addr addr, ExceptionCode code)
BreakpointFault(const PCStateBase &pc)
void invokeSE(ThreadContext *tc, const StaticInstPtr &inst) override
RegVal trap_value() const override
void invokeSE(ThreadContext *tc, const StaticInstPtr &inst) override
IllegalFrmFault(uint8_t r, const ExtMachInst inst)
void invokeSE(ThreadContext *tc, const StaticInstPtr &inst) override
IllegalInstFault(std::string r, const ExtMachInst inst)
RegVal trap_value() const override
InstFault(FaultName n, const ExtMachInst inst)
InterruptFault(ExceptionCode c)
NonMaskableInterruptFault()
void invoke(ThreadContext *tc, const StaticInstPtr &inst=nullStaticInstPtr) override
FaultName name() const override
RiscvFault(FaultName n, FaultType ft, ExceptionCode c)
virtual void invokeSE(ThreadContext *tc, const StaticInstPtr &inst)
ExceptionCode exception() const
const FaultType _fault_type
void invoke(ThreadContext *tc, const StaticInstPtr &inst) override
FaultName name() const override
bool isNonMaskableInterrupt() const
virtual RegVal trap_value() const
void invokeSE(ThreadContext *tc, const StaticInstPtr &inst) override
SyscallFault(PrivilegeMode prv)
const std::string instName
void invokeSE(ThreadContext *tc, const StaticInstPtr &inst) override
UnimplementedFault(std::string name, const ExtMachInst inst)
UnknownInstFault(const ExtMachInst inst)
void invokeSE(ThreadContext *tc, const StaticInstPtr &inst) override
ThreadContext is the external interface to all thread state for anything outside of the CPU.
#define panic(...)
This implements a cprintf based panic() function.
bool getFaultVAddr(Fault fault, Addr &va)
Returns true if the fault passed as a first argument was triggered by a memory access,...
Copyright (c) 2024 - Pranith Kumar Copyright (c) 2020 Inria All rights reserved.
std::shared_ptr< FaultBase > Fault
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
const StaticInstPtr nullStaticInstPtr
Statically allocated null StaticInstPtr.