Skip to content

Commit cfd989c

Browse files
committed
docs: add misa q bit, add MUTABLE_MISA_Q parameter to Q extension
1 parent ae741a1 commit cfd989c

File tree

2 files changed

+29
-0
lines changed

2 files changed

+29
-0
lines changed

arch/csr/misa.yaml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,29 @@ fields:
169169
.. Execute every in-scope multiply extension instruction
170170
. check
171171
.. Check that every multiply extension instruction throws illegal instruction exception
172+
Q:
173+
location: 16
174+
description: |
175+
Indicates support for the `Q` (quad precision float) extension.
176+
177+
[when,"MUTABLE_MISA_Q == true"]
178+
--
179+
Indicates support for the `Q` (quad precision float) extension.
180+
--
181+
type(): |
182+
return (implemented?(ExtensionName::Q) && MUTABLE_MISA_Q) ? CsrFieldType::RW : CsrFieldType::RO;
183+
reset_value(): |
184+
return implemented?(ExtensionName::Q) ? 1 : 0;
185+
definedBy: Q
186+
sw_write(csr_value): |
187+
if (csr_value.Q == 0) {
188+
return UNDEFINED_LEGAL_DETERMINISTIC;
189+
}
190+
191+
# fall-through; write the intended value
192+
return csr_value.Q;
193+
legal?(csr_value): |
194+
return !(csr_value.Q == 0);
172195
S:
173196
location: 18
174197
description: |

arch/ext/Q.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,9 @@ versions:
1818
state: ratified
1919
ratification_date: null
2020
requires: D
21+
params:
22+
MUTABLE_MISA_Q:
23+
description: |
24+
Indicates whether or not the `Q` extension can be disabled with the `misa.Q` bit.
25+
schema:
26+
type: boolean

0 commit comments

Comments
 (0)