rubyx/lib/virtual.rb

37 lines
1.1 KiB
Ruby
Raw Normal View History

require "parfait"
require "virtual/machine"
#if we are in the ruby run-time / generating an executable
require "virtual/positioned"
require "virtual/padding"
require "virtual/parfait_adapter"
require "virtual/compiler"
require "virtual/instruction"
2015-07-03 19:13:03 +02:00
require "virtual/method_source"
require "virtual/slots/slot"
require "virtual/type"
# the passes _are_ order dependant
require "virtual/passes/minimizer"
2015-05-31 10:07:49 +02:00
require "virtual/passes/collector"
require "virtual/passes/send_implementation"
require "virtual/passes/get_implementation"
require "virtual/passes/enter_implementation"
2015-06-21 16:22:51 +02:00
require "virtual/passes/set_optimisation"
2015-06-19 12:11:40 +02:00
Sof::Volotile.add(Parfait::Object , [:memory])
Sof::Volotile.add(Parfait::Method , [:memory])
Sof::Volotile.add(Parfait::Class , [:memory])
Sof::Volotile.add(Parfait::Layout , [:memory])
Sof::Volotile.add(Parfait::Space , [:memory])
Sof::Volotile.add(Parfait::Frame , [:memory])
Sof::Volotile.add(Parfait::Message , [:memory])
Sof::Volotile.add(Parfait::BinaryCode , [:memory])
Sof::Volotile.add(Virtual::Block , [:method])
2015-07-03 19:13:03 +02:00
Sof::Volotile.add(Virtual::MethodSource , [:current])
2015-05-29 11:47:49 +02:00
class Fixnum
def fits_u8?
self >= 0 and self <= 255
end
end