| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
* libguile/threads.c (scm_unlock_mutex): Bind to unlock-mutex.
* libguile/threads.h: Remove scm_unlock_mutex_timed.
* libguile/deprecated.h: Add scm_unlock_mutex_timed.
* libguile/deprecated.c (scm_unlock_mutex_timed): Deprecate.
* test-suite/tests/threads.test: Update unlock-mutex tests to use
wait-condition-variable if they would wait on a cond.
|
|
|
|
|
|
|
|
|
| |
* libguile/threads.c (fat_mutex): Remove unchecked_unlock member.
(make_fat_mutex): Adapt.
(scm_make_mutex_with_flags): Remove unchecked-unlock flag.
(scm_make_recursive_mutex): Likewise.
(fat_mutex_unlock): Remove unchecked-unlock case.
* test-suite/tests/threads.test: Remove unchecked-unlock test.
|
|
|
|
|
|
| |
* libguile/threads.c (fat_mutex_lock): Remove abandoned mutex error, as
SRFI-18 is responsible for this.
* test-suite/tests/threads.test: Update test.
|
|
|
|
|
|
|
|
| |
* libguile/threads.c (scm_lock_mutex_timed): Deprecate "owner"
argument.
(fat_mutex_lock): Remove owner argument.
(fat_mutex_unlock): Don't pass owner to scm_lock_mutex_timed.
* test-suite/tests/threads.test: Remove tests of mutex-owner.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* NEWS: Add entry.
* doc/ref/api-scheduling.texi (Threads): Remove thread-cleanup docs.
* libguile/threads.c (guilify_self_1, do_thread_exit):
(scm_set_thread_cleanup_x, scm_thread_cleanup): Remove these.
* libguile/threads.h (scm_i_thread): Remove cleanup_handler.
* module/ice-9/threads.scm:
* module/ice-9/deprecated.scm (thread-cleanup, set-thread-cleanup!):
Remove.
* test-suite/tests/threads.test: Adapt to test cancel-thread return
values and not test thread-cleanup procs.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reported by Sylvain Beucler <beuc@beuc.net>.
* configure.ac: Check for 'pthread_cancel'.
* libguile/threads.c (scm_cancel_thread): Conditionalize on
!SCM_USE_PTHREAD_THREADS || defined HAVE_PTHREAD_CANCEL.
* test-suite/tests/threads.test (require-cancel-thread): New procedure.
("timed joining fails if timeout exceeded", "join-thread returns
timeoutval on timeout", "cancel succeeds", "handler result passed to
join", "can cancel self"): Use it.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixes <http://bugs.gnu.org/13188>.
Reported by Nala Ginrut <nalaginrut@gmail.com>.
* module/ice-9/futures.scm (%nesting-level): Rename to...
(%nesting-level): ... this. Default to 0 instead of #f. Update
users.
(%max-nesting-level): New variable.
(touch): When FUTURE is queued and (%nesting-level) is above
%MAX-NESTING-LEVEL, abort to %FUTURE-PROMPT.
* test-suite/tests/future.test ("nested futures")["loop"]: Remove
`compile' call.
* test-suite/tests/threads.test ("par-map")["long list"]: New test.
* doc/ref/api-scheduling.texi (Futures): Add a paragraph about stack
consumption.
|
|
|
|
|
|
|
|
|
| |
* test-suite/lib.scm (clear-stale-stack-references): New helper.
* test-suite/tests/gc.test:
* test-suite/tests/threads.test: Use the new helper.
I removed the "unresolved" throw, as I'd like to see what the bots do
with this.
|
|
|
|
|
|
|
|
| |
* test-suite/tests/gc.test (stack-cleanup): New procedure.
("Unused modules are removed"): Use it.
* test-suite/tests/threads.test (stack-cleanup): Likewise.
("mutex with owner not retained (bug #27450)"): Use it.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* libguile/posix.c (scm_total_processor_count,
scm_current_processor_count): Move to...
* libguile/threads.c: ... here.
* libguile/posix.h (scm_total_processor_count,
scm_current_processor_count): Move declarations to...
* libguile/threads.h: ... here.
* test-suite/tests/posix.test ("nproc"): Move tests to...
* test-suite/tests/threads.test: ... here.
|
|
|
|
|
|
|
| |
* test-suite/tests/threads.test ("timed locking succeeds if mutex
unlocked within timeout", "timed unlocking returns #t if condition
signaled", "timed joining succeeds if thread exits within timeout"):
Increase the timeout. Reported by Dale P. Smith <dsmich@roadrunner.com>.
|
|
|
|
|
|
|
|
|
|
|
| |
* module/ice-9/threads.scm (parallel, par-mapper): Rewrite in terms of
`future' and `touch'.
* test-suite/tests/threads.test ("par-map", "par-for-each"): New test
prefixes.
* doc/ref/api-scheduling.texi (Parallel Forms): Add cross-ref to
futures. Recommend against the `n-' variants.
|
|
|
|
|
|
|
|
|
| |
* libguile/threads.c (do_thread_exit): Deal with `t->mutexes' being a
weak list.
(fat_mutex_lock): Use weak-car pairs when building up `t->mutexes'.
* test-suite/tests/threads.test ("mutex-ownership")["mutex with owner
not retained (bug #27450)"]: New test.
|
|
|
|
|
|
|
|
|
|
| |
(Not quite finished, the following will be done tomorrow.
module/srfi/*.scm
module/rnrs/*.scm
module/scripts/*.scm
testsuite/*.scm
guile-readline/*
)
|
|
|
|
|
|
|
|
|
| |
* libguile/threads.c (scm_join_thread_timed): Recheck t->exited before
looping round to call block_self again, in case thread t has now
exited.
* test-suite/tests/threads.test ("don't hang when joined thread
terminates in SCM_TICK"): New test.
|
|
|
|
|
|
|
|
|
|
| |
* libguile/threads.c (fat_mutex_unlock): Unblock asyncs when breaking
out of loop.
* test-suite/tests/threads.test (asyncs-still-working?): New function,
to test if asyncs are working (i.e. unblocked). Use this throughout
threads.test, in particular before and after the "timed locking
succeeds if mutex unlocked within timeout" test.
|
| |
|
| |
|
|
|
|
| |
condvar primitives, in preparation for SRFI-18 support.
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|