all green

That fixes all existing tests. Operation successful

Off course there is tests missing :-(
This commit is contained in:
Torsten Ruger
2015-05-20 17:29:08 +03:00
parent 2ec9ee90f9
commit 422ec64105
9 changed files with 34 additions and 30 deletions

View File

@ -1,11 +1,11 @@
module Arm
# There are only three call instructions in arm branch (b), call (bl) and syscall (swi)
# A branch could be called a jump as it has no notion of returning
# The pc is put into the link register to make a return possible
# a return is affected by moving the stored link register into the pc, effectively a branch
# swi (SoftWareInterrupt) or system call is how we call the kernel.
# in Arm the register layout is different and so we have to place the syscall code into register 7
# Registers 0-6 hold the call values as for a normal c call
@ -36,7 +36,7 @@ module Arm
if( arg.is_a? Fixnum ) #HACK to not have to change the code just now
arg = Virtual::IntegerConstant.new( arg )
end
if arg.is_a?(Virtual::Block) or arg.is_a?(Virtual::CompiledMethod)
if arg.is_a?(Virtual::Block) or arg.is_a?(Virtual::CompiledMethodInfo)
#relative addressing for jumps/calls
diff = arg.position - self.position
# but because of the arm "theoretical" 3- stage pipeline, we have to subtract 2 words (fetch/decode)