Move builtin wholesale to Mom

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)
This commit is contained in:
2019-08-12 12:36:32 +03:00
parent a4b6f29834
commit fa0aa30386
20 changed files with 40 additions and 30 deletions

View File

@ -12,15 +12,11 @@ class Class
end
end
# The Risc Machine, is an abstract machine with registers. Think of it as an arm machine with
# normal instruction names. It is not however an abstraction of existing hardware, but only
# of that subset that we need.
# See risc/Readme
module Risc
# module method to reset, and init
def self.boot!
Position.clear_positions
Builtin.boot_functions
end
end
@ -47,5 +43,4 @@ end
require_relative "risc/instruction"
require_relative "risc/register_value"
require_relative "risc/text_writer"
require_relative "risc/builtin"
require_relative "risc/builder"