On Mar 18, 2010, at 12:46 PM, Roy Stogner wrote:
> The assert, or the assert and the bool both? I was thinking of
> setting the bool even in opt mode, in case any user had a use for it,
> on the theory that it's cheap compared to the TBB overhead... but I
> wouldn't be using it except in debug/de
On Thu, 18 Mar 2010, Derek Gaston wrote:
> On Mar 18, 2010, at 11:57 AM, Roy Stogner wrote:
>
>> I'd like to instead just "enforce" the current restrictions - set a
>> Threads::_now_multithreaded bool to true at the start of and false at
>> the end of any Threads::parallel_* call, and then do a
On Mar 18, 2010, at 11:57 AM, Roy Stogner wrote:
> Most of the Parallel:: functions would break right now if called from
> more than one thread at once. It would be possible in theory to
> change that - e.g. Parallel::max() would first take the max over all
> threads, then take the max over all r
On Thu, 18 Mar 2010, John Peterson wrote:
> On Thu, Mar 18, 2010 at 12:57 PM, Roy Stogner
> wrote:
>>
>> I'd like to instead just "enforce" the current restrictions - set a
>> Threads::_now_multithreaded bool to true at the start of and false at
>> the end of any Threads::parallel_* call, and t
On Thu, Mar 18, 2010 at 12:57 PM, Roy Stogner wrote:
>
> I'd like to instead just "enforce" the current restrictions - set a
> Threads::_now_multithreaded bool to true at the start of and false at
> the end of any Threads::parallel_* call, and then do a
> assert(!Threads::now_multithreaded()) in e
Thoughts? Right now we only call Parallel:: functions from thread 0,
so we should be safe even on non-thread-safe MPI stacks.
But should that change? And what should users be allowed to do?
Most of the Parallel:: functions would break right now if called from
more than one thread at once. It