about summary refs log tree commit diff stats
Commit message (Collapse)AuthorAgeFilesLines
* mu.subx: redo passing code-gen testsKartik Agaram2020-05-182-147/+118
| | | | | | We've gone back and rewritten the tests to fit the older format from 3 commits ago. No behavior change, but staying close to the older format should make it easier to update the remaining tests.
* mu.subx: another code-gen testKartik Agaram2020-05-181-37/+105
|
* -Kartik Agaram2020-05-181-8/+4
| | | | Remove one local variable and unnecessary copy.
* mu.subx: first code-gen test passing!Kartik Agaram2020-05-183-109/+258
|
* handle nulls in lookupKartik Agaram2020-05-1813-4/+36
| | | | | | | | | Cleaner abstraction, but adds 3 instructions to our overhead for handles, including one potentially-hard-to-predict jump :/ I wish I could have put the alloc id in eax for the comparison as well, to save a few bytes of instruction space. But that messes up the non-null case.
* mu.subx: all parsing tests passingKartik Agaram2020-05-182-2/+2
|
* mu.subx: tests for parse-var-with-typeKartik Agaram2020-05-181-45/+93
|
* mu.subx: done with function header parsingKartik Agaram2020-05-181-56/+97
|
* mu.subx: second parsing testKartik Agaram2020-05-181-30/+48
| | | | | append-list is still very confusing the way it's written. Maybe I should just use an extra register or an extra local variable or something.
* -Kartik Agaram2020-05-181-2/+2
|
* -Kartik Agaram2020-05-181-1/+1
|
* mu.subx: first parsing test passingKartik Agaram2020-05-181-13/+20
| | | | | | | 2 bugfixes in this commit. I thought I'd seen append-list successfully working in some previous test, but I was wrong.
* -Kartik Agaram2020-05-181-1/+1
|
* ok, let's start running testsKartik Agaram2020-05-181-4/+8
|
* -Kartik Agaram2020-05-181-4/+2
|
* mu.subx: spilling register for reg varsKartik Agaram2020-05-182-20/+22
|
* mu.subx: size-of-derefKartik Agaram2020-05-181-8/+12
|
* mu.subx: size-ofKartik Agaram2020-05-181-6/+8
|
* mu.subx: populate-mu-type-offsetsKartik Agaram2020-05-181-19/+24
| | | | | | | Also locate-typeinfo-entry-with-index, though I didn't need to change much there. But it did get me to notice that I'm returning `addr` from functions. Need to correct my paper.
* -Kartik Agaram2020-05-181-30/+0
|
* mu.subx: compute-size-of-varKartik Agaram2020-05-181-6/+8
|
* mu.subx: lookup-or-create-constantKartik Agaram2020-05-181-12/+12
|
* mu.subx: new-blockKartik Agaram2020-05-181-3/+13
|
* mu.subx: find-in-function-outputsKartik Agaram2020-05-181-11/+27
|
* mu.subx: fourth test passingKartik Agaram2020-05-181-16/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Our four tests are exercising the following 18 primitives at least a little bit: add-operation-and-inputs-to-stmt append-stmt-var lookup-var lookup-var-helper lookup-var-or-literal new-literal-integer new-reg-var-def new-var new-var-def new-var-from-slice next-mu-token parse-mu-stmt parse-mu-var-def parse-type parse-var-with-type pos-or-insert-slice pos-slice stmt-has-outputs? For comparison, here are the 34 primitives in mu.subx that we've made significant changes to since all tests passed: add-operation-and-inputs-to-stmt append-list append-stmt-var append-to-block convert-mu find-or-create-typeinfo find-or-create-typeinfo-fields find-or-create-typeinfo-output-var find-typeinfo lookup-or-define-var lookup-var lookup-var-helper lookup-var-or-literal new-block-name new-literal new-literal-integer new-reg-var-def new-var new-var-def new-var-from-slice next-mu-token parse-mu parse-mu-block parse-mu-named-block parse-mu-stmt parse-mu-var-def parse-type parse-type-tree parse-var-with-type populate-mu-function-body populate-mu-function-header pos-or-insert-slice pos-slice stmt-has-outputs?
* mu.subx: third test passingKartik Agaram2020-05-181-24/+57
|
* mu.subx: include missing argKartik Agaram2020-05-181-2/+2
| | | | It's not used in these tests, but still confusing.
* mu.subx: lookup-or-define-varKartik Agaram2020-05-181-9/+9
|
* mu.subx: second test passingKartik Agaram2020-05-181-1/+2
|
* mu.subx: add-operation-and-inputs-to-stmtKartik Agaram2020-05-181-27/+46
| | | | ..and append-stmt-var
* mu.subx: lookup-var, lookup-var-or-literalKartik Agaram2020-05-181-20/+31
|
* -Kartik Agaram2020-05-181-18/+14
|
* mu.subx: new-literal-integerKartik Agaram2020-05-181-30/+62
|
* mu.subx: first passing testKartik Agaram2020-05-182-30/+40
| | | | test-parse-mu-var now passing. After I had to extensively fix parse-type.
* -Kartik Agaram2020-05-181-2/+2
| | | | Pass everything so far through translate_subx_debug, which has more error-checking.
* mu.subx: new-reg-var-defKartik Agaram2020-05-181-14/+11
|
* mu.subx: new-var-defKartik Agaram2020-05-181-8/+15
|
* mu.subx: parse-mu-var-def testsKartik Agaram2020-05-181-2/+12
| | | | Still no passing tests; we're just manually translating.
* mu.subx: parse-mu-var-defKartik Agaram2020-05-181-11/+22
|
* mu.subx: parse-mu-stmtKartik Agaram2020-05-181-14/+25
|
* mu.subx: parse-mu-block and parse-mu-named-blockKartik Agaram2020-05-181-28/+70
|
* mu.subx: more progress on parse-mu-blockKartik Agaram2020-05-181-4/+12
|
* -Kartik Agaram2020-05-181-60/+77
| | | | | | | | Trying to switch gears a bit and scope out how much is left. Code-generation should be a lot less work since few signatures need to change. Hopefully getting to 55% down mu.subx will really be 90% of the way. In particular, there are 17 signature changes remaining that need to patch their calling functions as well.
* -Kartik Agaram2020-05-181-1/+1
|
* mu.subx: mu-block-nameKartik Agaram2020-05-181-29/+32
|
* mu.subx: append-to-blockKartik Agaram2020-05-181-3/+6
| | | | | | | | I'm just cleaning up the final call to append-list, and it's internally consistent if `block` can be an `addr`. I don't know yet if that makes sense for callers. I think I also found a bug in append-to-block: it was clobbering eax.
* mu.subx: append-listKartik Agaram2020-05-181-30/+52
| | | | | populate-function-header _almost_ done. I think we just need to fix `push` next.
* mu.subx: parse-var-with-typeKartik Agaram2020-05-181-7/+2
|
* mu.subx: parse-type-treeKartik Agaram2020-05-181-20/+31
|
* mu.subx: parse-typeKartik Agaram2020-05-182-33/+26
|