guile-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Guile bugs


From: Marko Rauhamaa
Subject: Re: Guile bugs
Date: Sun, 10 Sep 2017 01:31:08 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux)

Linas Vepstas <address@hidden>:
> So if you used GC_malloc_atomic() in your code, then gc will NOT scan
> that region for pointers. guile-2.2 does this correctly for strings (I
> checked) because strings will never contain pointers. I have not
> checked other uses.

The question about mmap(2) is addressed more directly by the README
under <URL: https://github.com/ivmai/bdwgc>:

   Any objects not intended to be collected must be pointed to either
   from other such accessible objects, or from the registers, stack,
   data, or statically allocated bss segments. [...]

   WARNING: pointers inside memory allocated by the standard malloc are
   not seen by the garbage collector. Thus objects pointed to only from
   such a region may be prematurely deallocated. It is thus suggested
   that the standard malloc be used only for memory regions, such as I/O
   buffers, that are guaranteed not to contain pointers to garbage
   collectible memory.

   [...]

   WARNING: the collector does not guarantee to scan thread-local
   storage (e.g. of the kind accessed with pthread_getspecific). The
   collector does scan thread stacks

Now, the question is, can you make your multigigabyte allocation go into
these excluded memory segments? Are you still hit by the pathological GC
behavior you reported?


Marko



reply via email to

[Prev in Thread] Current Thread [Next in Thread]