On Tue, 2014-11-04 at 16:45 -0800, Cesar Philippidis wrote:
> Here's an updated version of my nested function patch.
>
> David, I tweaked the gimple class hierarchy a little bit. Here's what
> the updated class diagram looks like:
>
> + gimple_statement_omp
> | | layout: GSS_OMP. Used for code GIMPLE_OMP_SECTION
> | |
> | + gimple_statement_omp_parallel_layout
> | | | layout: GSS_OMP_PARALLEL_LAYOUT
> | | |
> | | + gimple_statement_omp_targetreg
> | | |
> | | + gimple_statement_oacc_kernels
> | | | code: GIMPLE_OACC_KERNELS
> | | |
> | | + gimple_statement_oacc_parallel
> | | | code: GIMPLE_OACC_PARALLEL
> | | |
> | | + gimple_statement_omp_target
> | | code: GIMPLE_OMP_TARGET
>
> Basically, I've introduced gimple_statement_omp_targetreg and made
> GIMPLE_OACC_{PARALLEL,KERNELS} and GIMPLE_OMP_TARGET inherit it. This
> seems to work out pretty good. It cleans up both
> {lower,expand}_oacc_offload in omp-low.c and allows OpenACC kernel and
> parallel regions to be treated as OpenMP target regions in
> tree-nested.c. Are these changes to gimple.h OK?
I'm not a reviewer, so it's not directly up to me, but if it simplifies
the code then it seems reasonable. I'm interested in Jakub's opinion.
> Thomas, assuming these gimple changes are OK, should I commit this
> change to gomp-4_0-branch, or do you want to include this patch with
> your middle end trunk submission?