diff options
author | Rupert Swarbrick <rswarbrick@gmail.com> | 2022-03-11 21:44:54 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-11 13:44:54 -0800 |
commit | 59ec157568d2a52feeec568ac042362db1c5ddbc (patch) | |
tree | 802e4fd68f756a543b02bf763d029051f4404fc7 /riscv/processor.h | |
parent | 29dca8b846250a015e84b36e40f4bd1b57bf55fa (diff) | |
download | spike-59ec157568d2a52feeec568ac042362db1c5ddbc.zip spike-59ec157568d2a52feeec568ac042362db1c5ddbc.tar.gz spike-59ec157568d2a52feeec568ac042362db1c5ddbc.tar.bz2 |
Incorporate supported privilege levels into isa_parser_t (#940)
These affect the "max_isa" value (now exposed as get_max_isa()) and
feel like they're similar to the other computations done in
isa_parser_t.
Diffstat (limited to 'riscv/processor.h')
-rw-r--r-- | riscv/processor.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/riscv/processor.h b/riscv/processor.h index 05c55ce..2fe5ede 100644 --- a/riscv/processor.h +++ b/riscv/processor.h @@ -311,9 +311,10 @@ static int cto(reg_t val) class isa_parser_t { public: - isa_parser_t(const char* str); + isa_parser_t(const char* str, const char *priv); ~isa_parser_t(){}; unsigned get_max_xlen() const { return max_xlen; } + reg_t get_max_isa() const { return max_isa; } std::string get_isa_string() const { return isa_string; } bool extension_enabled(unsigned char ext) const { if (ext >= 'A' && ext <= 'Z') |