Compare commits
2 Commits
13f7f21b49
...
c421595a95
Author | SHA1 | Date | |
---|---|---|---|
c421595a95 | |||
9e895e9032 |
@ -518,6 +518,12 @@ static void cpu_execute(rv32_cpu_t* cpu, instruction_t* instruction)
|
|||||||
cpu->sim_ticks_left = 1;
|
cpu->sim_ticks_left = 1;
|
||||||
cpu->pc -= 4;
|
cpu->pc -= 4;
|
||||||
break;
|
break;
|
||||||
|
case IMM_SRET:
|
||||||
|
fprintf(stderr, "SRET: We don't support that.\n");
|
||||||
|
break;
|
||||||
|
case IMM_MRET:
|
||||||
|
fprintf(stderr, "MRET: We don't support that.\n");
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
switch(instruction->func7)
|
switch(instruction->func7)
|
||||||
{
|
{
|
||||||
@ -525,7 +531,8 @@ static void cpu_execute(rv32_cpu_t* cpu, instruction_t* instruction)
|
|||||||
fprintf(stderr, "SFENCE.VMA: Guest kernel must think we have an MMU. We have none.\n");
|
fprintf(stderr, "SFENCE.VMA: Guest kernel must think we have an MMU. We have none.\n");
|
||||||
break;
|
break;
|
||||||
case FUNC7_WFI:
|
case FUNC7_WFI:
|
||||||
fprintf(stderr, "WFI: Guest kernel must think we have interrupts. We have none.\n");
|
fprintf(stderr, "WFI: Guest kernel must think we have interrupts. We have none. Halting simulation.\n");
|
||||||
|
cpu->sim_ticks_left = 1;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
fprintf(stderr, "FATAL: Unknown IMM for ECALL/EBREAK instruction while executing (IMM=0x%x)\n", instruction->immediate);
|
fprintf(stderr, "FATAL: Unknown IMM for ECALL/EBREAK instruction while executing (IMM=0x%x)\n", instruction->immediate);
|
||||||
@ -1069,6 +1076,12 @@ static void cpu_print_instruction(instruction_t* instruction)
|
|||||||
case IMM_EBREAK:
|
case IMM_EBREAK:
|
||||||
printf("ebreak\n");
|
printf("ebreak\n");
|
||||||
break;
|
break;
|
||||||
|
case IMM_SRET:
|
||||||
|
printf("sret\n");
|
||||||
|
break;
|
||||||
|
case IMM_MRET:
|
||||||
|
printf("mret\n");
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
switch(instruction->func7)
|
switch(instruction->func7)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user