Commit graph

48 commits

Author SHA1 Message Date
Janis 6f3a7dc56c helpers for reading ast Data and getting children of ast nodes 2024-09-09 15:41:56 +02:00
Janis 45653380cf new ast parser 2024-09-09 15:01:53 +02:00
Janis 44fa241a79 new ast module 2024-09-03 22:58:46 +02:00
Janis 07c98d55a0 remove old code 2024-09-02 16:52:48 +02:00
Janis 568c3b2fa4 calling functions 2024-09-02 16:03:12 +02:00
Janis 4424ef875d global symbols 2024-09-02 12:59:17 +02:00
Janis 4b432f404b branching? yay? 2024-09-01 21:31:09 +02:00
Janis b0f52da586 phi node 2024-09-01 14:28:48 +02:00
Janis dd6ce88ad6 if-else branches in IR 2024-09-01 12:28:47 +02:00
Janis 6bab60d168 if-else ast 2024-08-30 23:55:13 +02:00
Janis ad6a9b00ec fix warnings 2024-08-30 23:55:01 +02:00
Janis 9194e35851 remove comments from asm 2024-08-30 21:55:16 +02:00
Janis 48bbcdec5e boolean arithmetic 2024-08-30 19:31:44 +02:00
Janis cbc416dcaa no longer wrong! 2024-08-30 18:13:28 +02:00
Janis e9335d3fc5 something is wrong, but typechecking 2024-08-30 17:34:26 +02:00
Janis 70644ede3e fixes, rewrote liveness gen a bit 2024-08-30 16:22:53 +02:00
Janis 9f0e2c4a31 mir to asm translation WORKS!! 2024-08-29 21:34:05 +02:00
Janis 3aee606ca2 mir.rs changes for last commit's triples.rs changes 2024-08-29 01:50:58 +02:00
Janis 9d85eb1428 inline loading of values into registers into mir.rs 2024-08-29 01:50:08 +02:00
Janis 9b484ce175 bitflag dependency 2024-08-29 01:48:11 +02:00
Janis 2d8c75ba0d comptime folding changes/fixes for declrefs 2024-08-27 21:52:36 +02:00
Janis 62cf214bde comptime folding can now deal with declrefs 2024-08-27 21:08:37 +02:00
Janis d4918a722f warnings chore 2024-08-27 18:49:50 +02:00
Janis 270162850d comptime folding works!!!!! 2024-08-27 18:49:28 +02:00
Janis 18e29f1fa1 folding comptime math 2024-08-27 17:22:47 +02:00
Janis a64658995a comptime math 2024-08-27 16:21:39 +02:00
Janis 42a3be8186 bigint math 2024-08-27 00:54:55 +02:00
Janis 99bf630546 amd64 abstraction which was required like 10 commits ago 2024-08-26 15:59:34 +02:00
Janis eba0edb9e4 refactor/cleanup of mir generation for arithmetic ops and preloading of constant lhs 2024-08-26 15:58:51 +02:00
Janis 06b1ec1763 register allocator refactor 2024-08-26 15:58:01 +02:00
Janis 16399192b3 mir register allcoator 2024-08-26 13:47:44 +02:00
Janis c13ed77ddf intel syntax because at&t just sucks so much to read idek how 2024-08-25 16:04:37 +02:00
Janis 010e6d2bec LANGUAGE CHANGES
prefix binds tighter than as-expr, because &a as *u32 should be valid syntax
i think it can actually do pointer arithmetic somewhat validly now?
2024-08-25 03:09:54 +02:00
Janis c8d51e8bcf reserve rax for scratch 2024-08-19 16:28:58 +02:00
Janis f7ec585057 goodness gracious it can do integer addition and pointer dereferencing!!!! 2024-08-18 19:59:13 +02:00
Janis 00359a306c stufffffffffff 2024-08-18 14:52:24 +02:00
Janis ddd65e8c4d has string_table now :^) 2024-08-16 22:38:13 +02:00
Janis 5c57dfb904 trying to refactor a bit:
- working on a string/bytes table
- no longer directly referencing ir outside of current function; the goal here
is to end up only generating ir for 1 function, then link together in assembling
step. this involves adding an GlobalRef() ast-node and ExternRef() ir instruction
2024-08-16 16:56:11 +02:00
Janis 2689179ed4 changed globaldecl to only allow const instead of let or var as keyword 2024-08-14 17:55:03 +02:00
Janis efff2446bc not entirely sure why yet, but made SymbolTable a tree of pointers 2024-08-14 17:03:10 +02:00
Janis 3bb4ba79bc move symboltable into parser and tree, away from triples gen 2024-08-14 14:57:23 +02:00
Janis 66d08dadcc remove lints 2024-08-13 18:55:36 +02:00
Janis fe25d226d1 integrated SymbolTable into AST/Parser 2024-08-13 18:49:22 +02:00
Janis c3157b1355 not really sure, i guess this is an IR? 2024-08-13 00:00:19 +02:00
Janis 02be9bdc26 simple lexing error reporting 2024-08-09 18:58:26 +02:00
Janis 69e67c882d can generate naive ast and render 2024-08-08 19:14:14 +02:00
Janis b7105c1235 working on parsing ast 2024-08-07 00:35:10 +02:00
Janis e8934b8ccc initial commit 2024-08-06 20:58:09 +02:00