From 4c187162fa29f40746b8794bcbc0c4c52a497f31 Mon Sep 17 00:00:00 2001 From: Tom de Vries Date: Wed, 19 Dec 2018 15:20:06 +0000 Subject: [PATCH] [openacc] Make oacc_fn_attrib_level external Expose oacc_fn_attrib_level to be used in backends. 2018-12-19 Tom de Vries * omp-offload.c (oacc_fn_attrib_level): Remove static. * omp-offload.h (oacc_fn_attrib_level): Declare. From-SVN: r267275 --- gcc/ChangeLog | 5 +++++ gcc/omp-offload.c | 2 +- gcc/omp-offload.h | 1 + 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 8dc0e289f21..7b0ca6357de 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2018-12-19 Tom de Vries + + * omp-offload.c (oacc_fn_attrib_level): Remove static. + * omp-offload.h (oacc_fn_attrib_level): Declare. + 2018-12-19 Tom de Vries * omp-offload.c (oacc_get_default_dim): New function. diff --git a/gcc/omp-offload.c b/gcc/omp-offload.c index 9c7bd7328d1..a220b4b9982 100644 --- a/gcc/omp-offload.c +++ b/gcc/omp-offload.c @@ -88,7 +88,7 @@ vec *offload_funcs, *offload_vars; /* Return level at which oacc routine may spawn a partitioned loop, or -1 if it is not a routine (i.e. is an offload fn). */ -static int +int oacc_fn_attrib_level (tree attr) { tree pos = TREE_VALUE (attr); diff --git a/gcc/omp-offload.h b/gcc/omp-offload.h index 14edcad8a7d..176c4da7e88 100644 --- a/gcc/omp-offload.h +++ b/gcc/omp-offload.h @@ -23,6 +23,7 @@ along with GCC; see the file COPYING3. If not see #define GCC_OMP_DEVICE_H extern int oacc_get_default_dim (int dim); +extern int oacc_fn_attrib_level (tree attr); extern GTY(()) vec *offload_funcs; extern GTY(()) vec *offload_vars; -- 2.30.2