guile-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] Futures: Avoid creating the worker pool more than once


From: Ludovic Courtès
Subject: Re: [PATCH] Futures: Avoid creating the worker pool more than once
Date: Sat, 10 Nov 2012 14:53:48 +0100
User-agent: Gnus/5.130005 (Ma Gnus v0.5) Emacs/24.2 (gnu/linux)

Mark H Weaver <address@hidden> skribis:

> address@hidden (Ludovic Courtès) writes:
>
>> Mark H Weaver <address@hidden> skribis:
>>
>>> +  ;; setting 'create-workers!' to a no-op is an optimization, but it is
>>> +  ;; still possible for '%create-workers!' to be called more than once
>>> +  ;; from different threads.  Therefore, to avoid creating %workers more
>>> +  ;; than once (and thus creating too many threads), we check to make
>>> +  ;; sure %workers is empty within the critical section.
>>
>> Do you have a scenario where this happens?
>
> I'd hoped that the comment above was clear, but let me try again.

Yes, what wasn’t clear to me is how practical this is, and whether
somebody encountered that situation in real life.

Anyway, please apply.

Thanks,
Ludo’.



reply via email to

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