new(malloc) locks everything in multithreading

Sean Kelly via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Fri Oct 24 15:30:17 PDT 2014


On Friday, 24 October 2014 at 21:02:05 UTC, Kapps wrote:
>
> Yes, GDB is stopping on SIGUSR1 / SIGUSR2 since that's the 
> default settings. D's GC uses these signals for suspending / 
> resuming threads during a collection. You need to type what I 
> said above, prior to typing 'run'.

I took a look at the Boehm GC earlier today and it appears
they've made the signal set configurable, both to try and not use
SIGUSR1/2 by default and to let the user specify another signal
set if they need SIGUSR1/2 for some reason.  It's probably worth
doing this in our own code as well.  The Boehm GC also does some
magic with clearing signals at various points to make sure the
right signal handlers will be called.  Probably another
enhancement request.


More information about the Digitalmars-d-learn mailing list