diff options
author | Scott Johnson <scott.johnson@arilinc.com> | 2021-11-13 08:54:24 -0800 |
---|---|---|
committer | Scott Johnson <scott.johnson@arilinc.com> | 2021-11-13 08:54:24 -0800 |
commit | d3d526b85341b810e1a8be846f8437c3afd5fafe (patch) | |
tree | c006e53d1e5b5aa3585249422ab11e850c4f2a28 /riscv/csrs.h | |
parent | 37807bca031e173436464f5b9aa3967709906e5b (diff) | |
download | spike-d3d526b85341b810e1a8be846f8437c3afd5fafe.zip spike-d3d526b85341b810e1a8be846f8437c3afd5fafe.tar.gz spike-d3d526b85341b810e1a8be846f8437c3afd5fafe.tar.bz2 |
Mask hideleg by mideleg
According to spec clarification:
https://github.com/riscv/riscv-isa-manual/pull/771
This has no functional effect today, because all the active bits of
hideleg are tied to 1 inside mideleg.
Diffstat (limited to 'riscv/csrs.h')
-rw-r--r-- | riscv/csrs.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/riscv/csrs.h b/riscv/csrs.h index cf63d4d..6e218db 100644 --- a/riscv/csrs.h +++ b/riscv/csrs.h @@ -511,6 +511,15 @@ class hypervisor_csr_t: public basic_csr_t { }; +class hideleg_csr_t: public masked_csr_t { + public: + hideleg_csr_t(processor_t* const proc, const reg_t addr, csr_t_p mideleg); + virtual reg_t read() const noexcept override; + private: + csr_t_p mideleg; +}; + + class hgatp_csr_t: public basic_csr_t { public: hgatp_csr_t(processor_t* const proc, const reg_t addr); |