> [RFC,PATCH] Do not GC_INIT the Boehm GC if already initialized On 06-02-2023 19:34, Jose E. Marchesi wrote: > > Hello Guile hackers. > > We are in the process of integrating GNU poke[1] in GDB by mean of > libpoke. > > Problem is, libpoke uses the Boehm GC, as guile does. We are working on > switching to an ad-hoc exact collector, but it will get some time. > > So, in the interim, we may: > > 1) Make both libguile and libpoke to do GC_INIT conditionally, only if > no one else has initialized the collector before. This is already in > poke master. A suggested (untested!) patch for guile below. > [...] According to the Boehm GC documentation, this 'conditional initialisation' is unnecessary: /* Portable clients should call this at the program start-up. More */ /* over, some platforms require this call to be done strictly from the*/ /* primordial thread. **Multiple invocations are harmless.** */ #define GC_INIT() [...] (emphasis added). Greetings, Maxime