File tree 2 files changed +5
-9
lines changed
test/resources/testSource/sys/risc-v
2 files changed +5
-9
lines changed Original file line number Diff line number Diff line change @@ -574,8 +574,8 @@ public ExpressionNode visit(GroupedExpr expr) {
574
574
575
575
@ Override
576
576
public ExpressionNode visit (IntegerLiteral expr ) {
577
- return new ConstantNode ( Constant . Value . fromInteger ( expr . number ,
578
- (( ConstantType ) expr . type ()). closestBits ()) );
577
+ // IntegerLiteral should never be reached as it should always be substituted by the typechecker.
578
+ throw new IllegalStateException ( "IntegerLiteral should never be reached in the VIAM lowering." );
579
579
}
580
580
581
581
@ Override
Original file line number Diff line number Diff line change @@ -230,13 +230,9 @@ processor Spike implements RV32IMZicsr = {
230
230
// this processor has no zicsr extension: 0xf1402573 csrr a0, mhartid
231
231
MEM<4>(0x1008) := 0x00000013 // addi x0, x0, 0
232
232
233
- if MLen = 32 then {
234
- MEM<4>(0x100c) := 0x0202a583 // lw a1, 32(t0)
235
- MEM<4>(0x1010) := 0x0182a283 // lw t0, 24(t0)
236
- } else {
237
- MEM<4>(0x100c) := 0x0202b583 // ld a1, 32(t0)
238
- MEM<4>(0x1010) := 0x0182b283 // ld t0, 24(t0)
239
- }
233
+ // 32-bit reset version
234
+ MEM<4>(0x100c) := 0x0202a583 // lw a1, 32(t0)
235
+ MEM<4>(0x1010) := 0x0182a283 // lw t0, 24(t0)
240
236
241
237
MEM<4>(0x1014) := 0x00028067 // jr t0
242
238
// store start_addr in memory (0x80000000)
You can’t perform that action at this time.
0 commit comments