From 75c5ec7b90a5cb1057520a8051ce5033212c77be Mon Sep 17 00:00:00 2001 From: Julian Graham Date: Sat, 24 May 2008 19:11:12 -0400 Subject: [PATCH] Update NEWS file for SRFI-18 and associated core thread changes --- NEWS | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-- 1 files changed, 58 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index 5f84659..a52378b 100644 --- a/NEWS +++ b/NEWS @@ -12,6 +12,7 @@ Changes in 1.9.0: * New modules (see the manual for details) ** The `(ice-9 i18n)' module provides internationalization support +** `(srfi srfi-18)' * Changes to the distribution @@ -26,14 +27,69 @@ be used for efficiently implementing a Scheme code coverage. ** Duplicate bindings among used modules are resolved lazily. This slightly improves program startup times. -** New thread cancellation and thread cleanup API -See `cancel-thread', `set-thread-cleanup!', and `thread-cleanup'. +** Changes and additions to the thread and synchronization API + +There is a new thread cancellation and thread cleanup API. See +`cancel-thread', `set-thread-cleanup!', and `thread-cleanup' in the +manual for details. + +New predicates `mutex?', `condition-variable?', and `mutex-locked?' +have been added. + +Functions for examining the state of a locked mutex, `mutex-level' and +`mutex-owner', have been added. + +Some of the existing thread functions now take optional arguments that +extend their functionality: `make-mutex' now accepts zero or more +flags that allow the user to configure various aspects of the behavior +of the returned mutex; `join-thread' and `lock-mutex' now accept +timeout arguments that allow users to limit the amount of time those +functions will wait; `join-thread' also now has the ability to return +a failure value of the caller's choosing, in order to distinguish +between timeout and threads returning #f; `unlock-mutex' can now +optionally wait for a specified condition variable to be signaled +before returning. See the manual for details. + +Threads waiting on a locked mutex will now be notified if the owner +exits before unlocking it. * Changes to the C interface ** Functions for handling `scm_option' now no longer require an argument indicating length of the `scm_t_option' array. +** Corresponding C functions for the thread API enhancements have been +** added + +These functions provide access to the new features provided by the +Scheme thread API enhancements described above. Where changes to the +signatures of the existing C API would have been required, new functions +with distinct names have been introduced, in order to preserve backwards +compatibility with existing code. + + Synchronization type predicates: + + - SCM scm_mutex_p (SCM obj) + - SCM scm_condition_variable_p (SCM obj) + + Timeout and other enhancements for existing thread primitives: + + - SCM scm_lock_mutex_timed (SCM m, SCM timeout, SCM owner) + - SCM scm_join_thread_timed (SCM t, SCM timeout, SCM timeoutval) + - SCM scm_unlock_mutex_timed (SCM m, SCM cond, SCM timeout) + - SCM scm_make_mutex_with_flags (SCM flags) + + Thread cancellation and cleanup: + + - SCM scm_cancel_thread (SCM t) + - SCM scm_set_thread_cleanup_x (SCM thread, SCM proc) + - SCM scm_thread_cleanup (SCM thread) + + Mutex inspection: + + - SCM scm_mutex_owner (SCM m) + - SCM scm_mutex_level (SCM m) + - SCM scm_mutex_locked_p (SCM m) Changes in 1.8.5 (since 1.8.4) -- 1.5.4.3