glm94
|
8b6edc39be
|
Updated the Parser to handle the variable declaration directive.
|
2022-10-08 16:15:10 -05:00 |
|
glm94
|
c142d2c6d0
|
Cleaned up the Symbol struct and updated code accordingly.
|
2022-10-08 14:43:00 -05:00 |
|
glm94
|
4b08707e67
|
Cleaned up the list implementation so as to NOT copy items into a new buffer.
|
2022-10-07 20:46:55 +00:00 |
|
glm94
|
bdb4d2b241
|
Updated the way Instructions keep track of symbols. Only their name is important but we need the Symbols to be able to track which Instruction they point to (if they do that is, i.e. a label symbol).
|
2022-10-06 21:11:22 -05:00 |
|
glm94
|
d53833c25f
|
Added some debug print out for the instruction list and a helper function to get a string for any Registers enum.
|
2022-10-06 21:05:57 +00:00 |
|
glm94
|
f38da9cc74
|
A bit of cleanup.
|
2022-10-04 21:05:15 +00:00 |
|
glm94
|
33309a2759
|
Updated the Instruction's structure and updated the Parser accordingly.
|
2022-10-04 20:37:47 +00:00 |
|
glm94
|
1f7989533b
|
Fixed a bug in the SymbolsTable where it wouldn't update its size.
|
2022-10-03 20:11:04 -05:00 |
|
glm94
|
cd1258a724
|
Fixed various Parser bugs.
|
2022-10-03 19:58:44 -05:00 |
|
glm94
|
be91e3c112
|
Updated the parser to better handle parameters, sort of and including a string length assembly program to use as a test for the whole assembler.
|
2022-10-03 21:26:28 +00:00 |
|
glm94
|
706f480e31
|
The Scanner will now check for empty lines (is the previous token and the current token a new line?) and simply not emit a NewLine Token.
|
2022-10-03 19:40:00 +00:00 |
|
glm94
|
a949007c75
|
Updated the ISA so the program will correctly see things like 'load', 'inc' and 'dec'.
|
2022-10-03 16:56:39 +00:00 |
|
glm94
|
a0d5d62a34
|
Fixed a bug in the Scanner when parsing a hex number, still not super robust but it'll work.
|
2022-10-03 15:20:31 +00:00 |
|
glm94
|
f7cd87f13f
|
Started reworking the Parser to simplify how instructions will be represented. It will act like a 'first pass' that will do grammar checks but not verify the parameters of the opcodes.
|
2022-10-02 22:54:18 -05:00 |
|
glm94
|
55f4c32764
|
Missed this for the Scanner fix.
|
2022-10-02 22:12:16 -05:00 |
|
glm94
|
097eca383b
|
Fixed a bug with the Scanner adding a blank line via a single NewLine Token when a file starts with a block of comments.
|
2022-10-01 20:43:55 -05:00 |
|
glm94
|
984683bfc5
|
Minor adjustment to Figure 1.1
|
2022-09-29 22:57:12 -05:00 |
|
glm94
|
0f42ad2997
|
Updated the ISA and added links in the table of contents.
|
2022-09-29 22:11:19 -05:00 |
|
glm94
|
63438b551b
|
Got the scanner running again. Seems to be picking up punctuation, labels, identifiers and strings as expected.
|
2022-09-29 21:32:08 -05:00 |
|
glm94
|
e94e486e18
|
More refinements to the loading data instructions. I am truly bad at this whole thing...
|
2022-09-29 20:42:37 +00:00 |
|
glm94
|
2b71ac05a0
|
Added a note about a proposal regarding assembly language design.
|
2022-09-27 17:46:50 +00:00 |
|
glm94
|
02cf72902e
|
Updated the load instructions.
|
2022-09-26 22:13:48 -05:00 |
|
glm94
|
afa84076c8
|
Added a command to make generating an opcode table a one liner. Updated the ISA.
|
2022-09-23 19:36:27 +00:00 |
|
glm94
|
925f7703d6
|
Updated the ISA, hopefully I can get this all put together in a thought out way.
|
2022-09-22 20:49:20 +00:00 |
|
glm94
|
a82a4c23ad
|
Updated the docs.
|
2022-09-21 21:44:38 -05:00 |
|
glm94
|
f5c82d1c36
|
Added a LaTex document to put in writing how the machine should behave.
|
2022-09-21 16:23:11 +00:00 |
|
glm94
|
0b58e0124f
|
Some refactoring to update everything to use the new structures and some new considerations for how Symbols and Instructions shoudl be represented.
|
2022-09-15 22:14:38 -05:00 |
|
glm94
|
2ae60a607c
|
Incomplete, but I want to make sure the ideas I have here don't get wiped. Sadly this commit won't compile.
|
2022-09-15 21:29:27 +00:00 |
|
glm94
|
6d17dffcdf
|
Added a SymbolTable object (untested at the moment) and redefined the Symbol object. I think when a Symbol is made only the size of it should matter to the code that will assemble the final binary.
|
2022-09-08 20:56:02 +00:00 |
|
glm94
|
2518214585
|
Added a length attribute to the symbol.
|
2022-09-06 14:15:45 +00:00 |
|
glm94
|
7004fff659
|
This feels like a trainwreck but eh. Changed the way the opcodes are managed. Hopefully this is the right direction when I add support for multiple ASM files.
|
2022-09-01 18:46:59 +00:00 |
|
glm94
|
13f8ff194b
|
Smoothbrain indeed...
|
2022-08-30 22:48:49 -05:00 |
|
glm94
|
dac01ffd0c
|
Changed the TokenClass from opcode to nomic, a less smoothbrain name IMO and also frees up Opcode for a better use later on.
|
2022-08-30 22:06:50 -05:00 |
|
glm94
|
3c7056c5e6
|
The main function will now write out the output of the parser.
|
2022-08-29 21:23:02 +00:00 |
|
glm94
|
6c7b8d5356
|
Fixed a bug where CMP REG, REG wouldn't get encoded and a disassembler bug related to said CMP bug.
|
2022-08-29 19:29:34 +00:00 |
|
glm94
|
5f437b6869
|
Both the assembler and the disassembler should now support all the instructions I've layed out thus far.
|
2022-08-29 18:51:48 +00:00 |
|
glm94
|
e3b4293314
|
Fixed a bug in the parser where the size of the binary was too big.
|
2022-08-29 18:02:11 +00:00 |
|
glm94
|
ae1e73e00f
|
Fixed a bug to correct the location of symbols in the heap.
|
2022-08-29 16:00:02 +00:00 |
|
glm94
|
7385a807a5
|
Created a basic binary format to help guide the disassembler.
|
2022-08-29 15:57:14 +00:00 |
|
glm94
|
0d3f8a460e
|
Added more instructions for the parser to emit and refactored the code in doing so.
|
2022-08-28 15:37:56 -05:00 |
|
glm94
|
c2111e2b88
|
Added support for the ADD and SUB opcodes to the disassembler.
|
2022-08-28 13:08:18 -05:00 |
|
glm94
|
8e9d1aefe8
|
Fixed some disassembler issues. At least some instuctions are being disassembled correctly.
|
2022-08-26 21:43:03 -05:00 |
|
glm94
|
0785f21805
|
Added a disassembler which is still very buggy. Also fixed some bugs with the opcode mask getting function.
|
2022-08-26 21:41:02 +00:00 |
|
glm94
|
e4a191a17e
|
Refined the encoding some more.
|
2022-08-26 19:00:37 +00:00 |
|
glm94
|
eb5e2c506e
|
Got the start of encoding opcodes.
|
2022-08-26 18:27:41 +00:00 |
|
glm94
|
0d060248cb
|
Forgot about the bloody IN instruction...
|
2022-08-25 21:01:35 -05:00 |
|
glm94
|
80bea6f1a8
|
I'm dumb, fixed the CMP opcode overlap..
|
2022-08-25 20:57:33 -05:00 |
|
glm94
|
a96f485da6
|
I believe I have the bit patterns for my opcodes worked out.
|
2022-08-25 20:45:46 -05:00 |
|
glm94
|
88d550f344
|
Added unconditional jump opcode to my comment section.
|
2022-08-25 20:27:25 -05:00 |
|
glm94
|
0e53f9798f
|
Added a distinction between constant numbers and what are effectively memory addresses (i.e. strings and labels).
|
2022-08-25 19:47:16 -05:00 |
|