add traceable dummies

This commit is contained in:
Torsten Ruger 2018-03-14 20:25:21 +05:30
parent 559a797100
commit 2533842204
7 changed files with 24 additions and 5 deletions

View File

@ -23,6 +23,10 @@ module Mom
def initialize( receiver,arguments ) def initialize( receiver,arguments )
@receiver , @arguments = receiver , arguments @receiver , @arguments = receiver , arguments
end end
def to_risc(context)
Risc::Label.new(self,"ArgumentTransfer")
end
end end

View File

@ -19,6 +19,10 @@ module Mom
@cached_type = type @cached_type = type
@cached_method = method @cached_method = method
end end
def to_risc(context)
Risc::Label.new(self,"DynamicCall")
end
end end
end end

View File

@ -1,13 +1,16 @@
module Mom module Mom
# unconditional jump to the instruction given as target # unconditional jump to the instruction given as target
# #
class Jump < Instruction class Jump < Instruction
attr_reader :target attr_reader :target
def initialize(target) def initialize(target)
@target = target @target = target
end end
def to_risc(context)
Risc::Label.new(self,"Jump")
end
end end

View File

@ -18,7 +18,7 @@ module Mom
end end
def to_risc(compiler) def to_risc(compiler)
Risc::Label.new(self,method.name) Risc::Label.new(self,"MethodSetup")
end end
end end

View File

@ -13,8 +13,8 @@ module Mom
@left , @right = left , right @left , @right = left , right
end end
def to_risc(compiler) def to_risc(context)
Risc::Label.new(self,"NotSameCheck") Risc::Label.new(self,"NotSameCheck")
end end
end end
end end

View File

@ -19,6 +19,10 @@ module Mom
# set of lower level instructions. # set of lower level instructions.
# #
class ReturnSequence < Instruction class ReturnSequence < Instruction
def to_risc(context)
Risc::Label.new(self,"ReturnSequence")
end
end end
end end

View File

@ -9,10 +9,14 @@ module Mom
# #
class SimpleCall < Instruction class SimpleCall < Instruction
attr_reader :method attr_reader :method
def initialize(method) def initialize(method)
@method = method @method = method
end end
def to_risc(context)
Risc::Label.new(self,"SimpleCall")
end
end end
end end