JeffBezanson
9ed9a51786
adding *print-level* and *print-length*
...
fixing open-string-output-port (R6RS)
making io.tostring! more consistent
adding newlines to boot file; wastes space but will allow more
efficient diffing
2009-08-13 04:09:35 +00:00
JeffBezanson
97c05e8eb4
a couple bug fixes
...
some small performance tweaks
moving some test files around
2009-08-09 20:34:07 +00:00
JeffBezanson
929ec92a65
adding support for eof-object
...
renaming exported symbol NIL to FL_NIL
making default vector fill #f
some misc. cleanup
2009-08-09 18:04:03 +00:00
JeffBezanson
51f645a916
adding gensym?, fixing keyword?
...
checking in psyntax library, and more scheme aliases to make it work
2009-08-09 17:05:40 +00:00
JeffBezanson
302ddec770
adding read and print support for named characters, e.g. #\space
...
printing infs and nans in R6RS format
making closure print syntax more compact; fn instead of function
adding more c[ad]+r functions
2009-08-08 21:44:14 +00:00
JeffBezanson
1a6d9d391f
adding with-bindings, with-output-to-file, with-output-to
...
simplifying printing. now based on standard function write,
removing io.print and io.princ
using same top level exception handler for scripts as repl
2009-08-08 00:29:55 +00:00
JeffBezanson
c6a977063e
better error checking for formal argument lists
...
some cosmetic error improvements
adding more tests
2009-08-03 05:00:44 +00:00
JeffBezanson
15c8cb327d
finishing initial implementation of keyword arguments
...
fixing up interpreter so it can be used for bootstrapping again
removing let/copyenv optimization because it really didn't seem to help much
2009-08-02 04:06:07 +00:00
JeffBezanson
adb702cdf8
fixing a bug in optional args + rest args with no required arguments
...
adding some code for keyword argument processing
2009-07-29 04:20:28 +00:00
JeffBezanson
ecfd81148f
changing optional args to allow default values to be computed from
...
preceding arguments
tidying some stuff with keywords
2009-07-28 04:16:20 +00:00
JeffBezanson
eceeddf6d2
adding support for optional arguments
...
error checking formal argument lists
making filter preserve the order of elements in the input list
2009-07-27 03:34:33 +00:00
JeffBezanson
c61dc10002
adding some combined instructions and teaching the compiler to emit them:
...
brn, brnn, brne, cadr
2009-07-24 04:20:09 +00:00
JeffBezanson
66c671bfee
making long argument lists more efficient
2009-07-22 02:10:20 +00:00
JeffBezanson
0278b152b8
fixing a case where tail position was not properly observed
2009-07-21 03:42:15 +00:00
JeffBezanson
57c066fcdf
simplifying code by eliminating the hybrid stack/heap calling convention
...
other misc. cleanup
2009-07-20 04:57:17 +00:00
JeffBezanson
2c304edf42
changing boot file format; the old one did not preserve sharing
...
between top-level functions
making colon at the end also valid for keywords
adding keyword? predicate
fixing bug in map
adding functions to emulate values and call-with-values
adding receive macro
improving equal? on closures
adding lambda-lifting optimization to the compiler
2009-07-17 01:30:26 +00:00
JeffBezanson
c19aaeabd6
keeping track of function names, printing nice stack traces
...
changing default bootstrap process to use VM instead of interpreter
fixing bug where only a fixnum could index a vector
merging equal.c into the main compilation unit
2009-07-10 04:17:39 +00:00
JeffBezanson
3793cf676c
implementing stack traces
...
some cleanup
2009-07-06 03:56:48 +00:00
JeffBezanson
494e439510
using lisp value stack for call frames instead of the C stack
...
adding the ability to grow the value stack as needed
the net effect is that calls use much less space, and stack frames
can use all available heap space. the only downside is that C builtins
must be aware that the stack can change out from under them if they call
lisp code. currently the only example of this is table.foldl.
also fixing bug where exceptions failed to unwind the gc handle stack.
2009-07-03 18:43:15 +00:00
JeffBezanson
2f78b407ea
some renaming (intern is now symbol) and moving stuff around
...
adding scheme aliases
2009-06-30 03:21:41 +00:00
JeffBezanson
3844191d70
adding the ability for the VM to use computed goto where available
...
with gcc v4.3.2 I found the combination of -O2 and computed goto to give the
best performance; with -O3 performance was a little worse and computed goto
was a wash.
2009-06-28 19:47:11 +00:00
JeffBezanson
b5897e0ad1
adding maxstack calculation and stack overflow protection
...
making append benchmark more useful by measuring interpreter
speed instead of the builtin
2009-06-27 23:07:22 +00:00
JeffBezanson
8decdc4ae4
making append a builtin
...
making branch destinations relative so we can access the code
using *ip instead of code[ip]
doing the same to bp (argument access)
small improvement to map, builtin->instruction
better profiling
2009-06-15 02:25:21 +00:00
JeffBezanson
6ec69f5375
optimizations to map and case
...
several optimizations to the compiler itself, mostly involving
emit and encode-byte-code
experimental, very basic profiling utility
2009-06-11 00:34:50 +00:00
JeffBezanson
943c0d71d1
tiny performance tweaks: removing some variables, making some static
2009-06-09 18:46:02 +00:00
JeffBezanson
27a3e413d3
adding opcodes loada0, loada1, loadc00, loadc01
...
adding offset and count arguments to dump
2009-06-08 03:22:32 +00:00
JeffBezanson
17752decf4
implementing support for lambdas with up to 2^32-1 required arguments
...
using copy-list to implement append2
fixing bug in op_vargc when nrequired==MAX_ARGS
making fetching of multibyte numbers from bytecode portable
some cleanup in compiler
2009-06-06 21:15:54 +00:00
JeffBezanson
7e59898778
updating doc
2009-05-31 22:27:37 +00:00
JeffBezanson
ba32e4b0e9
simplifying the whole list* situation, taking better advantage of
...
existing builtin functionality
2009-05-31 18:58:09 +00:00
JeffBezanson
7e65db3e74
faster append
...
removing 'equal' alias
removing some top level bindings
2009-05-30 21:13:13 +00:00
JeffBezanson
bbcc68cfdf
making copy-list a builtin, since the functionality was there anyway.
...
adding builtin primitive apply-nlist*, to speed up list* and nlist*
2009-05-30 17:54:27 +00:00
JeffBezanson
bfbbf051c9
doing a better job hashing circular structure. the hash function is now
...
always fast and gives conservative correct answers, at the expense of
fidelity on medium and large size structures. for example (hash (iota 15))
gives the same result as (hash (iota 14)).
2009-05-20 03:39:20 +00:00
JeffBezanson
c2026ba77c
adding gc handles, making evaluator stack static
...
this provides a better interface and could only help performance
starting to add some useful library code
2009-05-19 02:54:56 +00:00
JeffBezanson
c38c47d264
adding R6RS div, mod, div0, mod0
...
small improvement to cmp_eq
explicit -fomit-frame-pointer was causing test failures with gcc4.3.2
2009-05-14 17:54:59 +00:00
JeffBezanson
e365cb1d33
adding divide by 0 check in div
2009-05-14 02:53:04 +00:00
JeffBezanson
ae2a4dd156
adding integer division function div
...
changing / to do real division always
fixing equal? to distinguish -0.0 and 0.0
making equal? and eqv? false on numbers of different exactness
2009-05-14 01:30:25 +00:00
JeffBezanson
6c549f0399
fixing hash of circular structure to avoid tree recursion (very important!!)
...
simplifying vector_grow
2009-05-13 04:03:13 +00:00
JeffBezanson
77e37368c9
fixing trace and untrace
...
replacing function->vector with function:code, function:vals, and
function:env
2009-05-13 01:13:40 +00:00
JeffBezanson
a7a31cf53a
fixing vararg apply to work properly
2009-05-11 23:55:40 +00:00
JeffBezanson
c94774a5df
adding *error-stream* variable
...
removing unnecessary byte after :let in bytecode encoding
adding script for easy bootstrapping
2009-05-05 23:51:13 +00:00
JeffBezanson
63edc82ba4
using global variables uniformly for print settings instead of passing
...
around one of them
fixing unwind-protect not to duplicate code
2009-05-05 04:01:06 +00:00
JeffBezanson
264df1f90b
improving closure representation
...
some performance tweaks
2009-04-28 04:10:18 +00:00
JeffBezanson
14d625bd83
some performance tweaks
2009-04-27 03:21:53 +00:00
JeffBezanson
de19e4f401
adding return special form
...
eliminating some unnecessary top-level bindings
adding opcodes add2, sub2, neg
2009-04-26 22:19:32 +00:00
JeffBezanson
0dc4c16276
making procedure? a builtin
...
fixing type error trying to apply #t, #f, nil
2009-04-24 20:43:56 +00:00
JeffBezanson
909b91ffcc
fixing printing of invalid UTF-8
2009-04-23 00:22:03 +00:00
JeffBezanson
e4488bb065
some tweaks to the vm
2009-04-22 23:00:13 +00:00
JeffBezanson
27120b0ce4
fixing bug in truncate
...
simplifying nconc loop
2009-04-22 15:02:49 +00:00
JeffBezanson
d6f73d0bf0
implementing #vu8 read and print syntax for uint8 vectors
...
much more compact string representation of bytecode
2009-04-21 15:35:46 +00:00
JeffBezanson
305c350c56
a couple small fixes
...
making bytecode representation more space-efficient
2009-04-21 14:53:18 +00:00