mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-04-30 11:50:28 +02:00
(FETCH_STORE) [generic C]: Should be
scm_i_scm_pthread_mutex_lock/unlock now. Reported by Ludovic Courtès.
This commit is contained in:
parent
e96f5ee768
commit
8ff3ca467c
1 changed files with 7 additions and 7 deletions
|
@ -1,4 +1,4 @@
|
|||
/* Copyright (C) 1995,1996, 1997, 2000, 2001, 2004 Free Software Foundation, Inc.
|
||||
/* Copyright (C) 1995,1996, 1997, 2000, 2001, 2004, 2005 Free Software Foundation, Inc.
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
|
@ -64,12 +64,12 @@
|
|||
atomic. Unfortunately this approach probably makes arbiters no faster
|
||||
than mutexes (though still using less memory of course), so some
|
||||
CPU-specifics are highly desirable. */
|
||||
#define FETCH_STORE(fet,mem,sto) \
|
||||
do { \
|
||||
scm_mutex_lock (&scm_i_misc_mutex); \
|
||||
(fet) = (mem); \
|
||||
(mem) = (sto); \
|
||||
scm_mutex_unlock (&scm_i_misc_mutex); \
|
||||
#define FETCH_STORE(fet,mem,sto) \
|
||||
do { \
|
||||
scm_i_scm_pthread_mutex_lock (&scm_i_misc_mutex); \
|
||||
(fet) = (mem); \
|
||||
(mem) = (sto); \
|
||||
scm_i_pthread_mutex_unlock (&scm_i_misc_mutex); \
|
||||
} while (0)
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue