It took a while, but I did it! I really don't know why it took so long for be to learn c++, but but I'm glad its finally over with. I really needed to get past languages with VMs, because I want to try to make my own language, with its own compiler or, optionally a vm with a shell. (like python, although i do realize python still only compiles to bytecode, not machinecode). the exact details of how my language, vm, and compiler will work are still in their infancy, but this is roughly what I plan to do:
language:
-modernized version of BASIC (to start, at least)
-it will include goto, because the state machine in the vm will be coded by hand (no bison!), so there wont be any optimization to ruin in the first place.
vm:
-written in c++
- this is where i need help should i create a stack machine? or a register machine? what are the pros and cons of each?
compiler:
-written in c++, then rewritten in BITCH (my version of BASIC) once i can compile it.
I've been researching this stuff for a while now, and I know how each part of the compiler and vm functions individually, so I think I'm finally ready. wish me luck! and if any of you have any advice, I'd love to hear it. if this ever works out, Im thinking about doing something with brainfuck.
language:
-modernized version of BASIC (to start, at least)
-it will include goto, because the state machine in the vm will be coded by hand (no bison!), so there wont be any optimization to ruin in the first place.
vm:
-written in c++
- this is where i need help should i create a stack machine? or a register machine? what are the pros and cons of each?
compiler:
-written in c++, then rewritten in BITCH (my version of BASIC) once i can compile it.
I've been researching this stuff for a while now, and I know how each part of the compiler and vm functions individually, so I think I'm finally ready. wish me luck! and if any of you have any advice, I'd love to hear it. if this ever works out, Im thinking about doing something with brainfuck.