Skip to content

Commit af79247

Browse files
committed
Clarify behaviour of vstid/vstidc registers.
The specification is not completly clear on the behaviour of the vstid/c registers. Propose it should follow the behaviour of other virtual supervisor registers.
1 parent 1594796 commit af79247

File tree

1 file changed

+16
-4
lines changed

1 file changed

+16
-4
lines changed

src/tid-ext.adoc

+16-4
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,15 @@ include::img/stidreg.edn[]
7474
[#vstid,reftext="vstid"]
7575
==== Virtual Supervisor Thread Identifier (vstid)
7676

77-
The <<vstid>> register is a VSLEN-bit read-write register. It is used to
78-
identify the current thread in virtual supervisor mode. The reset value of this
77+
The <<vstid>> register is a VSLEN-bit read-write register. It is VS-mode's
78+
version of supervisor register <<stid>> used to identify the current
79+
thread in virtual supervisor mode. As other Virtual Supervisor registers
80+
when V=1, <<vstid>> substitutes for the usual <<stid>>, so that
81+
instructions that normally read or modify <<stid>> actually access
82+
<<vstid>> instead. When V=0, <<vstid>> does not directly affect the
83+
behaviour of the machine.
84+
85+
The reset value of this
7986
register is UNSPECIFIED.
8087

8188
.Virtual supervisor thread identifier register
@@ -122,8 +129,13 @@ include::img/stidcreg.edn[]
122129
==== Virtual Supervisor Thread Identifier Capability (vstidc)
123130

124131
The <<vstidc>> register is a CLEN-bit read-write capability register.
125-
It is the capability extension of the <<vstid>> register.
126-
It is used to identify the current thread in virtual supervisor mode.
132+
It is the capability extension of the <<stidc>> register used to
133+
identify the current thread in virtual supervisor mode.
134+
As other Virtual Supervisor registers when V=1, <<vstidc>> substitutes
135+
for the usual <<stidc>>, so that instructions that normally read or modify
136+
<<stidc>> actually access <<vstidc>> instead.
137+
When V=0, <<vstidc>> does not directly affect the
138+
behaviour of the machine.
127139
On reset the tag of <<vstidc>> will be set to 0 and the remainder
128140
of the data is UNSPECIFIED.
129141

0 commit comments

Comments
 (0)