GOMP project OpenMP 3.0 design document

2009-08-09 Thread Qihang Huang
Hi list,

I found some preliminary documents for the initial GOMP project, but
it is old and not much detail. I was wondering whether there is a
design document for OpenMP 3.0? Or something similar. That would be
really helpful.

Many thanks.

Cheers,
Tim


OpenMP 3.0 Task implementation

2009-08-23 Thread Qihang Huang
Hi,

I am currently reading the libgomp source code, hoping to understand
how gcc schedule tasks and how pthread pool is used in a nested
parallel region.

On the manual section, there are implementation ABI for PARALLEL,
SINGLE, etc constructs. But for some reason, I don't find the same
info for TASK construct. I would like to know how gcc transform the
code when encounter a TASK construct in OpenMP 3.0. I am looking for
information details like this (for example,
http://gcc.gnu.org/onlinedocs/gcc-4.4.1/libgomp/Implementing-PARALLEL-construct.html#Implementing-PARALLEL-construct).
Could someone help me out? Many thanks.



Cheers,
Tim


OpenMP 3.0 libgomp ABI documentation for TASK construct

2009-10-03 Thread Qihang Huang
Hi,

>From gcc online docs (http://gcc.gnu.org/onlinedocs/libgomp/), I found
documentations for most of OpenMP constructs, except one very
important construct TASK. I don't know why it is missing, but I really
need to find out how TASK get transformed into GOMP_* routines. I
posted this question before, but haven't got a reply yet. I am very
grateful if someone can point me to the right track. For example, is
there a pretty-print feature of the AST after processing the OpenMP
pragmas? If so, how? Of course, if someone have the expertise, and
directly show me how TASK get transformed, it would be even better!

Many thanks!

Cheers,
Tim


Re: OpenMP 3.0 libgomp ABI documentation for TASK construct

2009-10-05 Thread Qihang Huang
That's super! Thank you Antoniu. With the capacity of printing the
expanded code, it feels a lot more freedom now when reading the source
code of libgomp.

Cheers,
Tim

On Mon, Oct 5, 2009 at 8:29 AM, Antoniu Pop
 wrote:
> Hi Tim,
>
>
>> From gcc online docs (http://gcc.gnu.org/onlinedocs/libgomp/), I found
>> documentations for most of OpenMP constructs, except one very
>> important construct TASK.
>
> I cannot answer this. It may be that the documentation was written
> before tasks (which were introduced in a latter versionĀ  of OpenMP)
> were added to GCC OpenMP.
>
>>
>> I don't know why it is missing, but I really
>> need to find out how TASK get transformed into GOMP_* routines. I
>> posted this question before, but haven't got a reply yet. I am very
>> grateful if someone can point me to the right track. For example, is
>> there a pretty-print feature of the AST after processing the OpenMP
>> pragmas? If so, how? Of course, if someone have the expertise, and
>> directly show me how TASK get transformed, it would be even better!
>
>
> For the pretty print, just use -fdump-tree-ompexp-all on the compile
> line and look for the file *.c.*ompexp that is generated. It contains
> the dump just after OpenMP expansion.
>
> If you need to check out the code generation routines by yourself,
> take a look at gcc/omp-low.c
> Most of everything happens there. There are two passes, OpenMP
> lowerring then expansion. The generation of the GOMP_* routine calls
> happens during expansion pass and so you should start from the
> "expand_omp_taskreg" function (in gcc/omp-low.c).
>
> Best,
> Antoniu
>