(let ((table-address (+ (* (hash-table-count *linkage-info*)
sb!vm:linkage-table-entry-size)
sb!vm:linkage-table-space-start))
(let ((table-address (+ (* (hash-table-count *linkage-info*)
sb!vm:linkage-table-entry-size)
sb!vm:linkage-table-space-start))
(aver real-address)
(unless (< table-address sb!vm:linkage-table-space-end)
(error "Linkage-table full (~D entries): cannot link ~S."
(aver real-address)
(unless (< table-address sb!vm:linkage-table-space-end)
(error "Linkage-table full (~D entries): cannot link ~S."
(sb!thread:with-mutex (*foreign-lock*)
(let ((info (or (gethash name *linkage-info*)
(link-foreign-symbol name datap))))
(sb!thread:with-mutex (*foreign-lock*)
(let ((info (or (gethash name *linkage-info*)
(link-foreign-symbol name datap))))
;;; Update the linkage-table. Called during initialization after all
;;; shared libraries have been reopened, and after a previously loaded
;;; Update the linkage-table. Called during initialization after all
;;; shared libraries have been reopened, and after a previously loaded