Another month gone, so quickly. What the heck did I do? It’s difficult to recall, but my git history is helping.
It seems my major accomplishments this month were:
- implemented automatic unit testing for the AO dictionary (runs all `test.` words)
- implemented an automatic type analysis based on partial evaluation
- implemented a few list processing functions (e.g. nub, partition, sort, map, each)
- simplified and optimized fixpoint combinator (15 ABC prims, from 80)
- cleaned up the conditional behavior words (e.g. `if` and `if_`).
- partially developed an incremental processes model (based on `µP.[a→(P*b)]`)
Not too bad, but I can’t say I’m entirely satisfied. I had an aha-moment idea for direct compilation of ABC into a Haskell monad (to improve bootstrap performance) but that ran into a wall. After picking up the pieces and removing the debris, all I had left of that effort was the typechecker. I also ended up removing adverbs, after experimenting with the idea and finding I needed more specialization for context and category (e.g. lists vs. streams vs. automata).
Ah, six steps forward, two steps back. That’s progress.
My plans for the next month are to start building functions for data structures: maps/records, sequences, streams. And to further fill out the set for lists. I hope to get far enough along that I can start modeling grammars in April. At the moment, I have 844 words in AO, of which slightly more than half (440) are documentation (`doc.`), tests (`test.`), or assertions (`id.` or `eqv.`). I don’t know how many words I’ll need to bootstrap an ABC or AO compiler – quite a few, I imagine, but hopefully fewer than 10k. Regardless, I need to pick up the pace.
More subjectively, I quite enjoy programming in my new language.
The REPL plus automatic tests mix is very effective. I’d still like some automatic visualization and continuous feedback tools, and I very strongly look forward to rendering colors/styles instead of suffixes/prefixes for large words. But I’m not desparate for these features. AO has been delightful in its simplicity, security, safety, and flexibility. The first-class nature of the environment gives me much greater feeling of ‘control’ than I’ve felt in other languages. Going back to Haskell is starting to feel a little painful.
My main pain point for AO right now is the awful interpreted performance. I’ll be a lot happier with AO when I can compete with other languages for performance.
Two backward/six forward sounds pretty good to me. Good luck with the next stage.
I’m interested in your incremental process µP.[a→(P*b)] thing. (I assume that’s a single step of evolution of a recursive proc.) How does that fit in with RDP?
Your assume correctly what `µP.[a→(P*b)]` describes. RDP doesn’t retain state from instant to instant. Incremental processes can be useful in RDP for processing of large values within a logical instant, similar to folds. They’re also useful for modeling objects (assuming dependent types). Outside of RDP, incremental processes can be used to model long-running imperative/functional processes, and are potentially useful to implement RDP. (AO isn’t limited to the RDP paradigm.)
Plenty of time to optimize performance later, right? That’s what they always tell me, anyway…
Yeah. Modulo a little frustration during bootstrap, it won’t make much of a difference whether I optimize now vs. later.
I would like greater performance for its own sake, though… a proof of concept, of sorts. ABC is designed to be highly optimizable, but the cost is that it needs optimization to compete with more conventional models.