The collector now has an abstract interface onto the embedder. The
embedder has to supply some functionality, such as tracing and
forwarding. This is a pretty big change in terms of lines but it's
supposed to have no functional or performance change.
We're targetting systems that need to be able to inspect the kind of an
object, so this information has to be somewhere. If it's out-of-line,
we might save memory, but we would lose locality. Concretely in Guile
the tag bits are in the object itself.
Fixes <https://bugs.gnu.org/55596>.
Reported by Hugo Nobrega <hugonobrega@ic.ufrj.br>
and Jack Hill <jackhill@jackhill.us>.
* libguile/posix.c (start_child): Close OUT only if it's greater than 2.
* test-suite/tests/posix.test ("system*")["exit code for nonexistent file"]
["https://bugs.gnu.org/55596"]: New tests.
Fixes <https://bugs.gnu.org/49223>.
Reported by Domagoj Stolfa <ds815@gmx.com>.
Backport of Guix commit b36267b1d96ac344d2b42c9822ce04b4c3117f85.
* guix/build/download.scm (tls-wrap): Retry up to 5 times when
'handshake' throws a non-fatal error.
The custom input/output port wrapping the TLS session record port would
introduce overhead, and it would also prevent its uses in a non-blocking
context--e.g., with Fibers. The port close mechanism added in GnuTLS
3.7.7 allows us to get rid of that wrapper.
Backported from Guix commit dd573ceea73295c7a872088ecd91e5f0fd74bf2b.
* web/client.scm (wrap-record-port-for-gnutls<3.7.7): New procedure,
with code formerly in 'tls-wrap'.
(tls-wrap): Check for 'set-session-record-port-close!' and use it when
available; otherwise call 'wrap-record-port-for-gnutls<3.7.7'.
Firstly, we add a priority evacuation reserve to prioritize having a few
evacuation blocks on hand. Otherwise if we give them all to big
allocations first and we have a fragmented heap, we won't be able to
evacuate that fragmented heap to give more blocks to the large
allocations.
Secondly, we remove `enum gc_reason`. The issue is that with multiple
mutator threads, the precise thread triggering GC does not provide much
information. Instead we should make choices on how to collect based on
the state of the heap.
Finally, we move detection of out-of-memory inside the collector,
instead of the allocator.
Together, these changes let mt-gcbench (with fragmentation) operate in
smaller heaps.
Marking conservative roots in place effectively prohibits them from
being moved, and we need to trace the roots anyway to discover
conservative roots. No need therefore for a pin bit.