[OpenACC 3/11] new target hook

Jakub Jelinek jakub@redhat.com
Thu Oct 22 08:23:00 GMT 2015


On Wed, Oct 21, 2015 at 03:13:26PM -0400, Nathan Sidwell wrote:
> 2015-10-20  Nathan Sidwell  <nathan@codesourcery.com>
> 
> 	* target.def (fork_join): New GOACC hook.
> 	* targhooks.h (default_goacc_fork_join): Declare.
> 	* omp-low.c (default_goacc_forkjoin): New.
> 	* doc/tm.texi.in (TARGET_GOACC_FORK_JOIN): Add.
> 	* doc/tm.texi: Regenerate.
> 	* config/nvptx/nvptx.c (nvptx_xform_fork_join): New.
> 	(TARGET_GOACC_FOR_JOIN): Override.

This is ok, with nits.

> --- config/nvptx/nvptx.c	(revision 229096)
> +++ config/nvptx/nvptx.c	(working copy)
> @@ -2146,7 +2146,26 @@ nvptx_goacc_validate_dims (tree ARG_UNUS
>  
>    return changed;
>  }
> -
> +
> +/* Determine whether fork & joins are needed.  */
> +
> +static bool
> +nvptx_xform_fork_join (gcall *call, const int dims[],
> +		       bool ARG_UNUSED (is_fork))

Why is this not called nvptx_goacc_fork_join when that is the name of
the target hook?

	Jakub



More information about the Gcc-patches mailing list