Bug 409 - deal with illegal instruction in simulator and hardware
Summary: deal with illegal instruction in simulator and hardware
Alias: None
Product: Libre-SOC's first SoC
Classification: Unclassified
Component: Source Code (show other bugs)
Version: unspecified
Hardware: Other Linux
: --- enhancement
Assignee: Luke Kenneth Casson Leighton
Depends on: 415 325
Blocks: 383
  Show dependency treegraph
Reported: 2020-07-01 14:27 BST by Luke Kenneth Casson Leighton
Modified: 2021-04-20 15:08 BST (History)
1 user (show)

See Also:
NLnet milestone: NLNet.2019.10.043.Wishbone
total budget (EUR) for completion of task and all subtasks: 100
budget (EUR) for this task, excluding subtasks' budget: 100
parent task for budget allocation: 383
child tasks for budget allocation:
The table of payments (in EUR) for this task; TOML format:
"lkcl"={amount=100, paid=2020-08-21}


Note You need to log in before you can comment on or make changes to this bug.
Description Luke Kenneth Casson Leighton 2020-07-01 14:27:37 BST
from microwatt execute1.vhdl: illegal instructions need to generate a trap that sets bit 44 in SRR1

this in both ISACaller and power_decoder2

exception := '1';
v.f.redirect_nia := std_logic_vector(to_unsigned(16#700#, 64));
-- Since we aren't doing Hypervisor emulation assist (0xe40) we
-- set bit 44 to indicate we have an illegal
ctrl_tmp.srr1(63 - 44) <= '1';
report "illegal";
Comment 1 Luke Kenneth Casson Leighton 2020-07-14 16:13:56 BST
sorted.  PowerDecode2 now detects illegal instructions and sets the
instruction *to* trap, and as a result it is the TRAP pipeline that
deals with it.