Charles Childers


blog | parable | retro | ios apps | fountain pens


Updates: May 2016

It's been a long while since my last post, so here's what's going on in my projects:

Parable

I've been working on adding significant internal commentary, cleaning up and reorganizing the source. This marks the start of something new: I'm now using Markdown for my source files, with a simple script to convert the Markdown into Python (or other languages) at build time. This step towards a literate programming style should be helpful to me in maintaining the codebase as it grows and evolves.

Release 2016.05 should be out on the 30th or 31st with the completed commentary and improvements.

After this I plan to focus on the interfaces a bit, and continue debugging and making the core language more stable.

I did a little work on an embedded Parable, but it's going to be very difficult to do this right. Parable assumes a system with significant memory. While it's possible to work around this, it's slow and not ideal. I'm putting this on the backburner for now. I may revisit it later this year or sometime next, when I have the core language to a reliable, well documented state.

PL/0

I dusted off some work on a PL/0 compiler I was lightly involved in back in 2012. I've updated the source to work with Python 3, rewritten the Parable and Retro targets, and intend to add additional targets in the coming months. It's an interesting little language, and offers a nice diversion from Parable when I need something different.

Nga

Retro runs on a virtual machine called Ngaro. This VM has seen some evolution during its life, but hasn't been updated in quite a while.

Nga is a possible successor. It has a slightly smaller, cleaner instruction set, and returns to an overall simpler implementation . Like Parable this is being written in a literate style, so it should be hopefully easier for implementors to see what I've done in my approach.

Here's the instruction set:

0  nop        7  jump      14  gt        21  and
1  lit <v>    8  call      15  fetch     22  or
2  dup        9  if        16  store     23  xor
3  drop      10  return    17  add       24  shift
4  swap      11  eq        18  sub       25  zret
5  push      12  neq       19  mul       26  end
6  pop       13  lt        20  divmod

27 opcodes. The memory model remains the same: a linear array of 32-bit signed integers, addressed from zero.

The biggest changes are:

Nga doesn't provide any simulated I/O devices. As in Parable, the user can implement these as desired.

Currently there's nothing significant using Nga. It's still early in its life, and I'm working on both the implementation and some tooling around it. So far I have beem working on:

It's quite possible that I'll do a Forth for this in the future. It may not be Retro though. I'd kind of like to make a more minimal, traditional style Forth again...

Personal

I've begun to make some big changes in my lifestyle to hopefully help improve my overall health.

This month I began a ketogenic diet. The early results are promising: my fasting blood sugar has dropped to 160 (down from over 400), my weight has started to drop, and I feel better overall.

I also resumed biking. I stopped not long after the accident last fall, and it feels really good to be getting back into this. I've added a mile to my morning ride, in the same time I used to take, and will hopefully see this improve further as the weather improves.