Commit Graph

5 Commits (162683d63e085e5317d71d4b34ec659984145a46)

Author SHA1 Message Date
James T. Martin 162683d63e
Hacked together a god-awful hand-written lexer. 2022-09-07 11:07:05 -07:00
James T. Martin 46640b6204
Remove gratuitous platform-specific IO.
I don't need some fancy atomic output file updating or
posix_fadvise. I removed all platform-specific code
except for a single `chmod`.

That's not to say there's no advantage to atomically
reading or writing files, but for this project, the first
rule needs to be KISS. It's premature optimization and
overengineering.
2022-09-06 23:16:23 -07:00
James T. Martin 57aa667000
Completely rewrite stack management.
Now we always use the stack instead of keeping a TOS register.
This is very inefficient, but I'll worry about register
allocation later.

The new block model is inspired by x86's `enter` and `leave`
instructions. I intend to support nested procedures at some point
in the future.
2022-09-06 19:47:46 -07:00
James T. Martin 4e06f8d00f
Separate instruction encoding into a separate file.
I describe the intended file structure in comments
at the top of each file.
2022-09-06 02:20:10 -07:00
James T. Martin b5667c61ec
Initial commit. 2022-09-05 23:48:56 -07:00