Torsten Rüger
fa0aa30386
Since Builtin generates risc, just like mom instructions, it was a design mistake to put builtin into risc in the first place. Now that borders are coming more into focus, it make much more sense to have the builtin in mom. In fact the instructions should be moved out and a seperate invocation mechanism used , so functions can be parsed, not generated (wip)
27 lines
850 B
Ruby
27 lines
850 B
Ruby
# The *essential* step from vool to risc, is the one from a language to a machine.
|
|
# From vools statements that hang in the air, to an instruction set.
|
|
#
|
|
# ### List based: Bit like Risc, just no registers
|
|
#
|
|
# ### Use object memory : object to object transfer + no registers
|
|
#
|
|
# ### Instruction based
|
|
#
|
|
# So a machine rather than a language. No control structures, but compare and jump instructions.
|
|
# No send or call, just objects and jump.
|
|
# Machine capabilities (instructions) for basic operations. Use of macros for higher level.
|
|
|
|
module Mom
|
|
# boot bubiltin function (subject to change)
|
|
def self.boot!
|
|
Builtin.boot_functions
|
|
end
|
|
end
|
|
|
|
require_relative "instruction.rb"
|
|
require_relative "mom_collection"
|
|
require_relative "callable_compiler"
|
|
require_relative "method_compiler"
|
|
require_relative "block_compiler"
|
|
require_relative "builtin"
|