diff options
author | James Clarke <jrtc27@jrtc27.com> | 2019-12-23 19:44:11 +0000 |
---|---|---|
committer | James Clarke <jrtc27@jrtc27.com> | 2019-12-23 19:52:50 +0000 |
commit | dd0f51d1d681b92348e56abe2e20aac11dfda130 (patch) | |
tree | e235cf442ddf0525d73409a6bb46d5497a5e7e26 /model/riscv_fetch.sail | |
parent | 9ebfc467a2f9251f165494ebbedb83e0cb432fa9 (diff) | |
download | sail-riscv-dd0f51d1d681b92348e56abe2e20aac11dfda130.zip sail-riscv-dd0f51d1d681b92348e56abe2e20aac11dfda130.tar.gz sail-riscv-dd0f51d1d681b92348e56abe2e20aac11dfda130.tar.bz2 |
Remove hard-coded E_Fetch_Access_Fault now mem_read checks the type
Diffstat (limited to 'model/riscv_fetch.sail')
-rw-r--r-- | model/riscv_fetch.sail | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/model/riscv_fetch.sail b/model/riscv_fetch.sail index d091756..cdda96e 100644 --- a/model/riscv_fetch.sail +++ b/model/riscv_fetch.sail @@ -22,7 +22,7 @@ function fetch() -> FetchResult = * exceptions. */ match mem_read(Execute(), ppclo, 2, false, false, false) { - MemException(e) => F_Error(E_Fetch_Access_Fault(), PC), + MemException(e) => F_Error(e, PC), MemValue(ilo) => { if isRVC(ilo) then F_RVC(ilo) @@ -36,7 +36,7 @@ function fetch() -> FetchResult = TR_Failure(e, _) => F_Error(e, PC_hi), TR_Address(ppchi, _) => { match mem_read(Execute(), ppchi, 2, false, false, false) { - MemException(e) => F_Error(E_Fetch_Access_Fault(), PC_hi), + MemException(e) => F_Error(e, PC_hi), MemValue(ihi) => F_Base(append(ihi, ilo)) } } |