Author: Armin Rigo <[email protected]>
Branch:
Changeset: r40:134108fde888
Date: 2013-05-27 15:28 +0200
http://bitbucket.org/pypy/stmgc/changeset/134108fde888/
Log: Another similar bug
diff --git a/c3/gcpage.c b/c3/gcpage.c
--- a/c3/gcpage.c
+++ b/c3/gcpage.c
@@ -122,8 +122,8 @@
if (stmgc_is_young_in(d, L))
goto found;
}
- assert(0); /* L is not a young pointer anywhere! */
- abort();
+ stmgcpage_release_global_lock();
+ return NULL; /* L is not a young pointer anywhere! */
found:
/* must acquire the collection_lock before releasing the global lock,
diff --git a/c3/nursery.c b/c3/nursery.c
--- a/c3/nursery.c
+++ b/c3/nursery.c
@@ -1042,6 +1042,8 @@
retry.
*/
if (P->h_revision == v) {
+ assert(source_d != NULL);
+
/* careful here: all 'thread_descriptor' accesses will continue
to get the current thread (needed e.g. for stmgcpage_malloc())
which is different from 'source_d', the source thread out of
@@ -1067,7 +1069,9 @@
/* debugging support: "deactivate" the foreign nursery again */
assert(stmgc_nursery_hiding(source_d, 1));
}
- spinlock_release(source_d->collection_lock);
+
+ if (source_d != NULL)
+ spinlock_release(source_d->collection_lock);
}
static void normalize_stolen_objects(struct tx_descriptor *d)
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit