remove dead code

This commit is contained in:
Torsten Ruger 2016-12-14 19:06:48 +02:00
parent b3bf881c49
commit bf4ddd16ee
5 changed files with 0 additions and 43 deletions

View File

@ -88,14 +88,6 @@ module Arm
io.write_uint32 val io.write_uint32 val
end end
def uses
ret = [@left.register ]
ret << @right.register unless @right.is_a? Constant
ret
end
def assigns
[]
end
def to_s def to_s
"#{opcode} #{@left} , #{@right} #{super}" "#{opcode} #{@left} , #{@right} #{super}"
end end

View File

@ -108,14 +108,5 @@ module Arm
def to_s def to_s
"#{self.class.name} #{opcode} #{@result} = #{@left} #{@right} extra=#{@extra}" "#{self.class.name} #{opcode} #{@result} = #{@left} #{@right} extra=#{@extra}"
end end
def uses
ret = []
ret << @left.register if @left and not @left.is_a? Constant
ret << @right.register if @right and not @right.is_a?(Constant)
ret
end
def assigns
[@result.register]
end
end end
end end

View File

@ -109,13 +109,5 @@ module Arm
io.write_uint32 val io.write_uint32 val
end end
def uses
ret = [@left.register ]
ret << @right.register unless @right.nil?
ret
end
def assigns
[@result.register]
end
end end
end end

View File

@ -102,11 +102,5 @@ module Arm
end end
end end
def uses
@from.is_a?(Constant) ? [] : [@from.register]
end
def assigns
[@to.register]
end
end end
end end

View File

@ -59,18 +59,6 @@ module Arm
io.write_uint32 val io.write_uint32 val
end end
def is_push?
opcode == :push
end
def is_pop?
!is_push?
end
def uses
is_push? ? regs : []
end
def assigns
is_pop? ? regs : []
end
def regs def regs
@first @first
end end