1use riscu::Instruction;
2
3pub enum SyscallId {
4 Exit = 93,
5 Read = 63,
6 Write = 64,
7 Openat = 56,
8 Brk = 214,
9}
10
11pub const fn instruction_to_str(i: Instruction) -> &'static str {
12 match i {
13 Instruction::Lui(_) => "lui",
14 Instruction::Jal(_) => "jal",
15 Instruction::Jalr(_) => "jalr",
16 Instruction::Beq(_) => "beq",
17 Instruction::Ld(_) => "ld",
18 Instruction::Sd(_) => "sd",
19 Instruction::Addi(_) => "addi",
20 Instruction::Add(_) => "add",
21 Instruction::Sub(_) => "sub",
22 Instruction::Sltu(_) => "sltu",
23 Instruction::Mul(_) => "mul",
24 Instruction::Divu(_) => "divu",
25 Instruction::Remu(_) => "remu",
26 Instruction::Ecall(_) => "ecall",
27 }
28}