Commit Graph

23 Commits

Author SHA1 Message Date
Kartik Agaram 7e7a8a6eae 5876 - address -> addr 2020-01-03 01:36:34 -08:00
Kartik Agaram 2a2a5b1e43 5804
Try to make the comments consistent with the type system we'll eventually
have.
2019-12-08 23:31:05 -08:00
Kartik Agaram 68719bebc0 5794
Rather surprisingly, all the treeshake tooling is done in just about 2
hours of work. From now on it'll be easier to update stats.txt. Observations:

a) Binaries are tiny compared to conventional stacks. Tens of KB.
b) ~80% of binaries are tests and unused libraries in all my apps.
c) ~75% of LoC in SubX sources are tests or comments.
2019-12-06 01:12:08 -08:00
Kartik Agaram 686a52bd2e 5790
Standardize conventions for labels within objects in the data segment.

We're going to use this in a new tool.
2019-12-05 22:57:51 -08:00
Kartik Agaram 931b17daa0 5782 - fix a widespread bug with Heap-size 2019-11-30 11:14:49 -08:00
Kartik Agaram 70187b1c01 5765
A couple more primitives now working. In the process I ran into an issue
with some buffer filling up when running ntranslate. Isolating it to survey.subx
was straightforward, but --trace ran out of RAM, and --trace --dump ran
out of (7GB of) disk. In the end what helped was just repeatedly inserting
exits at different points, and I realized there was a magic number that
hadn't been turned into a named constant.
2019-11-26 22:11:23 -08:00
Kartik Agaram 0fba3393a5 5715
Clean up pseudocode to match planned syntax for the type- and memory-safe
level-2 Mu language.

http://akkartik.name/post/mu-2019-2 is already out of date.
2019-10-26 23:42:27 -07:00
Kartik Agaram f0b7e327c5 5714
Replace calculations of constants with labels.
2019-10-25 06:10:36 -07:00
Kartik Agaram 5409743432 5700 2019-10-17 21:59:51 -07:00
Kartik Agaram 7a5832204a 5698
Thanks Andrew Owen for reporting this typo.
2019-10-15 19:35:19 -07:00
Kartik Agaram fd91f7f61b 5675 - move helpers from subx-common into layers
This undoes 5672 in favor of a new plan:

Layers 000 - 099 are for running without syntax sugar. We use them for
building syntax-sugar passes.

Layers 100 and up are for running with all syntax sugar.

The layers are arranged in approximate order so more phases rely on earlier
layers than later ones.

I plan to not use intermediate syntax sugar (just sigils without calls,
or sigils and calls without braces) anywhere except in the specific passes
implementing them.
2019-09-19 23:25:49 -07:00
Kartik Agaram a9d473e224 5668 - start reorg to permit syntax sugar in layers
Right now we always build the library before any apps.
Apps are where our syntax sugar translators (sigils, calls, braces) live.
So we can't use sugar in the standard library.

New idea: move all code for SubX phases into the top-level.
Perhaps we should also just build a single file rather than pipeline stages.
But for now we'll build each phase by building up to some specific layer.

This will simplify test_apps and move lots of one-off logic to a more standard
form in test_layers.

I'm also going to reorg existing layers so that we introduce each phase
at a point where it mostly only gets the helpers it needs.

This commit itself is just cleaning up some common strings. Using explicit
names for them streamlines binaries a bit.
2019-09-19 15:12:50 -07:00
Kartik Agaram f39eaf81fa 5661 2019-09-15 00:29:52 -07:00
Kartik Agaram 604c8315bd 5607 2019-09-01 23:57:29 -07:00
Kartik Agaram 282681c729 5600 2019-08-31 23:42:45 -07:00
Kartik Agaram 333525360b 5592 - switch register names to lowercase 2019-08-26 11:59:21 -07:00
Kartik Agaram e0d034b565 5590 2019-08-25 23:33:49 -07:00
Kartik Agaram fc55af70a5 5589 2019-08-25 23:25:08 -07:00
Kartik Agaram be063736d0 parsing *(reg+disp) 2019-08-24 23:42:04 -07:00
Kartik Agaram bfb2a8c0f0 get desugar working on the commandline 2019-08-13 10:57:05 -07:00
Kartik Agaram 15a84e2449 better error message when get aborts 2019-08-12 23:18:31 -07:00
Kartik Agaram 1ed1d1c842 5499 2019-07-31 15:28:23 -07:00
Kartik Agaram 6e1eeeebfb 5485 - promote SubX to top-level 2019-07-27 17:47:59 -07:00