keep track of used and assigned registers for each block

This commit is contained in:
Torsten Ruger
2014-06-08 01:41:56 +03:00
parent fbcfa844de
commit b66c4157d5
4 changed files with 78 additions and 12 deletions

View File

@ -106,7 +106,7 @@ module Arm
end
def syscall block , num
sys_and_ret = Vm::Integer.new(7)
sys_and_ret = Vm::Integer.new( Vm::Function::RETURN_REG )
block << mov( sys_and_ret , num )
block << swi( 0 )
#small todo, is this actually correct for all (that they return int)