Pete Elmore [Sun, 5 Apr 2015 23:28:43 +0000 (16:28 -0700)]
Merge branch 'master' of github.com:pete/pez
Pete Elmore [Sun, 5 Apr 2015 23:24:08 +0000 (16:24 -0700)]
Attempt to make that memory contiguous.
It speeds things up, but not as much as I'd hoped.
Pete Elmore [Sun, 5 Apr 2015 23:22:58 +0000 (16:22 -0700)]
Add a bug to TODO.
Pete [Thu, 26 Mar 2015 18:08:06 +0000 (11:08 -0700)]
Merge pull request #4 from larsbrinkhoff/master
Make GitHub detect *.pez as Forth
Lars Brinkhoff [Thu, 26 Mar 2015 09:07:32 +0000 (10:07 +0100)]
Make GitHub detect *.pez as Forth
Pete Elmore [Sat, 2 Jun 2012 05:55:02 +0000 (22:55 -0700)]
I love getting to delete m4 files!
Pete Elmore [Sat, 2 Jun 2012 05:54:00 +0000 (22:54 -0700)]
Lightning isn'used any more.
Pete Elmore [Wed, 4 Jan 2012 19:39:39 +0000 (11:39 -0800)]
There is not much to this, but it is a small library for fractions.
Pete Elmore [Wed, 4 Jan 2012 19:38:07 +0000 (11:38 -0800)]
Poke at write and gets a little. Need sighandlers.
Pete Elmore [Wed, 28 Dec 2011 03:45:18 +0000 (19:45 -0800)]
Fix the the spell checker example to use the new FFI.
Pete Elmore [Wed, 28 Dec 2011 03:41:53 +0000 (19:41 -0800)]
Seems lib/prime-sieve.pez had been "staged" but not "committed" for months. GIT!
Pete Elmore [Wed, 28 Dec 2011 03:39:41 +0000 (19:39 -0800)]
New words: pipe, fddup, fddup2. Wrappers around pipe(2), dup(2), dup2(2).
Pete Elmore [Wed, 28 Dec 2011 03:38:47 +0000 (19:38 -0800)]
TODO is a file which will never be zero lines long.
Pete Elmore [Wed, 28 Dec 2011 03:38:30 +0000 (19:38 -0800)]
Put Wolf in the credits, that guy is awesome.
Pete Elmore [Thu, 24 Nov 2011 23:59:33 +0000 (15:59 -0800)]
A couple of minor error-handling fixes, and make bounds-checking the default.
Pete Elmore [Wed, 16 Nov 2011 07:54:51 +0000 (23:54 -0800)]
General cleanup; fix a couple of undefined behaviors and make bounds checking
something you turn off instead of on.
(Incidentally, the overhead for bounds-checking is insanely small for most
of the code I've tested. Might just leave it always on.)
Pete Elmore [Sun, 13 Nov 2011 05:33:24 +0000 (21:33 -0800)]
Reformat comments, and don't be an idiot around pointers.
Pete Elmore [Sun, 13 Nov 2011 05:33:02 +0000 (21:33 -0800)]
Redo TODO
Pete Elmore [Tue, 6 Sep 2011 08:02:39 +0000 (01:02 -0700)]
Take the puts() out, baller style.
Pete Elmore [Tue, 6 Sep 2011 07:37:12 +0000 (00:37 -0700)]
Here I was, worried that adding libtcc to the autotools mess would be a
pain. It was not...yet.
Pete Elmore [Tue, 6 Sep 2011 07:33:42 +0000 (00:33 -0700)]
Dropping Lightning from the FFI in favor of libtcc.
Pete Elmore [Sun, 26 Jun 2011 16:08:12 +0000 (09:08 -0700)]
Incorrectly checked overflow rather than underflow.
Pete Elmore [Thu, 16 Jun 2011 23:09:31 +0000 (16:09 -0700)]
Prefetching IP. This is experimental! Eliminating the pointer-chasing speeds
a lot of operations up by 10-30%, but slows some down (mainly pushing literals)
due to (I suspect without being certain) branch-predictor misses. Getting those
back up to speed involves a reworking of (LIT). My intention is to do one of
these: re-add the (LIT0), (LIT1), etc., words from the old branch; use
lightning to generate (LITx) words as needed; tag literals and only resort to
use of (LIT) when we need all N bits of a cell; revert this patch. Still not
quite certain.
Pete Elmore [Sun, 29 May 2011 00:28:53 +0000 (17:28 -0700)]
New word: w_nohang, flag for wait.
Pete Elmore [Sun, 29 May 2011 00:28:17 +0000 (17:28 -0700)]
New word: rdrop
Pete Elmore [Fri, 3 Dec 2010 03:08:35 +0000 (19:08 -0800)]
Eliminate branches for comparisons. Pfffft.
Pete Elmore [Thu, 18 Nov 2010 08:11:10 +0000 (00:11 -0800)]
New word: 'times', ( word n -- ). It takes a word and a number of times to execute the word.
Pete Elmore [Thu, 18 Nov 2010 08:11:00 +0000 (00:11 -0800)]
I wanted some math.
Pete Elmore [Sun, 14 Nov 2010 06:38:44 +0000 (22:38 -0800)]
Add a couple of float stack manipulators, make 'clear' clear both stacks,
and reorder/trim the interpreter struct. Believe it or not, this made Pez
faster by about 5%.
Pete Elmore [Wed, 27 Oct 2010 06:42:10 +0000 (23:42 -0700)]
New word: log10. Toyed with calling it log[10], wisely chickened out.
Pete Elmore [Sun, 10 Oct 2010 08:59:11 +0000 (01:59 -0700)]
The C preprocessor told me that it was disappoint.
Pete Elmore [Sun, 10 Oct 2010 08:54:15 +0000 (01:54 -0700)]
Done having build issues with what was already a bad idea.
Pete Elmore [Sun, 10 Oct 2010 08:47:30 +0000 (01:47 -0700)]
Moved to the dispenser repo.
Pete Elmore [Sun, 10 Oct 2010 08:46:45 +0000 (01:46 -0700)]
New word: die (like die!, but no message). Fix a bug in waitpid.
Pete Elmore [Fri, 3 Sep 2010 06:31:26 +0000 (23:31 -0700)]
BLOOPSAPHONE!
Pete Elmore [Fri, 3 Sep 2010 04:50:24 +0000 (21:50 -0700)]
There was a bug in the handling of floats/doubles when loading/storing explicit
C types. Discovered while writing an interface for _why's bloopsaphone (for
epic justice; it'll be checked in when it definitely works).
Pete Elmore [Mon, 16 Aug 2010 23:15:54 +0000 (16:15 -0700)]
That changed a long time ago.
Pete Elmore [Mon, 16 Aug 2010 20:54:47 +0000 (13:54 -0700)]
Gone.
Pete Elmore [Sat, 7 Aug 2010 23:08:24 +0000 (16:08 -0700)]
And AWIB ( code.google.com/p/awib/ ) actually won't run without more
cells.
Pete Elmore [Sat, 7 Aug 2010 22:57:17 +0000 (15:57 -0700)]
And this is the solution that should have occurred to me *first*.
Pete Elmore [Sat, 7 Aug 2010 22:55:17 +0000 (15:55 -0700)]
That's the dumb but less hacky version. Next up...
Pete Elmore [Wed, 4 Aug 2010 09:01:17 +0000 (02:01 -0700)]
speling.pez, an implementation of Norvig's spelling corrector.
Pete Elmore [Wed, 4 Aug 2010 08:19:50 +0000 (01:19 -0700)]
Very simple benchmarking lib.
Pete Elmore [Wed, 4 Aug 2010 08:18:15 +0000 (01:18 -0700)]
Fix a bug in 'execute', document exword() (so as to avoid this bug in the
future), and then a few other comment tweaks.
Pete Elmore [Wed, 4 Aug 2010 08:17:58 +0000 (01:17 -0700)]
Drop a bug from read-file in core.pez.
Pete Elmore [Sun, 1 Aug 2010 22:22:07 +0000 (15:22 -0700)]
I needed one of these.
Pete Elmore [Sat, 31 Jul 2010 11:05:50 +0000 (04:05 -0700)]
strform was lying!
Pete Elmore [Sat, 31 Jul 2010 10:49:08 +0000 (03:49 -0700)]
If you check the date I added that TODO, you'll see how long this has been
bothering me.
Pete Elmore [Sat, 31 Jul 2010 10:07:32 +0000 (03:07 -0700)]
Floats get their own stack.
Advantages:
* Faster
* Cleaner (much less alignment special-casing)
* Simpler (especially for the FFI)
Pete Elmore [Thu, 22 Jul 2010 07:41:10 +0000 (00:41 -0700)]
This left a pointer to the library name on the stack. This would actually be
and accidental feature, were it not for the fact that popping it off would
cause the else clause to do bad stuff to memory.
Pete Elmore [Thu, 22 Jul 2010 07:40:54 +0000 (00:40 -0700)]
Minor additions to the core library.
Pete Elmore [Sun, 11 Jul 2010 21:18:37 +0000 (14:18 -0700)]
New word: ht-values. Yes, I copypasta'd.
Pete Elmore [Sun, 11 Jul 2010 21:03:08 +0000 (14:03 -0700)]
Two new words: ht-size and ht-keys, to get the size and an array of the keys
out of a hash table, respectively.
Pete Elmore [Tue, 6 Jul 2010 06:16:45 +0000 (23:16 -0700)]
Unnecessary output.
(I was doing diffs against prime lists generated by another program
to verify; the "[pez]" was there to make them easier to read.)
Pete Elmore [Tue, 6 Jul 2010 06:15:26 +0000 (23:15 -0700)]
Dang but reverse Polish notation seems to have made me reason backwards.
Pete Elmore [Tue, 6 Jul 2010 05:55:55 +0000 (22:55 -0700)]
Why did I have the word "pile" in there?
Pete Elmore [Tue, 6 Jul 2010 05:51:55 +0000 (22:51 -0700)]
Adding a prime number sieve example.
Pete Elmore [Tue, 6 Jul 2010 02:11:10 +0000 (19:11 -0700)]
These are going away, actually, and moving elsewhere. Stay tuned.
Pete Elmore [Tue, 6 Jul 2010 02:10:34 +0000 (19:10 -0700)]
Whoa, that's a *bug*.
Pete Elmore [Tue, 6 Jul 2010 02:10:20 +0000 (19:10 -0700)]
atoi
Pete Elmore [Sun, 13 Jun 2010 21:55:23 +0000 (14:55 -0700)]
Left that off until now.
Pete Elmore [Sun, 13 Jun 2010 21:51:02 +0000 (14:51 -0700)]
New words: chomp and chomp!
Pete Elmore [Sun, 13 Jun 2010 20:31:22 +0000 (13:31 -0700)]
Keep out the generated file.
Pete Elmore [Sun, 13 Jun 2010 20:30:36 +0000 (13:30 -0700)]
Some FFI cleanup.
Pete Elmore [Sat, 12 Jun 2010 16:23:50 +0000 (09:23 -0700)]
De-dup that.
Pete Elmore [Sat, 12 Jun 2010 16:21:23 +0000 (09:21 -0700)]
New words: $, waitpid. "some command line" $ is similar to backticks in other
languages, waitpid is about what you expect.
Pete Elmore [Sat, 12 Jun 2010 07:13:48 +0000 (00:13 -0700)]
For FFI stuff to build with the same options as Pez, it needs config.h around.
Pete Elmore [Sat, 12 Jun 2010 06:48:22 +0000 (23:48 -0700)]
Whoops!
Pete Elmore [Sat, 12 Jun 2010 06:44:31 +0000 (23:44 -0700)]
New word: fsleep, which takes a float.
Pete Elmore [Sat, 12 Jun 2010 02:04:42 +0000 (19:04 -0700)]
Adding the beginnings of the SDL lib. Currently testing it out, should have
the rest up soon, as well as some helpers for compiling C-FFI stuff.
Pete Elmore [Sat, 12 Jun 2010 02:04:14 +0000 (19:04 -0700)]
Stuffing these into the API. Amazed they weren't there.
Pete Elmore [Fri, 11 Jun 2010 05:21:01 +0000 (22:21 -0700)]
New word: rand.
Pete Elmore [Wed, 9 Jun 2010 22:17:00 +0000 (15:17 -0700)]
Stuff all of that into core.pez.
Pete Elmore [Wed, 9 Jun 2010 22:06:29 +0000 (15:06 -0700)]
New word: realloc. Apparently, uh, reading a few megabytes of data is slow as
hell if you do it by reading 4k chunks and s+'ing them. Ahem.
Pete Elmore [Wed, 9 Jun 2010 22:05:44 +0000 (15:05 -0700)]
A light touch-up for the list concatenator. It's still O(n)!
Pete Elmore [Tue, 11 May 2010 04:19:13 +0000 (21:19 -0700)]
Poke at the linked list library, make it use the new struct stuff.
Pete Elmore [Tue, 11 May 2010 04:18:26 +0000 (21:18 -0700)]
A whitespace change to move a comment immediately above the function it
describes. Definitely my best commit ever.
Pete Elmore [Mon, 10 May 2010 00:53:38 +0000 (17:53 -0700)]
That was broken anyway. It will be back shortly, though.
Pete Elmore [Mon, 10 May 2010 00:39:50 +0000 (17:39 -0700)]
755
Pete Elmore [Sun, 9 May 2010 23:01:44 +0000 (16:01 -0700)]
Wow, it feels good to take that out of the TODO.
Pete Elmore [Sun, 9 May 2010 22:57:38 +0000 (15:57 -0700)]
Add support for structs, at long last!
Also fix sdup and gets, a warning in tuck and 2tuck, and document system.
Non-atomic, but not my only atrocity of the day.
Pete Elmore [Sun, 9 May 2010 22:54:35 +0000 (15:54 -0700)]
That example segfaulted if no arguments were passed.
Pete Elmore [Sun, 9 May 2010 22:54:18 +0000 (15:54 -0700)]
Include those files in the build.
Pete Elmore [Sun, 9 May 2010 22:52:08 +0000 (15:52 -0700)]
This was the stuff I was putting off because it was tedious. Even generating
it was tedious. Anyway, this should be all we need to make structs worse.
Pete Elmore [Sun, 9 May 2010 22:51:08 +0000 (15:51 -0700)]
I had some fun printing prime factors of things.
Pete Elmore [Sun, 18 Apr 2010 23:08:58 +0000 (16:08 -0700)]
TODO update.
Pete Elmore [Sun, 18 Apr 2010 23:01:03 +0000 (16:01 -0700)]
New words: tuck, 2tuck, and some tests.
Pete Elmore [Sun, 11 Apr 2010 05:57:38 +0000 (22:57 -0700)]
Clean that horror up a little.
Pete Elmore [Sun, 11 Apr 2010 05:24:52 +0000 (22:24 -0700)]
Add a thousand annoying size words and accessors for various types, for talking
to C libraries. Some use standard C types with platform-dependent sizes, some
use types that explicitly mention sizes, and it's just a mess. No two ways
about it. (But, thankfully, autotools can shield us from parts of it.)
Pete Elmore [Sat, 10 Apr 2010 21:34:26 +0000 (14:34 -0700)]
Three new words: sdup, ht-dup, format. Will eventually do fformat.
Pete Elmore [Sat, 10 Apr 2010 21:33:27 +0000 (14:33 -0700)]
Update an example.
Pete Elmore [Sat, 10 Apr 2010 21:33:08 +0000 (14:33 -0700)]
Laying it out a little more plainly.
Pete Elmore [Sat, 10 Apr 2010 21:32:58 +0000 (14:32 -0700)]
AUTOMATIC
Pete Elmore [Fri, 2 Apr 2010 07:24:00 +0000 (00:24 -0700)]
Yeah, the flags are a little obscure, still.
Pete Elmore [Fri, 2 Apr 2010 07:20:07 +0000 (00:20 -0700)]
TODOne!
Pete Elmore [Fri, 2 Apr 2010 07:12:13 +0000 (00:12 -0700)]
Move the zero-branch checking into ; (i.e., at compilation finish) so that
we can avoid the cost of doing it at runtime. The one caveat is that ; doesn't
always get called (!!) and I don't have a good solution yet, but presumably
you know the risks if you're assembling words yourself or using does>.
Pete Elmore [Fri, 2 Apr 2010 06:48:44 +0000 (23:48 -0700)]
Gots to do something about that problem.
Pete Elmore [Thu, 1 Apr 2010 07:17:40 +0000 (00:17 -0700)]
Checking for bad branches.
Pete Elmore [Thu, 1 Apr 2010 07:04:30 +0000 (00:04 -0700)]
Well, that solves the mystery of the angry floats.
Pete Elmore [Thu, 1 Apr 2010 06:37:32 +0000 (23:37 -0700)]
And another.