Re: parallel GC only after at least one thread was created?
Shiro Kawai <[email protected]> Wed, 27 Mar 2024 10:18:23 -1000
| Newsgroups | gmane.lisp.scheme.gauche |
|---|---|
| Message-ID | <CALN0JNFL9Tnev-a9Xu4dqfVbFXv-V-J=3SbcMzw1g64irKStjg@mail.gmail.com> |
I think this is the change. They took a preventive measure in case the client provides a custom marker procedure which isn't thread-safe. https://github.com/ivmai/bdwgc/commit/020b05d7d567926a023dc428cde7b6add246cd65 For Gauche, I believe we can start parallel markers safely. On Wed, Mar 27, 2024 at 10:02 AM Shiro Kawai <[email protected]> wrote: > It does seem so; when I create the first thread in Gauche, GC spawns a > bunch of marker threads (bdwgc intercepts pthread_create). > > I vaguely remember it wasn't the case before. I'll check bdwgc history. > > > On Wed, Mar 27, 2024 at 6:10 AM Jens Thiele <[email protected]> wrote: > >> Hi, >> >> maybe this is a feature, but from "top" it looks like parallel GC only >> is used after at least one thread was created? >> >> No parallel GC: >> >> #!/usr/bin/env gosh >> (use gauche.threads) >> >> (define (main args) >> (while #t >> (gc)) >> 0) >> >> looks like parallel GC is used: >> >> #!/usr/bin/env gosh >> (use gauche.threads) >> >> (define (main args) >> (let1 t (make-thread (lambda() (+ 1 2))) >> (thread-start! t) >> #?=(thread-join! t)) >> (while #t >> (gc)) >> 0) >> >> Greetings, >> Jens >> >> >> _______________________________________________ >> Gauche-devel mailing list >> [email protected] >> https://lists.sourceforge.net/lists/listinfo/gauche-devel >> > _______________________________________________ Gauche-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/gauche-devel