Re: [Cython] OpenMP thread private variable not recognized (bug report + discussion)

2014-08-12 Thread Brett Calcott
That would be awesome (I love ipython notebook). On Tue, Aug 12, 2014 at 11:20 AM, Sturla Molden wrote: > Brett Calcott > wrote: > > > For someone who has bumbled around trying to use prange & openmp on > the mac > > (but successfully used python threading), this sounds great. Is there an > >

Re: [Cython] OpenMP thread private variable not recognized (bug report + discussion)

2014-08-12 Thread Sturla Molden
Brett Calcott wrote: > For someone who has bumbled around trying to use prange & openmp on the > mac > (but successfully used python threading), this sounds great. Is there an > example of this somewhere that you can point us to? No, but I could make one :) ipython notebook? Sturla

Re: [Cython] OpenMP thread private variable not recognized (bug report + discussion)

2014-08-12 Thread Brett Calcott
On Tue, Aug 12, 2014 at 10:26 AM, Sturla Molden wrote: > The sooner you discover you do not > need Cython's prange, the less pain it will cause. > > For someone who has bumbled around trying to use prange & openmp on the mac (but successfully used python threading), this sounds great. Is there an

Re: [Cython] OpenMP thread private variable not recognized (bug report + discussion)

2014-08-12 Thread Sturla Molden
Cython does not do an error here: - i is recognized as private - r is recognized as reduction - w is (correctly) recognized as shared If you need thread local storage, use threading.local() I agree that scoped cdefs would be an advantage. Personally I prefer to avoid OpenMP and just use Python

[Cython] OpenMP thread private variable not recognized (bug report + discussion)

2014-08-11 Thread Leon Bottou
The attached cython program uses an extension class to represent a unit of work. The with parallel block temporarily gets the gil to allocate the object, then release the gil and performs the task with a for i in prange(...) statement. My expectation was to have w recognized as a thread private