a34dd8040ced3a7f97f4e3f8deac64f9529f982e
[riscv-isa-sim.git] / riscv / extension.cc
1 // See LICENSE for license details.
2
3 #include "extension.h"
4 #include "trap.h"
5
6 extension_t::~extension_t()
7 {
8 }
9
10 void extension_t::illegal_instruction()
11 {
12 throw trap_illegal_instruction();
13 }
14
15 void extension_t::raise_interrupt()
16 {
17 p->take_interrupt((reg_t)1 << IRQ_COP); // must not return
18 throw std::logic_error("a COP exception was posted, but interrupts are disabled!");
19 }
20
21 void extension_t::clear_interrupt()
22 {
23 }