about summary refs log tree commit diff stats
path: root/subx/ex7.subx
Commit message (Collapse)AuthorAgeFilesLines
* 4529 - move examples to a sub-directoryKartik Agaram2018-09-011-64/+0
|
* 4514 - prefix jump targets with function nameKartik Agaram2018-08-121-2/+2
| | | | | | | | I'd been planning next to automatically namespace jump targets in different functions. But just a check for duplicate labels should suffice, and managing unique names isn't a huge burden. I'm wary of growing the translator too much. All this will eventually need to be self-hosted in SubX.
* 4512 - divide labels into two categoriesKartik Agaram2018-08-121-2/+2
| | | | | | | | | Targets you can jump to and ones you can call are conceptually disjoint sets. I'm highlighting these in Vim, but it's a pretty complex pattern. Arguably errors shouldn't be highlighted. Only warnings that are easy to be accidentally deployed.
* 4508Kartik Agaram2018-08-121-1/+1
|
* 4475Kartik Agaram2018-08-041-26/+0
|
* 4472 - experiment: help read the long linesKartik Agaram2018-08-041-25/+25
|
* 4467Kartik Agaram2018-08-031-28/+28
|
* 4465Kartik Agaram2018-07-301-2/+2
|
* 4456 - example with function calls: factorialKartik Agaram2018-07-301-0/+90
I found a bug with multiply in the process; another case (after the swap of call/jump opcodes in 4453) where there's no point improving testing. Unit tests can only tell us if our instructions are internally consistent. Validating against a real machine has to be manual. I'm definitely feeling the pain of debugging machine code now, that's for sure. Going over an instruction trace, comparing the state of registers line by line.