Skip to content

Commit

Permalink
C.ADDIW cannot have an rd of 0
Browse files Browse the repository at this point in the history
The code point of rd=0 in C.ADDIW is restricted.

Fix formatting while in these files.

Signed-off-by: Charlie Jenkins <[email protected]>
  • Loading branch information
charlie-rivos committed Sep 16, 2023
1 parent d752f19 commit 8759844
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
6 changes: 2 additions & 4 deletions rv64_c
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,13 @@ c.ld rd_p rs1_p c_uimm8lo c_uimm8hi 1..0=0 15..13=3
c.sd rs1_p rs2_p c_uimm8hi c_uimm8lo 1..0=0 15..13=7

#quadrant 1
c.addiw rd_rs1 c_imm6lo c_imm6hi 1..0=1 15..13=1
c.addiw rd_rs1_n0 c_imm6lo c_imm6hi 1..0=1 15..13=1
c.srli rd_rs1_p c_nzuimm6lo c_nzuimm6hi 1..0=1 15..13=4 11..10=0
c.srai rd_rs1_p c_nzuimm6lo c_nzuimm6hi 1..0=1 15..13=4 11..10=1
c.subw rd_rs1_p rs2_p 1..0=1 15..13=4 12..10=0b111 6..5=0
c.addw rd_rs1_p rs2_p 1..0=1 15..13=4 12..10=0b111 6..5=1


#quadrant 2
c.slli rd_rs1_n0 c_nzuimm6hi c_nzuimm6lo 1..0=2 15..13=0
c.ldsp rd_n0 c_uimm9sphi c_uimm9splo 1..0=2 15..13=3
c.sdsp c_rs2 c_uimm9sp_s 1..0=2 15..13=7

c.sdsp c_rs2 c_uimm9sp_s 1..0=2 15..13=7
5 changes: 2 additions & 3 deletions unratified/rv128_c
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,10 @@ c.sq rs1_p rs2_p c_uimm9hi c_uimm9lo 1..0=0 15..13=5
c.sd rs1_p rs2_p c_uimm8hi c_uimm8lo 1..0=0 15..13=7

#quadrant 1
c.addiw rd_rs1 c_imm6lo c_imm6hi 1..0=1 15..13=1
c.addiw rd_rs1_n0 c_imm6lo c_imm6hi 1..0=1 15..13=1

#quadrant 2
c.lqsp rd c_uimm10sphi c_uimm10splo 1..0=2 15..13=1
c.ldsp rd_n0 c_uimm9sphi c_uimm9splo 1..0=2 15..13=3
c.ldsp rd_n0 c_uimm9sphi c_uimm9splo 1..0=2 15..13=3
c.sqsp c_rs2 c_uimm10sp_s 1..0=2 15..13=5
c.sdsp c_rs2 c_uimm9sp_s 1..0=2 15..13=7

0 comments on commit 8759844

Please sign in to comment.