summaryrefslogtreecommitdiff
path: root/typd_mlc.c
diff options
context:
space:
mode:
authorIvan Maidanski <ivmai@mail.ru>2011-07-26 18:30:36 +0200
committerIvan Maidanski <ivmai@mail.ru>2011-07-26 18:30:36 +0200
commit3c50a689ca85f4fe56afbc8da9e894c4cc3af845 (patch)
tree63fc7287fe3951a51b0490573d097e3b899d8dca /typd_mlc.c
parent15a8bd002db68408468ee450c09f7af3975782e8 (diff)
gc7.0alpha5 tarball importgc7_0alpha5
Diffstat (limited to 'typd_mlc.c')
-rw-r--r--typd_mlc.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/typd_mlc.c b/typd_mlc.c
index cdedf46..1124ff9 100644
--- a/typd_mlc.c
+++ b/typd_mlc.c
@@ -587,9 +587,9 @@ void * GC_malloc_explicitly_typed(size_t lb, GC_descr d)
if(SMALL_OBJ(lb)) {
lg = GC_size_map[lb];
opp = &(GC_eobjfreelist[lg]);
- FASTLOCK();
- if( !FASTLOCK_SUCCEEDED() || (op = *opp) == 0 ) {
- FASTUNLOCK();
+ LOCK();
+ if( (op = *opp) == 0 ) {
+ UNLOCK();
op = (ptr_t)GENERAL_MALLOC((word)lb, GC_explicit_kind);
if (0 == op) return 0;
lg = GC_size_map[lb]; /* May have been uninitialized. */
@@ -597,7 +597,7 @@ void * GC_malloc_explicitly_typed(size_t lb, GC_descr d)
*opp = obj_link(op);
obj_link(op) = 0;
GC_bytes_allocd += GRANULES_TO_BYTES(lg);
- FASTUNLOCK();
+ UNLOCK();
}
} else {
op = (ptr_t)GENERAL_MALLOC((word)lb, GC_explicit_kind);
@@ -620,16 +620,16 @@ DCL_LOCK_STATE;
if( SMALL_OBJ(lb) ) {
lg = GC_size_map[lb];
opp = &(GC_eobjfreelist[lg]);
- FASTLOCK();
- if( !FASTLOCK_SUCCEEDED() || (op = *opp) == 0 ) {
- FASTUNLOCK();
+ LOCK();
+ if( (op = *opp) == 0 ) {
+ UNLOCK();
op = (ptr_t)GENERAL_MALLOC_IOP(lb, GC_explicit_kind);
lg = GC_size_map[lb]; /* May have been uninitialized. */
} else {
*opp = obj_link(op);
obj_link(op) = 0;
GC_bytes_allocd += GRANULES_TO_BYTES(lg);
- FASTUNLOCK();
+ UNLOCK();
}
} else {
op = (ptr_t)GENERAL_MALLOC_IOP(lb, GC_explicit_kind);
@@ -669,9 +669,9 @@ DCL_LOCK_STATE;
if( SMALL_OBJ(lb) ) {
lg = GC_size_map[lb];
opp = &(GC_arobjfreelist[lg]);
- FASTLOCK();
- if( !FASTLOCK_SUCCEEDED() || (op = *opp) == 0 ) {
- FASTUNLOCK();
+ LOCK();
+ if( (op = *opp) == 0 ) {
+ UNLOCK();
op = (ptr_t)GENERAL_MALLOC((word)lb, GC_array_kind);
if (0 == op) return(0);
lg = GC_size_map[lb]; /* May have been uninitialized. */
@@ -679,7 +679,7 @@ DCL_LOCK_STATE;
*opp = obj_link(op);
obj_link(op) = 0;
GC_bytes_allocd += GRANULES_TO_BYTES(lg);
- FASTUNLOCK();
+ UNLOCK();
}
} else {
op = (ptr_t)GENERAL_MALLOC((word)lb, GC_array_kind);