There are many changes since v0.50.1, which has been used for toolchain, spike, qemu and the CV32E41P implementation.
The status of all of the instructions are in the tables. Note that all subsets have been redefined.
v0.50 name | v0.70 Name | Encoding changed? | Semantics changed? | Notes |
---|---|---|---|---|
C.LB |
CM.LB |
Y |
N |
uimm < 4 is "custom defined" |
C.LBU |
CM.LBU |
Y |
N |
uimm < 4 is "custom defined" |
C.LH |
CM.LH |
Y |
N |
uimm < 4 is "custom defined" |
C.LHU |
CM.LHU |
Y |
N |
uimm < 4 is "custom defined" |
C.SB |
CM.SB |
Y |
N |
uimm < 4 is "custom defined" |
C.SH |
CM.SH |
Y |
N |
uimm < 4 is "custom defined" |
N/A |
C.LBU |
N/A |
N/A |
CM.LBU with shorter uimm |
N/A |
C.LH |
N/A |
N/A |
CM.LH with shorter uimm |
N/A |
C.LHU |
N/A |
N/A |
CM.LHU with shorter uimm |
N/A |
C.SB |
N/A |
N/A |
CM.SB with shorter uimm |
N/A |
C.SH |
N/A |
N/A |
CM.SH with shorter uimm |
v0.50 name | v0.70 Name | Encoding changed? | Semantics changed? | Notes |
---|---|---|---|---|
C.TBLJAL |
CM.JALT |
Y |
Y - exception model |
Meaning of table index changed in the encoding, # removed from assembly syntax |
C.TBLJ |
CM.J |
Y |
Y - exception model |
Meaning of table index changed in the encoding, # removed from assembly syntax |
C.TBLJALM |
N/A |
N/A |
N/A |
Deleted |
See this [commit](https://github.com/riscv/riscv-code-size-reduction/commit/8ba5b0fdf05d6fd5af118ba5301910d049abd1a8#diff-8d03bd23cf9ec0eb75984f7c6d4181aa9548acb5898dc9159514e24398076836) for the change in the table jump exception model.
v0.50 name | v0.70 Name | Encoding changed? | Semantics changed? | Notes |
---|---|---|---|---|
C.MVA01S07 |
CM.MVA01S |
Y |
N |
|
N/A |
CM.MVSA01 |
N/A |
N/A |
New instruction |
Note that the .E extension versions for the EABI will be specified in the future, and cannot yet be confirmed as the EABI is not frozen.
v0.50 name | v0.70 Name | Encoding changed? | Semantics changed? | Notes |
---|---|---|---|---|
C.ZEXT.B |
same |
Y |
N |
|
C.ZEXT.H |
same |
Y |
N |
|
C.SEXT.B |
same |
Y |
N |
|
C.SEXT.H |
same |
Y |
N |
|
C.SEXT.W |
same |
Y |
N |
|
C.NOT |
same |
Y |
N |
|
C.MUL |
same |
N |
N |
unchanged |
All 32-bit forms are removed and all the 16-bit forms support 12 register lists (excluding {ra, s0-s10}):
-
{ra}
-
{ra, s0}
-
{ra, s0-s1}
-
{ra, s0-s2}
-
{ra, s0-s3}
-
{ra, s0-s4}
-
{ra, s0-s5}
-
{ra, s0-s6}
-
{ra, s0-s7}
-
{ra, s0-s8}
-
{ra, s0-s9}
-
{ra, s0-s11}
spimm length also updated.
Note that the .E extension versions for the EABI will be specified in the future, and cannot yet be confirmed as the EABI is not frozen.
v0.50 name | v0.70 Name | Encoding changed? | Semantics changed? | Notes |
---|---|---|---|---|
C.PUSH |
CM.PUSH |
Y |
Y |
areg_list no longer supported |
C.POP |
CM.POP |
Y |
Y |
|
C.POPRET |
CM.POPRET |
Y |
Y |
CM.POPRET doesn’t return a value |
C.POPRET |
CM.POPRETZ |
Y |
Y |
separate encoding for return zero |
These instructions can be left in the compiler as experimental, enabled with the following switches:
Switch | Enabled instructions |
---|---|
-mzce-lsgp |
LWGP, SWGP, LDGP (RV64), SDGP (RV64) |
-mzce-muli |
MULI |
-mzce-beqi |
BEQI |
-mzce-bnei |
BNEI |
-mzce-cdecbnez |
C.DECBNEZ |
-mzce-decbnez |
DECBNEZ |
C.DECBNEZ - the encoding space for this has been used by all the CM.* instructions. Therefore this instruction must be disabled in the compiler - unless an encoding is proposed.
C.NEG - this is not very useful and can be deleted.
MULI - This is in custom-0, so can be kept unchanged. Early benchmarking results suggest it’s not much use, and the encoding is expensive so it’s unlikely to ever be included in an extension.
BEQI, BNEI - these fill in the 2 gaps in the BRANCH encoding group - these encodings have not been allocated to other instructions, so these can stay unchanged
DECBNEZ - this should be updated to match https://github.com/riscv/riscv-code-size-reduction/blob/master/Zce-release-candidate/Zcmd.pdf
LWGP, SWGP, LDGP, SDGP - these overlap with C.FLD, C.FSD
PUSH/POP/POPRET - delete all of these