From 35a5980e2ada2131155572f2dd1986989d3cf5a9 Mon Sep 17 00:00:00 2001 From: Erick Date: Thu, 7 Apr 2022 20:35:19 +0200 Subject: [PATCH] added a description of the next things to do for the vm --- main.c => vm.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) rename main.c => vm.c (72%) diff --git a/main.c b/vm.c similarity index 72% rename from main.c rename to vm.c index 72e0ddd..5e350bd 100644 --- a/main.c +++ b/vm.c @@ -4,6 +4,10 @@ #include #include +#include "assembler/assembler.c" +#include "compiler/compiler.c" + + // Logic gates Verilog files char gates[][32] = {"gates/and8way.v", "and8way16.v" @@ -21,6 +25,7 @@ char cpu[][32] = {"cpu/alu/alu.sv", "cpu/cpu.sv" }; +//FIXME:: can read folder and output every file name? then choose what to run?? //TODO: read all files and choose what file execute char input[][32] = {"asm/mult.asm", "asm/example.asm" @@ -38,6 +43,8 @@ int main(int argc, int *argv) { bool load = FALSE; bool quit = FALSE; + // startup and load->TRUE + // Load *.sv subsystem files if (load == TRUE) { // Load logic gates @@ -52,7 +59,15 @@ int main(int argc, int *argv) { import_sv(cpu[i]); } } + //TODO: NEXT STUFF TO DO + // read files, create a general logic to read *.sv, start cpu and use any other chip as needed, + // included in a file, like a tree of inclusions(?) + // user choose high level language program, compiler compiles (duh) to maachine code; + // assembly assembles (double-duh) the program, we read assembled program (binary opcodes) which inputs are feed + // to the rom, which will send to the cpu + + // maybe also load os-like assembled program, that allocates stuff or do useful things before running programs? if(quit == TRUE) {