vivace-graph-v2
vivace-graph-v2 copied to clipboard
SBCL gc issues with large data sets
SBCL has been throwing gc-related errors when loading really large data sets:
fatal error encountered in SBCL pid 16473(tid 140737354098432): GC invariant lost, file "gc-common.c", line 1675
and
fatal error encountered in SBCL pid 16339(tid 140737354098432): not a symbol where empty-hash-table-slot symbol expected: 44a
This patch for the SBCL source from Nikodemus fixes the problem:
diff --git a/src/code/target-hash-table.lisp b/src/code/target-hash-table.lisp index 5c5bdb7..fbed30a 100644 --- a/src/code/target-hash-table.lisp +++ b/src/code/target-hash-table.lisp @@ -288,6 +288,7 @@ Examples: future." (declare (type (or function symbol) test)) (declare (type unsigned-byte size))
- (declare (ignore synchronized)) (multiple-value-bind (test test-fun hash-fun) (cond ((or (eq test #'eq) (eq test 'eq)) (values 'eq #'eq #'eq-hash)) @@ -392,7 +393,7 @@ Examples: :element-type '(unsigned-byte #.sb!vm:n-word-bits) :initial-element +magic-hash-vector-value+))
-
:synchronized-p synchronized)))
-
(declare (type index size+1 scaled-size length)) ;; Set up the free list, all free. These lists are 0 terminated. (do ((i 1 (1+ i))):synchronized-p t)))
However, I can find no instances in the vivace-graph code where there are unsafe hash table accesses; this makes me think that one of the support libraries is possibly doing a bad thing.