Commit Graph
100 Commits
Author SHA1 Message Date
MightyPork 1e6e45ea72 use se32 in the bmp example 2020-10-15 01:05:12 +02:00
MightyPork 22cbfeb4ff have the sign extend instructions also extend zero sign 2020-10-15 00:55:11 +02:00
MightyPork 5b163e969f add the "lds" instruction 2020-10-15 00:53:59 +02:00
MightyPork 01ab4e7e1f add sign extend commands 2020-10-15 00:41:07 +02:00
MightyPork 3b9e89674c add a pikachu hint 2020-10-14 22:18:18 +02:00
MightyPork 0a182fb91a add bmp parser example 2020-10-14 22:05:10 +02:00
MightyPork ff84a7a481 add build scripts for native and musl 2020-10-11 23:03:28 +02:00
MightyPork 7efa04054c make it work with musl (the _nox target does not link the screen module that wouldn't build) 2020-10-11 22:56:48 +02:00
MightyPork 4cf24f0382 new examples 2020-10-11 22:34:11 +02:00
MightyPork c953e39b34 Add ld{32,16,8},sw{32,16,8},clz{,32,16,8},clo{,32,16,8},rng,rev,rbit; rename swap->xch 2020-10-11 22:01:12 +02:00
MightyPork 4062ff4d09 AMAZING NEW FEATURES ldn, bfio 2020-10-11 01:35:19 +02:00
MightyPork 74e3716ce4 change register count to 15, add global registers 2020-10-10 23:28:29 +02:00
MightyPork 9254635fd7 add examples; do not hard-shutdown when screen is closed - destructors did not run! 2020-10-10 22:25:26 +02:00
MightyPork c28fee88fe use 'spin_sleep' for more accurate execution rate, add "s", "m", "u" suffix support to the -C argument 2020-10-10 20:41:46 +02:00
MightyPork f2073fe7f4 improve the rev example 2020-10-10 18:58:35 +02:00
MightyPork acc36b1959 document the eof, empty and full flags 2020-10-10 18:56:35 +02:00
MightyPork 4d921cbec0 update docs about stdin renaming to cin 2020-10-10 18:49:40 +02:00
MightyPork ace92a6411 rewrite the stdio module to be less broken. also add sehbang support 2020-10-10 18:46:32 +02:00
MightyPork 982ba27ed3 cleanup, auto deref Wd, Wr, RdObj 2020-10-10 15:45:01 +02:00
MightyPork 7a3cb539e1 add new rdwr access type to guard against illegal writes that can be caught at compile time 2020-10-10 15:39:18 +02:00
MightyPork 8ea60f52eb remove unused "mask" code 2020-10-10 15:17:39 +02:00
MightyPork 3a8895b790 add rcmp instr, add rot13 example 2020-10-10 14:31:07 +02:00
MightyPork e48d734615 readme add codeblock annotations 2020-10-10 14:04:02 +02:00
MightyPork 4677625d51 readme fix 2020-10-10 14:02:48 +02:00
MightyPork 06b449004d document the swap instr 2020-10-10 14:02:22 +02:00
MightyPork d5821e3552 add "swap" instr, document buffer ops 2020-10-10 13:59:45 +02:00
MightyPork aae9db0598 fix branch parser eating all list tokens 2020-10-10 12:26:50 +02:00
MightyPork 9aee9ca143 add reverse example 2020-10-10 01:53:10 +02:00
MightyPork ee59096821 buffer module, replacing stacks. TODO: docs, fix parsing of "numbers tuple" in mkbfv (consumed by the conditional branch parser) 2020-10-10 01:26:40 +02:00
MightyPork 1f2dbaa81d add better string and number parsing to sexp. cleaning, more tests 2020-10-09 00:41:09 +02:00
MightyPork 548addc78c add a line about contributing 2020-10-08 14:41:09 +00:00
MightyPork 034c7b991f improve readme and example of the stdio module 2020-10-08 00:56:59 +02:00
MightyPork 9d7f3d25c8 add stdio module 2020-10-08 00:42:24 +02:00
MightyPork e3fe3c6d72 performance improvements 2020-10-07 23:40:00 +02:00
MightyPork a3eae0a8a9 add extension hook to pre-define constants 2020-10-07 22:31:50 +02:00
MightyPork 4115e07ee6 @reg and @value reading and writing is now possible 2020-10-07 22:24:30 +02:00
MightyPork 562fc48151 add support for character literals using single quotes 2020-10-07 19:27:30 +02:00
MightyPork ce5bf513c0 stricter label parsing, more relaxed identifier rules 2020-10-07 19:10:52 +02:00
MightyPork 0cc0be370f fix error in readme 2020-10-07 18:48:58 +02:00
MightyPork 5686ad7bd3 add script to test that all examples compile 2020-10-07 18:35:13 +02:00
MightyPork 6b685dcaa3 add docs for the screen module 2020-10-07 15:28:13 +02:00
MightyPork 003a214e06 update docs 2020-10-07 11:15:30 +02:00
MightyPork 017ec53b14 Merge branch 'spanned-sexp' into master 2020-10-06 23:27:06 +02:00
MightyPork dbc4454244 cleaning; optimize screen_bounce.csn 2020-10-06 23:26:52 +02:00
MightyPork 214d673643 remove junk, better explain whats going on with spanned_sexp 2020-10-06 23:17:47 +02:00
MightyPork 33ec1461e4 remove unnecessary cloning of SourcePosition, reduce SourcePosition size. clean, format 2020-10-06 23:12:11 +02:00
MightyPork 91573140a4 all errors now contain source location 2020-10-06 22:54:34 +02:00
MightyPork d4534c9c66 sexp: add span info to Sexps 2020-10-06 20:23:43 +02:00
MightyPork 0fd1c9980b sexp: move error defs to a module 2020-10-06 19:52:00 +02:00
MightyPork 6dfe22152c sexp: replace logging with log crate trace macro 2020-10-06 19:44:15 +02:00
MightyPork 7272eecc48 sexp automated format & cleanup 2020-10-06 19:40:56 +02:00
MightyPork 3cb445a31c sexp: tests to submodule 2020-10-06 19:40:16 +02:00
MightyPork a2dada519d sexp: replace try! with ? 2020-10-06 19:38:13 +02:00
MightyPork 250f0f22c0 cargo fix 2020-10-06 19:37:12 +02:00
MightyPork 85911c8e99 add sexp into source tree 2020-10-06 19:37:12 +02:00
MightyPork f404445003 deny direct access to symmed register - prevents bugs 2020-10-06 12:39:39 +02:00
MightyPork 2fa23dbbc3 start program without spawning thread so screen works on mac. improve mouse demo 2020-10-06 12:28:49 +02:00
MightyPork f4ced467e4 add rpush and rpop stack instructions 2020-10-06 12:18:07 +02:00
MightyPork 7ce51c0cc6 check close condition on poll 2020-10-05 23:40:07 +02:00
MightyPork 583ac7bcbf mouse and key input, handle close btn, mouse demo 2020-10-05 23:37:39 +02:00
MightyPork 6eef2b7ae3 cleaning 2020-10-05 22:13:43 +02:00
MightyPork fe8bf87e6d add round-trip tests for built-in instructions 2020-10-05 21:57:59 +02:00
MightyPork 05104c93ca fix ld printed as mov 2020-10-05 00:35:04 +02:00
MightyPork 34e339b1ca add pretty-printer for assembled instructions 2020-10-05 00:32:08 +02:00
MightyPork 986f3be6a2 cleanup. remove conditional jumps, replaced by condition embedded in the enum 2020-10-04 23:30:11 +02:00
MightyPork 810ed2dddc optimize labels, jumps 2020-10-04 22:45:34 +02:00
MightyPork b06ef50acd surround routines by far jump across 2020-10-04 21:26:06 +02:00
MightyPork e0cc1973ba Routine arity disambiguation, slash syntax (add/2, add/3) 2020-10-04 13:28:14 +02:00
MightyPork 8d585d765b stacks example 2020-10-01 23:36:33 +02:00
MightyPork 651ffcb888 new test 2020-10-01 23:33:42 +02:00
MightyPork 6d8d0fd51a show unsym and undef in the aliases example 2020-10-01 23:31:42 +02:00
MightyPork 4336454156 add unsym and undef 2020-10-01 23:29:49 +02:00
MightyPork e580a2b679 Add "sym" and "def" instructions, add argument naming 2020-10-01 23:26:06 +02:00
MightyPork afd412f22a make more stuff public for use by extensions 2020-09-30 23:19:34 +02:00
MightyPork 822e7912aa cleanup 2020-09-30 23:17:33 +02:00
MightyPork 4be5b4e05b generalize parsing to allow extensions to add arbitrary syntax; add 'proc' keyword to introduce a routine. 2020-09-30 23:16:22 +02:00
MightyPork d47d0f2345 add note about log level 2020-09-29 13:37:16 +02:00
MightyPork 0b168b5f5d add example config file, add default config file to gitignore 2020-09-29 13:31:16 +02:00
MightyPork c37408c7a2 read program from file; fmt, cleanup 2020-09-29 13:27:54 +02:00
MightyPork 01068ea001 crazy hypno + added sleep cmd 2020-09-29 00:40:11 +02:00
MightyPork 532df6eb04 screen imrpvoements 2020-09-29 00:22:42 +02:00
MightyPork d19c4e5bea add experimental framebuffer extension using minifb 2020-09-28 22:16:19 +02:00
MightyPork b7345144e0 refactors 2020-09-28 20:58:30 +02:00
MightyPork 2269d759c6 refactors 2020-09-28 20:44:37 +02:00
MightyPork 3599cb46c4 cleanup, optimize. use Arc for reference sharing 2020-09-28 20:12:31 +02:00
MightyPork d5de189af6 add more sensible API for object handles, add drop instruction 2020-09-28 19:36:15 +02:00
MightyPork 79d5aa3cd5 renaming, cleanup, fmt, move "extension module" traits and structs into a separate mod 2020-09-28 13:55:56 +02:00
MightyPork 8222efe6da remove "immediate ptr" data type, move read, write funcs to RunState, add %objectPtr syntax 2020-09-28 01:01:57 +02:00
MightyPork d489b214e0 add a readme 2020-09-27 00:13:08 +02:00
MightyPork be1ee66970 make exec speed configurable 2020-09-26 23:08:04 +02:00
MightyPork 0cd800653f Example extension: Stacks; fixes to allow module data storage in thread context 2020-09-26 22:49:06 +02:00
MightyPork 3e0aaa71e9 Convert builtin ops into a pseudo-extension 2020-09-26 22:00:27 +02:00
MightyPork 1d444fd516 cleaning 2020-09-26 21:06:34 +02:00
MightyPork ba0e3d0fd2 preparations for module data storage, remove broken tests (dyn trait can't implement PartialEq because ???) 2020-09-26 20:13:41 +02:00
MightyPork 44e7cd3a8f renames, improve module API (avoid cloning) 2020-09-26 19:01:40 +02:00
MightyPork f015104b95 re-arrange modules, add "plug-in" system so instructions can be defined in multiple crates 2020-09-26 00:29:33 +02:00
MightyPork 547beed847 comments, refactor 2020-09-25 23:02:54 +02:00
MightyPork 8f076e195a format 2020-09-25 22:53:19 +02:00
MightyPork f493cc102a add "_" pattern for explicitly specifying the "discard" destination (may be used for side effects) 2020-09-25 22:52:02 +02:00
MightyPork 8e7689df48 add explicit retval arg to all instrs (can be shortened), add Wr::discard() 2020-09-25 22:45:57 +02:00