Commit Graph

495 Commits

Author SHA1 Message Date
Jeremiah Orians 0805284391
Hex1 assembler optimization to reduce size and number of clock cycles
required to process input
2017-12-17 21:29:35 -05:00
Jeremiah Orians 0ad7d92437
Added program for finding characters invisible to human readers 2017-12-17 19:08:37 -05:00
Jeremiah Orians fa9cfb940e
Allow removal of watchpoints 2017-12-16 20:48:38 -05:00
Jeremiah Orians 2dcb5017a1
Updating documentation 2017-12-16 18:54:38 -05:00
Jeremiah Orians 45d9394d43
Eliminated stage1_assembler-0's need for memory 2017-12-16 18:51:51 -05:00
Jeremiah Orians 785af749a8
Make memory interaction more flexible and better match various sizes 2017-12-16 17:58:51 -05:00
Jeremiah Orians c67bbc8fff
Fix labels and improve comments 2017-12-16 16:40:26 -05:00
Jeremiah Orians 0e23b418ae
Continue expanding vm flexiblity in regards to various future enhancements 2017-12-16 13:53:59 -05:00
Jeremiah Orians 41eb315dd3
Preparing for large and small register tests 2017-12-11 22:55:03 -05:00
Jeremiah Orians 7a6aeb42bc
Fixed regression in hex.c 2017-12-11 18:50:53 -05:00
Jeremiah Orians d80bcaa678
Replaced case statements for easier compile 2017-11-20 21:01:36 -05:00
Jan Nieuwenhuizen 137e8b7139 makefile: use $(CC) 2017-11-19 09:53:50 +01:00
Jan Nieuwenhuizen 14843efa5e Make hex.c more mescc friendly to simplify bootstrapping 2017-11-19 09:52:14 +01:00
Jeremiah Orians c4cd93bc24
web IDE behavior enhancement 2017-09-16 13:44:38 -04:00
Jeremiah Orians 2b7e24e31c
Forgot to update the checksums 2017-09-16 07:46:44 -04:00
Jeremiah Orians 3309e6325e
Correcting the behavior of R@ 2017-09-16 07:41:22 -04:00
Jeremiah Orians 0f7b93de2d
Preparing for next release cycle 2017-08-18 12:22:26 -04:00
Jeremiah Orians c06faa77e0
Release 0.0.9 2017-08-18 12:02:02 -04:00
Jeremiah Orians 9be2763c40
Incorporated number? and symbol? into stage2 lisp 2017-08-18 11:41:21 -04:00
Jeremiah Orians 1926a9d6b7
Added list->string primitive to stage2 lisp 2017-08-18 11:15:59 -04:00
Jeremiah Orians f835312b3c
Fixing documentation for initial malloc pointer. Tempted to make CONS
array be malloc'd to simplify the address space
2017-08-18 08:32:58 -04:00
Jeremiah Orians 4c187f68b4
Ensured compliance with new stage0 assembler standard 2017-08-04 21:05:33 -04:00
Jeremiah Orians b9f6ecb0bc
Improving stage0 VM documentation 2017-08-04 20:55:06 -04:00
Jeremiah Orians ec47252222
Accidentally forgot to update the checksums 2017-07-30 21:56:11 -04:00
Jeremiah Orians 437bfe90b7
Removed unrequired primitive 2017-07-30 21:54:27 -04:00
Jeremiah Orians 21e06a6dfa
Bunch of renames and 1 new internal function for future use 2017-07-30 21:14:25 -04:00
Jeremiah Orians 51c7c98a05
Adding string? primitive to stage2 lisp 2017-07-30 21:01:09 -04:00
Jeremiah Orians 157bec9609
Added char? primitive to stage2 lisp 2017-07-30 20:53:23 -04:00
Jeremiah Orians ef68ad2d3b
Added string->list to stage2 lisp 2017-07-30 20:38:56 -04:00
Jeremiah Orians 7619d6c779
Added char->integer and integer->char 2017-07-30 18:42:36 -04:00
Jeremiah Orians f3f8ec5a32
Implemented basic raw string support in stage2 lisp, many more
enhancements required to make it fully useful
2017-07-30 18:04:29 -04:00
Jeremiah Orians 5b302ba9d0
Actually write to the desired output 2017-07-13 22:01:25 -04:00
Jeremiah Orians efa8689570
Update changelog and add missing copyright notice 2017-07-13 21:16:41 -04:00
Jeremiah Orians 228c8b20e2
Function to help beginners 2017-07-13 20:51:57 -04:00
Jeremiah Orians 59393b4985
Missed int64_t 2017-07-13 20:08:19 -04:00
Jeremiah Orians e113458a62
Made JUMP-TO use 32bit absolute addresses 2017-07-13 18:24:26 -04:00
Jeremiah Orians 24c1db3ec3
Improved M0 and hex2 notes 2017-07-12 21:11:14 -04:00
Jeremiah Orians 69a77610cf
Minor Forth Tweak 2017-07-12 21:07:53 -04:00
Jeremiah Orians 23b12e0ef9
Fixed lisp's behavior when there is insufficient memory 2017-06-24 11:49:28 -04:00
Jeremiah Orians d3bed26e0a
Correcting error in string output and avoiding segment faults in vm 2017-06-24 11:44:41 -04:00
Jeremiah Orians 4963fcfebc
Implemented graceful FAILURE and PRINT 2017-06-24 10:06:50 -04:00
Jeremiah Orians a51c243088
Implementing LSHIFT and RSHIFT per request 2017-06-24 08:49:08 -04:00
Jeremiah Orians 37b061defc
Ensure changelog, checksums and whitespacing rules are updated and enforced 2017-06-24 08:14:31 -04:00
Caleb Ristvedt 1a6c7d5afe
Fix CREATE, implement DOES>, more words
Implemented some new words in forth.s:
* 'DODOES
  Gives the address of the assembly for DODOES. Used by DOES> when compiling
  machine code to jump to it and activate the following high-level forth
  code. This is how non-primitive actions for a word can be set.
* LATEST!
  Sets the LATEST pointer. For when the user wants to write their own way of
  extending the dictionary (word lists, vocabularies, etc).
* R@
  Copies the top of the return stack to the data stack. Useful for when loops
  start getting non-trivial and you start wondering of all those ROTs aren't
  efficient enough. Maybe someday we'll implement a register-allocating
  compiler. Probably not. Too complicated for bootstrapping.
* Not really words but used: DODOES and DOVAR.
  DOVAR is the default behavior of CREATEd words - it just pushes a pointer to
  whatever was allotted right after the word was created. DODOES is jumped to in
  order to invoke high-level forth behaviors for words.
* Changed behavior of CREATE to better match the way it usually works.

Added some words to inital_library.fs (we should fix that name sometime):
* Added a variable BASE to control what base numbers are printed in.
* Turns out I misunderstood what WORD did and mis-diagnosed an early problem in
  ' - so it turns out that nothing was being allotted in the dictionary, just
  stuff in "string space", which if I understand properly just sort of fills up
  infinitely as long as WORD is being invoked. Some other forths try to solve
  this by introducing an input buffer for the current line, at the cost of some
  complexity (as words like [CHAR] and S" have to take that into
  account). Anyway, the HERE and DP! are gone from ' now.
* Added BOUNDS for common setup for sequence-iterating loops.
* Added region-comment "(" (note that it doesn't nest), used most often for
  stack comments.
* Added hex dump printer DUMP and support words, number of bytes printed per
  line is controlled by LINE-SIZE. It looks pretty nice, much of the design is
  based off of gforth's.
* Added DOES> and supporting words, and used it to make VARIABLE, CONSTANT, and
  DEFER.
* Added TUCK, MIN, SPACES, :NONAME, FILL, and <>.

Add LSHIFT and RSHIFT to the wishlist, as ghetto shifting with division seems to
behave a bit strangely when given negative values.

Also, we're now advanced enough to support the tictactoe I wrote awhile back for
gforth! http://paste.lisp.org/display/349394
2017-06-24 07:40:22 -04:00
Jeremiah Orians 871f8e281d
Added changelog notes to reflect reepa's improvements 2017-06-21 06:14:17 -04:00
Caleb Ristvedt c159b6a927
Refactor, fix bugs, and reword comments in initial_library.fs
Some of the comments seemed a bit off. Additionally, there was a bug in AGAIN
in which it didn't actually compile a jump. Also, WHILE's compile-time stack
effect is now consistent with gforth, which means we can have multi-exit while
loops. Also, added UNTIL. Also, added [CHAR] so we don't have to keep looking up
ascii values for characters. Also, whichever bug it was that caused problems
with splitting definitions up across multiple lines is now gone, so long live
the newlines!
2017-06-21 05:47:43 -04:00
Jeremiah Orians b974bec307
Prepare for next release 2017-06-17 23:04:49 -04:00
Jeremiah Orians db2bc37f1d
Release 0.0.8 2017-06-17 22:51:28 -04:00
Jeremiah Orians 800c867085
Altered EXECUTE into indirection 2017-06-17 22:27:15 -04:00
Jeremiah Orians 3b05f83e6a
Fixed the Carriage return issue and CMOVE zeroing issue 2017-06-17 22:05:33 -04:00