Commit Graph

18 Commits

Author SHA1 Message Date
Kartik Agaram 5a9795bb66 4881 2018-12-28 08:56:21 -08:00
Kartik Agaram 044b413021 4879 2018-12-28 02:07:11 -08:00
Kartik Agaram dd08c9e69b 4863 2018-12-10 00:14:49 -08:00
Kartik Agaram 33e7c3a751 4846
Clean up a few things:

a) Call scan-next-byte in hex.subx with the right number of args. Turns
out tests continue to work fine if they never use the other args.

b) Tear down a test for 'stop' in the right order. Not important since we
have no EBP to restore. But can still be misleading.

c) Have 'check-ints-equal' return nothing. Handy for it to not mess up
EAX. I never use the result anyway, and the name also is imperative suggesting
callers won't expect a return value.
2018-12-06 09:34:55 -08:00
Kartik Agaram cf02c20bb0 4832
Let's start adding ':end' labels in all functions, just because it helps
us visualize where function calls end in traces, thanks to the '--map'
commandline argument.
2018-12-04 00:29:06 -08:00
Kartik Agaram 9d27e966b5 4808 - clean up comments in all subx files 2018-11-30 16:45:15 -08:00
Kartik Agaram ee9a9237d6 4802
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
2018-11-30 11:13:36 -08:00
Kartik Agaram 6030d7e2e5 4801
Reindent all SubX code to make some room for the new comment style.
2018-11-30 10:54:42 -08:00
Kartik Agaram d1e5e391c7 4788 2018-11-27 12:06:08 -08:00
Kartik Agaram 2131b055f5 4787 2018-11-27 12:04:53 -08:00
Kartik Agaram e5cbbea435 4780 2018-11-26 00:26:20 -08:00
Kartik Agaram 6ee77ba7bb 4760 2018-11-21 22:25:26 -08:00
Kartik Agaram 4e647f4f21 4759 2018-11-20 23:18:49 -08:00
Kartik Agaram 0e6f3d086e 4737 2018-10-30 22:32:38 -07:00
Kartik Agaram 93be389bef 4731 2018-10-28 12:41:04 -07:00
Kartik Agaram eb9087635b 4729
Start injecting all dependencies in the Crenshaw compiler app.

In the process I realized the non-fake code path of 'stop' had a bug.
2018-10-28 00:19:46 -07:00
Kartik Agaram 261b1b8056 4719 - testable interface wrapping around exit() 2018-10-24 22:21:59 -07:00
Kartik Agaram f3612481b1 4713
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.
2018-10-21 21:17:22 -07:00