Search found 5 matches

by PGK
Tue Jun 11, 2013 7:58 am
Forum: OpenMP 4.0 Public Review Release Candidates
Topic: Accelerators and the target Constructs
Replies: 0
Views: 51433

Accelerators and the target Constructs

I have a few thoughts and questions regarding the very interesting inclusion of accelerators within the second OpenMP 4.0 Public Release Candidate. First of all, I was surprised that there is no reference to the word "accelerator" in the document. I searched for that word due to the title of the ear...
by PGK
Wed Sep 12, 2012 2:53 am
Forum: Using OpenMP
Topic: Unique addresses with threadprivate?
Replies: 2
Views: 5610

Re: Unique addresses with threadprivate?

Hi, I assigned x to gnum using the code below, and still see the duplicates. int lvl = omp_get_level(); int anum = omp_get_ancestor_thread_num(lvl-1); int nthreads = omp_get_num_threads(); int gnum = (anum*nthreads)+omp_get_thread_num(); x = gnum; The compiler was GCC 4.5.3 under cygwin. I also trie...
by PGK
Fri Sep 07, 2012 7:09 am
Forum: Using OpenMP
Topic: Unique addresses with threadprivate?
Replies: 2
Views: 5610

Unique addresses with threadprivate?

I had thought that a threadprivate variable within a parallel region would have a unique address for each thread. With code based on the following, I often see duplicate addresses. Am I on the right track? Is this a bug in the implementation? int main(int argc, char *argv[]) { static int x; #pragma ...
by PGK
Mon Aug 01, 2011 12:47 pm
Forum: Using OpenMP
Topic: threadprivate as default
Replies: 1
Views: 3190

threadprivate as default

Is it possible to make static/global/namespace scope variables behave as if threadprivate, by default - as if each such variable was followed by a threadprivate directive?

-- PGK
by PGK
Thu Jan 28, 2010 8:01 am
Forum: OpenMP 3.0 API Specifications
Topic: c99 _Pragma operator in OpenMP
Replies: 1
Views: 25515

c99 _Pragma operator in OpenMP

Hi all, Is the C99 _Pragma supported by OpenMP? The more common #pragma is first discussed on Page #21: In C/C++, OpenMP directives are specified by using the #pragma mechanism provided by the C and C++ standards. Which could imply that a compliant OpenMP c99 compiler would translate something like:...