start passing positions along inside the position code
This commit is contained in:
@ -20,7 +20,7 @@ module Arm
|
||||
bin = Parfait::BinaryCode.new(1)
|
||||
Risc::Position.set(bin , 0x20)
|
||||
code = @machine.call( bin ,{} )#this jumps to the next instruction
|
||||
Risc::Position.set(code , 0)
|
||||
Risc::Position.set(code , 0, 1)
|
||||
assert_code code , :call, [0x09,0x0,0x0,0xeb]
|
||||
end
|
||||
def test_swi
|
||||
|
@ -82,7 +82,7 @@ module Arm
|
||||
end
|
||||
def test_too_big_add
|
||||
code = @machine.add :r1 , :r1, 0x222
|
||||
Risc::Position.set(0,0)
|
||||
Risc::Position.set(code,0,1)
|
||||
# add 0x02 (first instruction) and then 0x220 shifted
|
||||
assert_code code , :add , [0x02,0x1c,0x91,0xe2] #e2 91 1e 02
|
||||
# added extra instruction to add "extra"
|
||||
|
Reference in New Issue
Block a user