Changed jalr test

This commit is contained in:
Valentin Haudiquet 2023-10-09 00:20:27 +02:00
parent 44a917b398
commit 7f3efb092c

View File

@ -12,15 +12,17 @@ _start:
# Try to call two imbricated functions # Try to call two imbricated functions
jal fn0 jal fn0
auipc t0, 0 auipc ra, 0
jalr ra, 12(t0) jalr 12(ra)
ebreak ebreak
# just_after : address is 12 bytes after auipc # just_after : address is 12 bytes after auipc
just_after: just_after:
# ra must still be the old address
addi a0, zero, 0 addi a0, zero, 0
ret ret
addi a0, zero, 1
ebreak ebreak
# fn0 : function that calls fn1 and returns # fn0 : function that calls fn1 and returns