-
Notifications
You must be signed in to change notification settings - Fork 0
/
encoding.txt
21 lines (19 loc) · 2.09 KB
/
encoding.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
+=====================+======================+==========+=====================+=========+=============+
| class | instruction | format | f7 | f3 | custom |
+=====================+======================+==========+=====================+=========+=============+
| | | | | | |
| ELEPHANT_RV32_TYPE2 | elephant.pstep.x | 2R+I->1R | 0000 : imm3 | 7 = 111 | 0 = 0001011 |
| ELEPHANT_RV32_TYPE2 | elephant.pstep.y | 2R+I->1R | 0001 : imm3 | 7 = 111 | 0 = 0001011 |
| | | | | | |
| ELEPHANT_RV32_TYPE2 | elephant.sstep | 1R ->1R | 0010 : imm3 | 6 = 110 | 0 = 0001011 |
| | | | | | |
+=====================+======================+==========+=====================+=========+=============+
.macro elephant.pstep.x rd, rs1, rs2, imm // elephant.pstep.x => 0000 iiir rrrr rrrr r111 rrrr r000 1011
.insn r CUSTOM_0, 7, \imm+( 0* 8), \rd, \rs1, \rs2 // => #define MATCH_ELEPHANT_PSTEP_X 0x0000700B
.endm // => #define MASK_ELEPHANT_PSTEP_X 0xF000707F
.macro elephant.pstep.y rd, rs1, rs2, imm // elephant.pstep.y => 0001 iiir rrrr rrrr r111 rrrr r000 1011
.insn r CUSTOM_0, 7, \imm+( 1* 8), \rd, \rs1, \rs2 // => #define MATCH_ELEPHANT_PSTEP_Y 0x1000700B
.endm // => #define MASK_ELEPHANT_PSTEP_Y 0xF000707F
.macro elephant.sstep rd, rs1 // elephant.sstep => 0010 iiir rrrr rrrr r110 rrrr r000 1011
.insn r CUSTOM_0, 6, ( 2* 8), \rd, \rs1, x0 // => #define MATCH_ELEPHANT_SSTEP 0x2000600B
.endm // => #define MASK_ELEPHANT_SSTEP 0xF000707F