*** empty log message ***
[bpt/guile.git] / libguile / ChangeLog
index dae4f34..24662c6 100644 (file)
@@ -1,3 +1,778 @@
+2000-03-22  Mikael Djurfeldt  <mdj@mdj.nada.kth.se>
+
+       * tags.h (SCM_ECONSP, SCM_NECONSP): More corrections of
+       pointer-arithmetic induced by the SCM_PACK/UNPACK change.
+
+       * print.c (scm_iprin1): SCM_PACK/UNPACK corrections.
+
+       * gc.c (scm_gc_sweep): SCM_PACK/UNPACK corrections.
+
+       * eval.c (SCM_CEVAL, scm_unmemocar): SCM_PACK/UNPACK corrections.
+
+       * dynwind.c (scm_swap_bindings): SCM_PACK/UNPACK corrections.
+
+       * async.c, __scm.h: Removed lots of the old async click logic.  It
+       is possible to reinsert it by defining GUILE_OLD_ASYNC_CLICK in
+       __scm.h.  Let's try this out and dump the old code after the
+       threads reorganization.
+       (set-tick-rate, set-switch-rate): Conditionally removed.
+
+2000-03-21  Mikael Djurfeldt  <mdj@mdj.nada.kth.se>
+
+       * gc.c (scm_gc_mark): Bugfix 1: The recent SCM_PACK/UNPACK change
+       made SCM values into pointers.  This turned an arithmetic
+       computation of the address of the vcell into a pointer-arithmetic
+       one, thereby screwing up marking of structs.
+       Bugfix 2: Removed incompletely introduced loop variable `j' used
+       when protecting the tail array of a struct.
+
+2000-03-21  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * struct.h (SCM_STRUCT_DATA):  Don't cast SCM values to pointers.
+
+2000-03-21  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * symbols.h, symbols.c (scm_strhash):  Declare the string
+       parameter as constant, since it is not modified.
+
+       * symbols.c (scm_intern_obarray_soft,
+       scm_sysintern0_no_module_lookup):  Can now pass constant strings
+       to scm_strhash without need for casting.
+
+2000-03-21  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * vectors.h (SCM_VELTS, SCM_VELTS_AS_STACKITEMS):  Don't cast SCM
+       values to pointers.  Use SCM2PTR instead.
+
+2000-03-21  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * async.c (scm_set_tick_rate, scm_set_switch_rate):  Don't unpack
+       results of SCM_INUM.
+
+2000-03-21  Mikael Djurfeldt  <mdj@thalamus.nada.kth.se>
+
+       * init.c (scm_boot_guile_1): Renamed GUILE_GC_TRIGGER_1 -->
+       GUILE_MIN_YIELD_1, GUILE_GC_TRIGGER_2 --> GUILE_MIN_YIELD_2.
+       GUILE_MIN_YIELD_X now take *positive* fractions of heap size.
+
+       * gc.c, gc.h (SCM_MIN_YIELD_1, SCM_MIN_YIELD_2,
+       min_yield_fraction, min_yield, adjust_min_yield): Renamed from
+       SCM_GC_TRIGGER_1, SCM_GC_TRIGGER_2, gc_trigger_fraction,
+       gc_trigger, adjust_gc_trigger.
+
+       * gc.c (alloc_some_heap): Further improvement of minimal heap size
+       prediction.
+       (SCM_MAX): New macro.
+       (scm_freelist_t): New field: collected_1. Previous amount of
+       collected cells.
+       (gc_sweep_freelist_finish): Trigger based on two last values of
+       freelist->collected to avoid unnecessary allocation due to
+       temporary peaks.
+       (SCM_INIT_HEAP_SIZE_1, SCM_GC_TRIGGER_1, SCM_GC_TRIGGER_2):
+       Adjusted to 45000 cells, 40% and 40%.  Gives quick startup
+       without extra heap allocation.
+
+2000-03-20  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * numbers.h (SCM_MAKINUM):  The parameter to SCM_MAKINUM should
+       already be a C value.  No need to unpack it.
+
+       * numbers.h (scm_long_long2num):  Cast the parameter to scm_bits_t
+       if we know it fits into an inum.
+
+       * ramap.c (ramap_rp):  An scm_tc7_[ui]vect object does point to a
+       field of long values.  In contrast, SCM_VELTS accesses a field of
+       SCM values.
+
+2000-03-20  Mikael Djurfeldt  <mdj@mdj.nada.kth.se>
+
+       * gc.c (scm_gc_stats): Inserted explanation of local_scm_mtrigger
+       etc.
+       (scm_gc_yield_1): New variable: Holds previous yield.  Used to
+       make better judgements.
+       (gc_sweep_freelist_finish): Inserted explanation of use of
+       gc_trigger.
+
+       * print.h, stacks.h, options.c, options.h: Changed C++
+       commentaries to C.
+
+2000-03-20  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * tags.h (SCM2PTR, PTR2SCM):  Use SCM_PACK / SCM_UNPACK correctly.
+
+       * numbers.h (SCM_INUMP, SCM_MAKINUM, SCM_INUM0, SCM_COMPLEX_REAL,
+       SCM_COMPLEX_IMAG, SCM_NUMP, SCM_BDIGITS):  Use SCM_PACK /
+       SCM_UNPACK / SCM2PTR correctly.
+
+2000-03-20  Mikael Djurfeldt  <mdj@mdj.nada.kth.se>
+
+       * gc.c (adjust_gc_trigger): Improved documentation.
+       (alloc_some_heap): Since gc_trigger is used against
+       freelist->collected, this is the value which should be used to
+       predict minimum growth.
+
+2000-03-20  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * eval.h:  Fix mixup of packed/unpacked SCM values.  (Thanks
+       Thien-Thi Nguyen for the patch.)
+
+2000-03-20  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * numbers.c (scm_ash):  Fixed typing problems with the second
+       parameter and added some documentation.  (Thanks Thien-Thi Nguyen
+       for indicating the problem.)
+
+2000-03-19  Mikael Djurfeldt  <mdj@mdj.nada.kth.se>
+
+       * gc.c, gc.h (scm_gc_yield): New variable.
+       (adjust_gc_trigger): Use scm_gc_yield.
+       (alloc_some_heap): Use scm_gc_yield instead of
+       scm_gc_cells_collected.
+
+       * coop-threads.c: Addd #include "root.h", #include "strings.h".
+
+       * debug.c: Added #include "root.h".  (Thanks to Thien-Thi Nguyen.)
+
+       * gc.c (scm_gc_for_newcell, adjust_gc_trigger): Improved GC
+       trigger adjustmeant: Take yield (freed cells) for all freelists
+       into account.
+       (SCM_INIT_HEAP_SIZE_1, SCM_GC_TRIGGER_1, SCM_GC_TRIGGER_2): Tuned
+       to 50000 cell heap with 45% trigger.
+       (scm_gc_cells_collected): Reintroduced.
+       (SCM_HEAP_SIZE): New macro.
+       (scm_gc_sweep): Reintroduced correct computation of
+       scm_cells_allocated.
+       (scm_freelist_t): Corrected commentary for field `cluster_size':
+       Clustersize counts objects, not cells;  New member
+       `clusters_allocated'.
+
+2000-03-19  Michael Livshin  <mlivshin@bigfoot.com>
+
+       * *.[hc]: add Emacs magic at the end of file, to ensure GNU
+       indentation style.
+
+2000-03-19  Mikael Djurfeldt  <mdj@thalamus.nada.kth.se>
+
+       * threads.h: Added #include "libguile/throw.h".  (Thanks to
+       Thien-Thi Nguyen.)
+
+2000-03-18  Michael Livshin  <mlivshin@bigfoot.com>
+
+       * tags.h: (SCM_DOUBLE_CELLP, SCM_NDOUBLE_CELLP): new macros.
+
+       * gc.h: (typedef struct scm_freelist_t) remove from here.
+
+       * gc.c: (CELL_UP, CELL_DN) make these macros take additional
+       parameter (the span).
+       (CLUSTER_SIZE_IN_BYTES, ALIGNMENT_SLACK) new macros.
+       (typedef struct scm_freelist_t) move here from gc.h, it had no
+       business being externally visible.
+       (typedef struct scm_heap_seg_data_t) renamed from
+       scm_heap_seg_data, to be style-compliant.
+       (scm_mark_locations) if the possible pointer points to a
+       multy-cell, check that it's properly aligned.
+       (init_heap_seg) alighn multy-cells properly, work with the
+       assumption that the segment size divides cleanly by cluster size
+       (so that there's no spill).
+       (round_to_cluster_size) new function.
+       (alloc_some_heap, make_initial_segment) use round_to_cluster_size
+       to satisfy the new init_heap_seg invariant.
+
+2000-03-18  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * _scm.h:  Don't include async.h everywhere...
+
+       * eq.c eval.c iselect.c: ... only include it here.
+
+2000-03-18  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * _scm.h:  Don't include root.h everywhere...
+
+       * async.c continuations.c eq.c eval.c evalext.c feature.c gc.c
+       gdbint.c gsubr.c ioext.c keywords.c lang.c load.c macros.c
+       numbers.c objprop.c ports.c print.c procprop.c ramap.c read.c
+       srcprop.c stackchk.c stacks.c strports.c symbols.c unif.c
+       variable.c vectors.c vports.c: ... only include it here.
+
+2000-03-17  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * _scm.h:  Don't include strings.h everywhere...
+
+       * backtrace.c dynl.c error.c feature.c filesys.c fports.c gc.c
+       gdbint.c ioext.c load.c net_db.c numbers.c objects.c options.c
+       ports.c posix.c print.c procs.c random.c read.c regex-posix.c
+       simpos.c socket.c stacks.c stime.c strop.c strports.c struct.c
+       symbols.c unif.c vectors.c version.c vports.c: ... only include it
+       here.
+
+2000-03-17  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * _scm.h:  Don't include ports.h everywhere...
+
+       * arbiters.c backtrace.c debug.c dynl.c dynwind.c eval.c feature.c
+       fluids.c gc.c gdbint.c guardians.c hash.c keywords.c mallocs.c
+       numbers.c objects.c print.c read.c root.c smob.c srcprop.c
+       stackchk.c strports.c struct.c throw.c variable.c:  ... only
+       include it here.
+
+2000-03-17  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * _scm.h:  Don't include vectors.h everywhere...
+
+       * eq.c eval.c filesys.c gc.c gsubr.c guardians.c hash.c hashtab.c
+       keywords.c net_db.c numbers.c objects.c posix.c print.c procprop.c
+       procs.c ramap.c random.c read.c scmsigs.c socket.c sort.c stime.c
+       strports.c symbols.c unif.c vports.c weaks.c:  ... only include it
+       here.
+
+2000-03-17  Dirk Herrmann  <D.Herrmann@tu-bs.de>
+
+       * genio.h:  removed.  (Only content was '/* delete me */'.)
+
+       * Makefile.am arbiters.c backtrace.c debug.c dynl.c dynwind.c
+       error.c filesys.c fluids.c gc.c gsubr.c guardians.c keywords.c
+       libguile.h mallocs.c numbers.c print.c random.c read.c root.c
+       srcprop.c stackchk.c struct.c threads.c throw.c variable.c:
+       Removed reference to genio.h
+
+2000-03-17  Mikael Djurfeldt  <mdj@thalamus.nada.kth.se>
+
+       * gc.c, gc.h: Cleanup of the change of 2000-03-15.
+       Cluster sizes are now independent of GC trigger values.
+       GUILE_GC_TRIGGER_n can now specify a relative trigger value:
+       A negative integer gives fraction of total heap size in percent.
+       (SCM_GC_TRIGGER_1, SCM_GC_TRIGGER_2): Default values set to -40.
+
+       * init.c (scm_boot_guile_1): Introduced new variable
+       GUILE_MAX_SEGMENT_SIZE; New environment variable names:
+       GUILE_INIT_SEGMENT_SIZE_1, GUILE_GC_TRIGGER_1,
+       GUILE_INIT_SEGMENT_SIZE_2, GUILE_GC_TRIGGER_2
+
+2000-03-16  Mikael Djurfeldt  <mdj@mdj.nada.kth.se>
+
+       * __scm.h (GC_FREE_SEGMENTS): Disable this until we have made
+       freeing of segment work with the new GC scheme.  (Thanks to
+       Michael Livshin.)  Oops, also happened to make GUILE_NEW_GC_SCHEME
+       the default, but I'll let this change stay in CVS Guile since this
+       code is not expected to contain serious bugs.
+
+2000-03-16  Mikael Djurfeldt  <mdj@thalamus.nada.kth.se>
+
+       * gc.c, gc.h (scm_map_free_list): Define also if GUILE_DEBUG is
+       defined.
+       (scm_free_list_length): New procedure (GUILE_DEBUG).
+       Fixed a small but serious bug introduced by the previous change.
+
+       * gc.c (scm_gc_sweep): Moved variable n_objects to inner sweep
+       loop and declare as register.
+
+       * gc.c (scm_gc_sweep): Sigh... forgot to clear private freelists
+       after GC.
+
+Wed Mar 15 08:27:04 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * fluids.c: Docstring patch from Keisuke Nishida.  Some
+       reindentation, too, and a couple formals renamed.  Should
+       fluid-set! return UNSPECIFIED instead of a value?
+
+Wed Mar 15 08:24:58 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * Makefile.am: Separate out DOT_X_FILES and DOT_DOC_FILES, and
+       generate the latter from the concrete listing of the former.  Then
+       make guile-procedures.txt depend on DOT_DOC_FILES instead of
+       *.doc, so that rebuilding it works.
+
+Wed Mar 15 08:12:14 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * libguile.h: Include libguile/validate.h.  Thanks Keisuke Nishida!
+
+       * guile-snarf.awk.in: Replace docstring line-ending \n" and \n\n"
+       with nothing and \n, respectively. Thanks Keisuke Nishida for
+       noticing this problem.
+
+2000-03-15  Mikael Djurfeldt  <mdj@mdj.nada.kth.se>
+
+       * __scm.h (GUILE_NEW_GC_SCHEME): Define this if you want to test a
+       new way of allocating heap.  It makes Guile fast, but still
+       contains bugs.
+
+       * gc.c, gc.h, pairs.h, init.c: Implementation of a new way of
+       allocating heap.  The basic idea is to trigger GC every Nth
+       allocated cell and grow heap when free list runs out.  The scheme
+       has been extended so that GC isn't triggered until all remaining
+       cells are used.  The implementation is also prepared for
+       development in the direction of POSIX threads.
+
+       * gc.c (SCM_EXPHEAP): In order to grow by a factor of 1.5,
+       SCM_EXPHEAP should return half of the heap size.
+
+2000-03-14  Mikael Djurfeldt  <mdj@thalamus.nada.kth.se>
+
+       The following change to init.c is only enabled if Guile was
+       configured with --enable-guile-debug.
+
+       * init.c (scm_i_getenv_int): New function.
+       (scm_boot_guile_1): Use the environment variables
+       GUILE_INIT_HEAP_SIZE, GUILE_INIT_HEAP_SIZE2 to select heap size if
+       they exist.  (This may be replaced by a Scheme level mechanism in
+       the future.)
+
+       * objprop.c (s_scm_set_object_property_x): Use scm_assq instead of
+       scm_assoc.  (Thanks to Keisuke Nishida.)
+
+2000-03-14  Mikael Djurfeldt  <mdj@mdj.nada.kth.se>
+
+       * eval.c, lang.c, lang.h (scm_lisp_nil, scm_lisp_t): Renamed from
+       scm_nil, scm_t.  (Thanks to Keisuke Nishida.)
+
+2000-03-14  Mikael Djurfeldt  <mdj@thalamus.nada.kth.se>
+
+       * init.c (scm_boot_guile_1): Use same initial segment size for
+       1-word and 2-word segments.  Having the smaller size causes Guile
+       to GC too often.  Obviously something needs to be done to allow
+       for a smaller 2-word segment without this to happen.  (The amount
+       of heap for each type should be automatically adapted to the
+       application somehow.)
+
+       [Almost all of these changes should be documented in the NEWS
+       file.]
+
+       * gc.h (scm_freelist_t): New type.
+
+       * pairs.h (SCM_NEWCELL, SCM_NEWCELL2): Use new style freelists.
+
+       * gc.c (SCM_INIT_HEAP_SIZE): Changed from 32768 --> 40000 so that
+       all of Guile basics fits into one segment and there suitable room
+       for work.
+       (SCM_EXPHEAP): Now takes an argument.  Grow by a factor of 1.5
+       instead of 2.
+       (scm_freelist, scm_freelist2): Now of type scm_freelist_t.
+       Freelists now contains information about object span, cells
+       collected and amount of cells in heap segments belonging to the
+       list.
+       (scm_heap_size, scm_gc_cells_collected): Removed.
+
+       * init.c (scm_boot_guile_1): Make 2-word segment 8K (512 cells).
+
+       * Makefile.am (libguile_la_LDFLAGS): Bumped library version
+       number.
+
+       * __scm.h eq.c, eval.c, gc.c, gc.h, gh_data, hash.c, numbers.c,
+       numbers.h, objects.c, ramap.c, random.c, unif.c, unif.h: Extensive
+       rewrite of handling of real and complex numbers.
+       (SCM_FLOATS, SCM_SINGLES): These #ifdef conditionals have been
+       removed along with the support for floats.  (Float vectors are
+       still supported.)
+
+       * tags.h (scm_tcs_bignums): Removed.
+       (scm_tc16_bigpos, scm_tc16_bigneg): Replaced by scm_tc16_big.
+       Use SCM_BIGSIGN(x) to test for sign!
+       (scm_tc16_big): The new bignum type.
+       (SCM_REAL_PART, SCM_IMAG_PART): Removed.
+
+       * numbers.h (SCM_BIGSIGN): Sign moved to bit 16.
+       (scm_makdbl): Deprecated.
+       (SCM_NEWREAL, SCM_NEWCOMPLEX): New macros.
+       (SCM_SINGP): Deprecated.
+       (SCM_FLO): Removed.
+       (SCM_INEXP, SCM_CPLXP): Deprecated.
+       (SCM_INEXACTP, SCM_COMPLEXP): New macros.
+       (SCM_COMPLEX_REAL, SCM_COMPLEX_IMAG): Renamed from
+       SCM_REAL, SCM_IMAG (and now only valid for complex numbers).
+       (SCM_REAL, SCM_IMAG): New, *deprecated*, selectors which work both
+       for doubles and complex numbers.
+       (SCM_REAL_VALUE): New selector for doubles.
+       (scm_double_t, scm_complex_t): New types.
+       (scm_dbl): Removed.
+
+       * numbers.c (scm_floprint, scm_floequal): Removed.
+       (scm_print_real, scm_print_complex, scm_real_equalp,
+       scm_complex_equalp): New functions.
+
+       * unif.c (scm_makflo): Removed.
+
+       * smob.h (SCM_SMOB_PREDICATE): New macro.
+       (SCM_NEWSMOB2, SCM_RETURN_NEWSMOB2, SCM_NEWSMOB3,
+       SCM_RETURN_NEWSMOB3): New macros.
+
+1999-11-21  Michael Livshin  <mlivshin@bigfoot.com>
+
+       The following changes implement primitive support for double cells
+       (i.e. four-word cells) and change the representation of some
+       things to multi-cells instead of cons+malloc.  (Applied and
+       modified by mdj.)
+
+       * pairs.h (SCM_NEWCELL2): double-cell variants of SCM_NEWCELL.
+       (SCM_CELL_WORD, SCM_CELL_WORDLOC, SCM_SET_CELL_WORD): primitive
+       multi-cell access macros (used by the ones below).
+       (SCM_CELL_WORD[0-3], SCM_SET_CELL_WORD[0-3]): multi-cell access
+       macros.
+
+       * gc.c (scm_freelist2): multi-cell freelists.
+       (inner_map_free_list): map_free_list, parameterized on ncells.
+       "nn cells in segment mm" was misleading for ncells > 1; changed to
+       "objects".  still print cells too, though.
+       (scm_map_free_list): rewritten using inner_map_free_list.
+       (scm_check_freelist): get freelist as parameter, since now we have
+       more than one.
+       (scm_debug_newcell2): multi-cell variants of
+       scm_debug_newcell.
+       (scm_gc_for_newcell): take ncells and freelist pointer as
+       parameters.
+       (scm_gc_mark): add case for tc7_pws (procedures with setters are
+       now double cells).
+       (scm_gc_sweep): don't free the float data, since it's not malloced
+       anymore.
+       (init_heap_seg): didn't understand what n_new_objects stood for,
+       so changed to n_new_cells.
+       (make_initial_segment): new function, makes an initial segment
+       according to given ncells.
+       (scm_init_storage): call make_initial_segment, for ncells={1,2,3}.
+
+       * numbers.c (scm_makdbl): no malloc'ing needed, so the
+       {DEFER,ALLOW}_INTS thing removed.
+
+       * numbers.h (struct scm_dbl): changed to represent a double cell,
+       with the number in the second half.
+
+       * dynwind.c: changed the wind-guards representation to double
+       cell.
+
+       * procs.c, procs.h: changed the procedure-with-setter representation
+       to double cell.
+
+       * async.c, async.h: made async representation a double cell.
+
+       * dynl.c: made dynamic_obj representation a double cell.
+
+2000-03-13  Gary Houston  <ghouston@arglist.com>
+
+       * ports.c (flush_void_port): renamed to flush_port_default.
+       (end_input_void_port): renamed to end_input_default.
+
+       * init.c (scm_standard_stream_to_port): create a void port instead
+       of opening /dev/null if the standard file descriptors are bad.
+       advantages: no portability problems, doesn't waste a file descriptor,
+       simplifies the code (thanks to Marius for the idea).
+
+       * vports.c (s_scm_make_soft_port): call scm_port_non_buffer.
+
+       * void ports: make reading from a void port give EOF instead of
+       segv:
+       * ports.c (s_scm_sys_make_void_port): modified docstring.
+       (fill_input_void_port): new proc.
+       (scm_init_ports): set up fill_input_void_port.
+       * ports.c (scm_port_non_buffer): new proc.
+       (scm_void_port): call scm_port_non_buffer.
+
+       * fports.c (scm_setvbuf): docstring: remove the fcntl documentation
+       which was incorrectly appended.
+
+2000-03-13  Mikael Djurfeldt  <mdj@mdj.nada.kth.se>
+
+       * guile-doc-snarf.in: Don't use absolute path for `sed'.  (Note
+       that we can't use autoconf for this.  Autoconf itself relies on
+       the existence of `sed' somewhere on your path.)  (Thanks to Dirk
+       Herrman.)
+
+2000-03-13  Mikael Djurfeldt  <mdj@thalamus.nada.kth.se>
+
+       * Makefile.am (libguile_la_SOURCES): Moved iselect.c here from
+       EXTRA_libguile_la_SOURCES.
+
+       * iselect.h: Always declare scm_internal_select.
+
+       * iselect.c (scm_internal_select): Added SCM_ASYNC_TICK at the
+       end.  Also let scm_internal_select be a real function also when
+       not using threads.
+
+       * __scm.h (SCM_TICK): Oops! Forgot to put SCM_ASYNC_TICK here...
+
+2000-03-13  Mikael Djurfeldt  <mdj@mdj.nada.kth.se>
+
+       * __scm.h (SCM_ALLOW_INTS, SCM_REALLOW_INTS): Removed call to
+       SCM_ASYNC_TICK.  (This is a preparation for POSIX threads support,
+       and kind of an experiment: Will this cause problems?)
+
+Sun Mar 12 13:26:30 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * Makefile.am: Added *.doc to DISTCLEANFILES.
+
+2000-03-12  Gary Houston  <ghouston@arglist.com>
+
+       * fports.c (scm_fdes_to_port): call fcntl F_GETFL to test that
+       the fdes is valid before doing anything else.  check that
+       the file descriptor supports the modes required.
+       (scm_fport_buffer_add): don't throw an error if fstat doesn't
+       work: just use the default buffer size.
+
+       * throw.c: change an outdated comment about scm_internal_catch
+       BODY: it doesn't take a jumpbuf arg.
+
+       * init.c (scm_standard_stream_to_port): install a handler in case
+       scm_fdes_to_port throws an error.  don't check here whether the
+       file descriptor is valid, since scm_fdes_to_port will do that.
+       set the revealed count depending on whether the port got the
+       standard file descriptor.
+       (stream_body_data): new type.
+       (stream_body, stream_handler): new procs.
+
+2000-03-12  Mikael Djurfeldt  <mdj@thalamus.nada.kth.se>
+
+       * stacks.c, stacks.h, struct.c, tags.h, unif.c (scm_bits_t):
+       Renamed from SCMWORD.
+
+       * tags.h (SCM_NCELLP): Removed (SCMWORD).
+
+       * arbiters.c (SCM_ARB_LOCKED): Use SCM_UNPACK_CAR.
+
+       * async.c, boolean.h, debug.c, dynl.c, dynwind.c, eval.c, eval.h,
+         feature.h, filesys.h, fluids.h, fports.c, fports.h, gc.c, gc.h,
+         hash.c, keywords.h, macros.c, numbers.c, numbers.h, objects.c,
+         objects.h, options.c, pairs.h, ports.c, ports.h, print.c,
+         procs.h, ramap.c, read.c, smob.c, smob.h, srcprop.h, stacks.c,
+         stacks.h, strports.c, struct.c, struct.h, tag.c, tags.h,
+         throw.c, unif.c, unif.h, variable.h, vectors.h, weaks.c,
+         weaks.h (SCM_PACK, SCM_UNPACK, SCM_UNPACK_CAR): Renamed from
+         SCM_ASSCM, SCM_ASWORD, SCM_CARW).
+
+       * numbers.h (SCM_SRS, SCM_INUM): Corrected SCM_ASSCM/ASWORD fixes.
+
+       * alist.c, eval.c, net_db.c, posix.c, print.c, snarf.h, struct.c,
+       tags.h: Fixed copyright notices.
+
+       * struct.c, coop-threads.c: SCM_ASSCM/ASWORD fixes.
+
+2000-03-12  Marius Vollmer  <mvo@zagadka.ping.de>
+
+       * init.c (scm_standard_stream_to_port): Check whether the file
+       descriptor is valid and substitute "/dev/null" when not.
+
+2000-03-12  Mikael Djurfeldt  <mdj@thalamus.nada.kth.se>
+
+       * coop-defs.h (struct timespec): Conditionally defined.
+
+       * coop.c (coop_condition_variable_timed_wait_mutex): Use ETIMEDOUT
+       instead of ETIME.
+
+       * readline.c (match_paren): Bugfix: First arg to select is not
+       number of descriptors but the number of the highest descriptor +
+       1.
+
+       This is a preliminary attempt at a cleanup of the threads support
+       code.  It moves things to better places, makes arguments more
+       consistent with the POSIX API (which is used in GNOME's glib), and
+       adds new functionality.
+
+       * readline.c (scm_init_readline): Added new arg to scm_init_mutex.
+
+       * coop-defs.h (scm_mutex_trylock): New macro: alias for
+       coop_mutex_trylock.
+       (scm_cond_init): Changed definition to
+       coop_new_condition_variable_init.
+
+       * coop.c: #include <errno.h>
+       (coop_timeout_qinsert): Moved here from iselect.c
+       (coop_new_mutex_init, coop_new_condition_variable_init): New
+       functions.  The strange names are temporary.  Use scm_mutex_init
+       and scm_cond_init instead.
+       (coop_mutex_trylock): New function.  Uses errno.h:EBUSY.  errno.h
+       is ANSI C, but should we check for individual error codes in
+       configure.in?
+       (coop_condition_variable_timed_wait_mutex): New function.
+       (coop_key_create, coop_setspecific, coop_getspecific,
+       coop_key_delete): New functions.
+
+       * iselect.c (coop_timout_qinsert): Moved to coop.c
+
+2000-03-11  Mikael Djurfeldt  <mdj@thalamus.nada.kth.se>
+
+       * pairs.h (SCM_SETAND_CAR, SCM_SETAND_CDR, SCM_SETOR_CAR,
+       SCM_SETOR_CDR): Corrected SCM_ASSCM/WORD fixes.
+
+       * tags.h (SCM_VOIDP_TEST): Renamed from VOIDP_TEST.
+       Layout cleanups.
+
+       * objects.h (SCM_CLASS_FLAGS, SCM_OBJ_CLASS_FLAGS,
+       SCM_SET_CLASS_INSTANCE_SIZE), struct.h (SCM_STRUCT_VTABLE_DATA),
+       proc.h (SCM_CLOSCAR): SCM_ASSCM/WORD fixes.
+
+       * eval.c (scm_lookupcar1): Inserted SCM_ASWORD in expressions
+       dealing with ilocs.
+
+2000-03-11  Dale P. Smith  <dpsm@en.com>, applied by Greg J. Badros, <gjb@cs.washington.edu>
+
+        * numbers.c (scm_copy_big_dec, scm_copy_smaller, scm_big_ior,
+        scm_big_xor, scm_big_and, scm_big_test): Added new lowlevel bignum
+        logical functions from SCM.
+
+        (logand, logior, logxor, logtest, logbit?): Extended scheme
+        logical functions to use bignums from SCM.
+
+        (lognot): Removed call to `SCM_VALIDATE_INUM' that prevented
+        lognot from using bignums.
+
+Thu Mar  9 11:33:25 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * vectors.h (SCM_VELTS_AS_STACKITEMS): Added this macro to help in
+       eliminating some warnings.
+
+       * unif.c, strports.c, print.c, options.c: Fix some warnings on
+       mis-use of SCM/long
+
+       * gc.c, gc.h: Added scm_return_first_int(), and added comment re:
+       what the scm_return_first* functions do.
+
+2000-03-09  Han-Wen Nienhuys  <hanwen@cs.uu.nl>, applied by Greg J. Badros, <gjb@cs.washington.edu>
+
+       * libguile/*.[ch]: make a distinction between SCM as a generic
+       name for a Scheme object (now a void*), and SCM as 32 bit word for
+       storing tags and immediates (now a long int).  Introduced
+       SCM_ASWORD and SCM_ASSCM for conversion. Fixed various dubious
+       code in the process: arbiter.c (use macros), unif.c (scm_array_p),
+
+Wed Mar  8 10:15:59 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * numbers.c:  Use SCM_VALIDATE_LONG_COPY, and longs, not ints, in
+       various logXXX primitives.  Thanks Eric Moore!
+
+Tue Mar  7 08:05:22 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * run-test, remaining-docs-needed:  Added these scripts.  The
+       second one is only temporary until the docstring additions are
+       complete.   run-test may best live on, but is here mostly for
+       convenience and awareness for now.
+
+       * hash.c: Docs, minor cleanup patch from Dirk Herrman.
+
+Thu Mar  2 16:06:58 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * error.h, error.c: Added `scm_wrong_type_arg_msg' to support
+       displaying the expected type.  Use SCM_LISTn in a couple places
+       instead of scm_cons-ing by hand.
+
+       * __scm.h: Added SCM_ASSERT_TYPE macro.
+
+       * validate.h, scm_validate.h: Added the former, as a renamed
+       version of the latter with SCM_ASSERT_TYPE used in
+       SCM_MAKE_VALIDATE (instead of just SCM_ASSERT)
+
+       * Makefile.am: Rename scm_validate.h to validate.h.
+
+       * *.c, *.h: Include validate.h, not scm_validate.h (old name's
+       prefix was superfluous).
+
+Thu Mar  2 15:33:12 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * hashtab.c: Improved documentation for lots of functions.  Added
+       handwritten docs for `hash-fold'.
+
+Thu Mar  2 15:13:25 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * list.c: Added hand-written docs for `del{q,v,ete}1!'.
+
+Thu Mar  2 12:38:30 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * list.c: Moved append docs to append! Thanks Dirk Hermann.  Also,
+       added append docs from R4RS.
+
+       * strings.c: Docstring typo fix, + eliminate unneeded IMP tests.
+       Thanks Dirk Hermann!
+
+       * chars.h: Provide SCM_CHARP, SCM_CHAR, SCM_MAKE_CHAR and
+       deprecate SCM_ICHRP, SCM_ICHR, SCM_MAKICHR.  Thanks Dirk Hermann!
+
+       * *.h, *.c: Use SCM_CHARP, SCM_CHAR, SCM_MAKE_CHAR throughout.
+       Drop use of SCM_P for function prototypes... assume an ANSI C
+       compiler.  Thanks Dirk Hermann!
+
+Sat Feb 19 12:20:12 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * ports.c: Made `set-port-column!' and `set-port-line!' each
+       return SCM_UNSPECIFIED instead of a (not-scheme-object) integer
+       that caused a seg fault.  Also fixed `set-port-column!'s
+       docstring.  Thanks Han-Wen Nienhuys for finding the bug!
+
+Sun Feb 13 19:11:42 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * arbiters.c, eq.c, gc.c, guardians.c, list.c, ports.c, print.c,
+       regex-posix.c, scmsigs.c, stime.c, strings.c, variable.c, stime.c,
+       strings.c, variable.c:  Added lots of documentation, cleaned up
+       some existing documentation.  Occasionally changed formal params
+       to match docs.  Also folded an #ifdef into the inners of a
+       primitive instead of having two copies of the primitive
+       (`get-internal-real-time', from stime.c)
+
+Sun Feb 13 18:12:19 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * ports.c: Added docs for primitives missing them.  Written by
+       hand.
+
+Sun Feb 13 09:40:36 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * guile-doc-snarf.in: Use ${AWK} -f guile-func-name-check, not
+       just execing guile-func-name-check.  Thanks Michael Livshin!
+
+Thu Feb 10 11:43:23 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * guile-snarf.awk.in: Tweak to work with Sun/HP awk, removed some
+       dead code.  Patch from Michael Livshin.
+
+       * guile-doc-snarf.in: Tweak to work with Sun/HP sh.  Patch from
+       Michael Livshin.
+
+2000-02-09  Gary Houston  <ghouston@arglist.com>
+
+       * init.c (scm_init_standard_ports): when stdout is a tty, make the
+       current-output-port unbuffered by default.  this is less confusing
+       for interactive use.  it was line-buffered because of a
+       performance problem with unbuffered ports, but I think it will be
+       OK now.
+
+2000-02-08  Gary Houston  <ghouston@arglist.com>
+
+       * __scm.h: don't define long_long or ulong_long if HAVE_LONG_LONGS
+       is not defined.
+
+       * stime.c (scm_localtime, scm_mktime): if neither HAVE_TM_ZONE nor
+       HAVE_TZNAME are defined, use an empty string instead of giving two
+       spurious compile-time errors.
+
+Tue Feb  8 13:57:46 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * ports.c: Doc patches from Richard Kim.  Pasted from MIT Scheme.
+       Thanks Richard!
+
+Mon Feb  7 09:07:31 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * macros.c: Doc patches from Richard Kim.  Pasted from scm.texi.
+
+Sun Feb  6 20:26:21 2000  Greg J. Badros  <gjb@cs.washington.edu>
+
+       * pairs.c: Doc patches from Richard Kim.  Pasted from MIT Scheme
+       (which is GNU GPL'd).
+
+2000-01-31  Gary Houston  <ghouston@arglist.com>
+
+       * strings.h: don't use SCM_P.  don't include <string.h>.
+       * error.c, gh_data.c, ports.c, script.c, strop.c: include <string.h>.
+
+       * strings.c (scm_string_ref): make the 2nd argument compulsory.
+       previously it defaulted to zero for no good reason that I can see.
+       use a local variable for SCM_INUM (k).  replace
+       SCM_VALIDATE_INUM_DEF with SCM_VALIDATE_INUM_COPY.
+
+       (scm_makfromstr): cosmetic changes.
+
+       (scm_string): Accept only chars in the list, not strings, for
+       conformance to R5RS (particularly for list->string, which is
+       supposed to be the inverse of string->list.)  remove
+       SCM_DEFER_INTS/SCM_ALLOW_INTS, which is unnecessary since
+       scm_makstr handles the cell allocation.  when reporting wrong-type
+       arg, don't report the position as 1.
+
+       * posix.c (scm_init_posix): intern PIPE_BUF if it's defined.
+
 2000-01-29  Gary Houston  <ghouston@arglist.com>
 
        * posix.c (scm_pipe): rewrote the docstring.
@@ -7,7 +782,7 @@
        "select" tests port buffers for the ability to provide input
        or accept output.  Previously only the underlying file descriptors
        were checked.  Rewrote the docstring.
+
 Thu Jan 27 10:14:25 2000  Greg J. Badros  <gjb@cs.washington.edu>
 
        * vectors.c, symbols.c, strorder.c: Documentation cut and pasted
@@ -29,13 +804,13 @@ Wed Jan 26 17:33:52 2000  Greg J. Badros  <gjb@cs.washington.edu>
 
 Wed Jan 26 10:02:11 2000  Greg J. Badros  <gjb@cs.washington.edu>
 
-       * tag.c:  Added doc for `tag', but mark as deprecated since Mikael 
+       * tag.c:  Added doc for `tag', but mark as deprecated since Mikael
        suggests removing tag.c altogether (and using a new `class-of'
        instead).
 
        * strings.c:  Added documentation from Gregg A. Reynolds.  Edited
        a bit by me to use FOO instead of @var{foo} and to have the
-       summary come before preconditions on input.  Also dropped trailing 
+       summary come before preconditions on input.  Also dropped trailing
        (rnrs) note.
 
        * gsubr.c: Do not use SCM_DEFINE for `gsubr-apply'. Register the
@@ -57,7 +832,7 @@ Tue Jan 25 17:15:47 2000  Greg J. Badros  <gjb@cs.washington.edu>
        * eq.c: Added docs for eq?, eqv? equal? abridged from R4RS.
 
        * boolean.c: Added docs for `not', `boolean?' (by hand).
-       
+
 Tue Jan 25 13:28:56 2000  Greg J. Badros  <gjb@cs.washington.edu>
 
        * random.c: Added documentation, from SLIB page:
@@ -71,7 +846,7 @@ Mon Jan 24 17:50:20 2000  Greg J. Badros  <gjb@cs.washington.edu>
 
 2000-01-23  Gary Houston  <ghouston@arglist.com>
 
-       * filesys.c (scm_chown): omit port/fdes support if HAVE_FCHOWN is 
+       * filesys.c (scm_chown): omit port/fdes support if HAVE_FCHOWN is
        not defined (thanks to Richard Y. Kim).
 
 Thu Jan 20 13:00:38 2000  Greg J. Badros  <gjb@cs.washington.edu>
@@ -118,7 +893,7 @@ Tue Jan 18 13:21:08 2000  Mikael Djurfeldt  <mdj@r11n07-s.pdc.kth.se>
           stacks.c, stime.c, strings.c, strop.c, strports.c, struct.c,
           symbols.c, throw.c, unif.c, vectors.c, version.c, vports.c,
           weaks.c: Converted docstrings to ANSI C format.
-       
+
        * filesys.c (scm_chmod), simpos.c (scm_system), version
        (scm_version), vports (scm_make_soft_port): Escape " occuring
        inside docstring.
@@ -154,7 +929,7 @@ Tue Jan 11 18:24:18 2000  Greg J. Badros  <gjb@cs.washington.edu>
        * guile-doc-snarf.in: Use new $fullfilename for running
        guile-func-name-check, and put "$fullfilename" and "$filename" in
        quotes at uses to make sure re-splitting on whitespace does not
-       occur (so filenames w/ embedded whitespace would work okay, though 
+       occur (so filenames w/ embedded whitespace would work okay, though
        I sure hope we never have to deal with that! :-) ).  Thanks to
        Mikael for pointing out the source_dir != build_dir was broken.
 
@@ -232,7 +1007,7 @@ Tue Jan 11 13:44:07 2000  Greg J. Badros  <gjb@cs.washington.edu>
        * ramap.c: Fix #if 0'd out code to be syntactically acceptable to
        guile-func-name-check.
 
-       * guile-doc-snarf.in: Run guile-func-name-check on the file before 
+       * guile-doc-snarf.in: Run guile-func-name-check on the file before
        doing the snarf.
 
 Tue Jan 11 11:31:10 2000  Greg J. Badros  <gjb@cs.washington.edu>
@@ -257,7 +1032,7 @@ Tue Jan 11 10:41:46 2000  Greg J. Badros  <gjb@cs.washington.edu>
 
        * print.h, print.c (scm_simple_format): Added `simple-format'
        primitive.  It's the old scm_display_error, with ARGS now a rest
-       parameter, and the destination first instead of last (and a couple 
+       parameter, and the destination first instead of last (and a couple
        new capabilities inspired by `format' -- #t as destination means
        current-output-port, #f means return the formatted text as a
        string.
@@ -278,7 +1053,7 @@ Tue Jan 11 10:41:46 2000  Greg J. Badros  <gjb@cs.washington.edu>
        * dynl.c: Use ANSI prototypes.
        (sysdep_dynl_link): Use lt_dlopenext instead of lt_dlopen.
        * scmconfig.h.in: Do not change, as it is automatically generated.
-       
+
     1999-07-25  Thomas Tanner  <tanner@ffii.org>
 
            * dynl-dl.c, dynl-dld.c, dynl-shl.c, dynl-vms.c: deleted
@@ -315,12 +1090,12 @@ Tue Jan 11 10:41:46 2000  Greg J. Badros  <gjb@cs.washington.edu>
        scm_lookupcar1: throw an error with key 'unbound-variable instead
        of 'misc-error when an unbound variable is encountered.
 
-       * filesys.c (scm_mkdir, scm_rmdir, scm_getcwd, scm_select, 
+       * filesys.c (scm_mkdir, scm_rmdir, scm_getcwd, scm_select,
        scm_symlink, scm_readlink, scm_lstat),
        posix.c (scm_setpgid, scm_setsid, scm_ctermid, scm_tcgetpgrp,
        scm_tcsetpgrp, scm_uname, scm_setlocale, scm_mknod, scm_nice,
        scm_sync),
-       simpos.c (scm_system), 
+       simpos.c (scm_system),
        stime.c (scm_times, scm_strptime):
        move the HAVE_XXX feature tests out of the procedure bodies.
        don't use SCM_SYSMISSING.
@@ -344,9 +1119,9 @@ Fri Jan  7 15:50:46 2000  Greg J. Badros  <gjb@cs.washington.edu>
        * scm_validate.h (SCM_OUT_OF_RANGE): Use scm_out_of_range_pos to
        report the position of the argument.
 
-       * error.h, error.c (scm_out_of_range_pos):  Added this function to 
+       * error.h, error.c (scm_out_of_range_pos):  Added this function to
        take extra "pos" argument, the position number of the errant
-       argument. 
+       argument.
 
        * debug.c: Use SCM_OUT_OF_RANGE instead of scm_out_of_range.
 
@@ -385,7 +1160,7 @@ Thu Jan  6 11:22:53 2000  Greg J. Badros  <gjb@cs.washington.edu>
 
 Thu Jan  6 11:21:49 2000  Greg J. Badros  <gjb@cs.washington.edu>
 
-       * alist.c: Do not report mismatch errors on some uses of `tmp' (do 
+       * alist.c: Do not report mismatch errors on some uses of `tmp' (do
        this by using SCM_ARG2 instead of `2' in the SCM_VALIDATE_CONS
        macro call.
 
@@ -448,7 +1223,7 @@ Wed Jan  5 10:50:39 2000  Greg J. Badros  <gjb@cs.washington.edu>
        formal in the current argument snarfing check.
 
        * snarf.h: Give new definition of SCM_ASSERT when in
-       snarfing mode to output a lexically-identifiable sequence that the 
+       snarfing mode to output a lexically-identifiable sequence that the
        guile-snarf.awk script uses to verify argument/position matching.
 
        * ramap.c: Remove extraneous #undef FUNC_NAME.
@@ -456,7 +1231,7 @@ Wed Jan  5 10:50:39 2000  Greg J. Badros  <gjb@cs.washington.edu>
 Wed Jan  5 08:36:38 2000  Greg J. Badros  <gjb@cs.washington.edu>
 
        * guile-doc-snarf.awk.in: Removed -- guile-snarf.awk.in is the
-       current version of the same functionality; it writes the .x output 
+       current version of the same functionality; it writes the .x output
        to stdout instead of directly into the file.
 
 Wed Jan  5 08:15:04 2000  Greg J. Badros  <gjb@cs.washington.edu>
@@ -488,7 +1263,7 @@ Tue Jan  4 14:21:35 2000  Greg J. Badros  <gjb@cs.washington.edu>
 Mon Jan  3 08:30:02 2000  Greg Harvey  <Greg.Harvey@thezone.net> (applied --01/03/00 gjb)
 
        * gc.c (scm_debug_newcell): Added SCM_SETCAR of the newly
-       allocated cell. 
+       allocated cell.
 
        * pairs.h: Added a comment about the need for the SCM_SETCAR in
        SCM_NEWCELL macro.