minor send fixes

This commit is contained in:
Torsten Ruger 2015-09-27 19:07:56 +03:00
parent 3e46dcda4e
commit eb57eb4d41
5 changed files with 4 additions and 4 deletions

View File

@ -36,7 +36,7 @@ module Virtual
class Machine class Machine
FIRST_PASS = "Virtual::SendImplementation" FIRST_PASS = "Virtual::GetImplementation"
LAST_PASS = "Virtual::SetOptimisation" LAST_PASS = "Virtual::SetOptimisation"
def initialize def initialize

View File

@ -13,5 +13,4 @@ module Virtual
end end
end end
end end
Virtual.machine.add_pass "Virtual::GetImplementation"
end end

View File

@ -44,7 +44,7 @@ int foo()
end end
foo() foo()
HERE HERE
@output = [[Virtual::MethodEnter , Virtual::NewMessage, Virtual::Set, Virtual::Set, Virtual::MessageSend], @output = [[Virtual::MethodEnter , Virtual::NewMessage, Virtual::Set, Virtual::Set, Virtual::MethodCall],
[Virtual::MethodReturn]] [Virtual::MethodReturn]]
check check
end end

View File

@ -9,7 +9,7 @@ int foo(int x)
int a = 5 int a = 5
return a return a
end end
3.foo( 4 ) foo( 4 )
HERE HERE
@expect = [ Virtual::Return ] @expect = [ Virtual::Return ]
check check

View File

@ -64,6 +64,7 @@ class TestPuts < MiniTest::Test
"GetSlot" , "RegisterTransfer" ,"GetSlot" , "GetSlot","GetSlot", "GetSlot" , "RegisterTransfer" ,"GetSlot" , "GetSlot","GetSlot",
"FunctionReturn" , "RegisterTransfer" , "Syscall" , "NilClass"].each_with_index do |name , index| "FunctionReturn" , "RegisterTransfer" , "Syscall" , "NilClass"].each_with_index do |name , index|
got = ticks(1) got = ticks(1)
#puts "TICK #{index}"
assert got.class.name.index(name) , "Wrong class for #{index+1}, expect #{name} , got #{got}" assert got.class.name.index(name) , "Wrong class for #{index+1}, expect #{name} , got #{got}"
end end
end end