about summary refs log tree commit diff stats
path: root/subx/apps
Commit message (Collapse)AuthorAgeFilesLines
* 4821Kartik Agaram2018-12-025-82/+0
|
* 4819Kartik Agaram2018-12-023-5/+5
|
* 4818Kartik Agaram2018-12-022-12/+13
|
* 4815Kartik Agaram2018-12-022-8/+18
|
* 4813Kartik Agaram2018-12-012-2/+2
|
* 4812Kartik Agaram2018-11-303-4/+4
|
* 4810Kartik Agaram2018-11-302-0/+0
|
* 4808 - clean up comments in all subx filesKartik Agaram2018-11-303-189/+183
|
* 4803Kartik Agaram2018-11-301-128/+128
|
* 4802Kartik Agaram2018-11-303-261/+261
| | | | | | | | | | | | | | | | Some automated commenting cleanup. Still needs more careful manual scanning. sed -i 's/^# 1-3/# . 1-3/' *.subx */*.subx sed -i 's/^# op/# . op/' *.subx */*.subx sed -i 's/# vim/# . . vim/' *.subx */*.subx sed -i 's/^ # push args/ # . . push args/' *.subx */*.subx sed -i 's/^ # discard args/ # . . discard args/' *.subx */*.subx sed -i 's/^ # call/ # . . call/' *.subx */*.subx sed -i 's/^ # prolog/ # . prolog/' *.subx */*.subx sed -i 's/^ # epilog/ # . epilog/' *.subx */*.subx sed -i 's/^ # save registers/ # . save registers/' *.subx */*.subx sed -i 's/^ # restore registers/ # . restore registers/' *.subx */*.subx sed -i 's/ operand / register /' *.subx */*.subx
* 4801Kartik Agaram2018-11-303-1060/+1060
| | | | Reindent all SubX code to make some room for the new comment style.
* 4800Kartik Agaram2018-11-302-10/+11
|
* 4799Kartik Agaram2018-11-301-4/+4
|
* 4797Kartik Agaram2018-11-302-2/+2
|
* 4796Kartik Agaram2018-11-301-146/+146
|
* 4776Kartik Agaram2018-11-252-1/+1
| | | | | | | | | | | | | Crenshaw compiler now runs natively as well. It turns out I was misreading the Intel manual, and the jump instructions that I thought take disp16 operands actually take disp32 operands by default on both i686 and x86_64 processors. The disp16 versions are some holdover from the 16-bit days. This was the first time I've used one of these erstwhile-disp16 instructions, but I still haven't tested most of them. We'll see if we run into future issues.
* 4775Kartik Agaram2018-11-244-213/+847
| | | | | | | Start with an exactly corresponding version to Crenshaw 2-1: single-digit numbers. The only change: we assume the number is in hex. The next version now supports multi-digit hex numbers.
* 4774Kartik Agaram2018-11-242-19/+2
| | | | Simplification.
* 4773 - done with crenshaw chapter 2-1Kartik Agaram2018-11-242-7/+121
| | | | In the process I had to fix a couple more bugs in support for disp16 instructions.
* 4770Kartik Agaram2018-11-241-6/+6
|
* 4768Kartik Agaram2018-11-242-0/+0
|
* 4766Kartik Agaram2018-11-241-3/+4
|
* 4765Kartik Agaram2018-11-231-1/+2
|
* 4764Kartik Agaram2018-11-232-5/+221
|
* 4763 - back to the 'trivial' crenshaw2-1 compilerKartik Agaram2018-11-232-2/+422
| | | | | This time I've ported (and test-driven) 'GetChar' and 'GetNum'. The new tests bring together our new testable interfaces for read() and exit().
* 4756Kartik Agaram2018-11-192-0/+0
| | | | | Long-standing and long-copied typo has been messing with our exit status on test failures.
* 4755 - read-byte (sometimes called getchar)Kartik Agaram2018-11-192-0/+0
|
* 4747 - subx: 'read' primitiveKartik Agaram2018-11-182-0/+0
|
* 4745Kartik Agaram2018-11-172-0/+0
|
* 4743Kartik Agaram2018-11-122-0/+0
|
* 4741Kartik Agaram2018-10-302-0/+0
| | | | Extract a helper that we'll need for 'read'.
* 4740Kartik Agaram2018-10-302-0/+0
|
* 4736Kartik Agaram2018-10-292-0/+0
| | | | | | | | | We'll use a common stream data structure for input and output streams. Having separate types makes more sense in a more high-level language, where we have type checking and where functions for handling the different types are more concise. But in machine code the sweet spot is more toward fewer types.
* 4733Kartik Agaram2018-10-281-1/+1
|
* 4732Kartik Agaram2018-10-281-0/+0
|
* 4731Kartik Agaram2018-10-282-11/+11
|
* 4729Kartik Agaram2018-10-283-38/+50
| | | | | | Start injecting all dependencies in the Crenshaw compiler app. In the process I realized the non-fake code path of 'stop' had a bug.
* 4721Kartik Agaram2018-10-242-0/+0
|
* 4713Kartik Agaram2018-10-212-0/+0
| | | | | | | | Initial sketch of a dependency-injected wrapper around the exit() syscall. I don't have the primitives yet, just a sketch of how they should work -- and a passing test for non-local jumps without support for passing the exit status to the caller.
* 4711Kartik Agaram2018-10-172-0/+0
| | | | | | | Extract a helper for appending strings to raw buffers. I'd been resisting this idea, but it actually turns out to be a pretty clean abstraction in the end.
* 4710Kartik Agaram2018-10-173-8/+8
| | | | | Start using write() instead of _write().. and we promptly find a typo when dealing with real file descriptors.
* 4707 - subx: dependency-injected write() primitiveKartik Agaram2018-10-162-0/+0
|
* 4703Kartik Agaram2018-10-161-4/+4
|
* 4700Kartik Agaram2018-10-161-2/+2
|
* 4699Kartik Agaram2018-10-143-43/+16
|
* 4698Kartik Agaram2018-10-141-4/+4
|
* 4697Kartik Agaram2018-10-142-0/+0
|
* 4691Kartik Agaram2018-10-132-0/+0
| | | | All tests now once again run the same natively and on VM.
* 4684Kartik Agaram2018-10-113-2/+3
| | | | | | | | | | Turns out the tests for 'trace' have been broken in native mode since the original commit (4674). Dangers of running my tests on Darwin, where I can't run them natively. The test failures didn't get flagged on CI because I'd forgotten to update the exit code of the factorial app in commit 4664. At least that's fixed in this commit.
* 4682 - subx: start testing all layers of 'library'Kartik Agaram2018-10-102-0/+0
|