Re: [PATCH] Apply fix for PR68463 to RS6000

2016-05-11 Thread James Norris
Thomas, On 05/11/2016 09:13 AM, Thomas Schwinge wrote: Hi! On Tue, 10 May 2016 10:39:33 -0500, James Norris <jnor...@codesourcery.com> wrote: The fix for PR68463 (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68463) was missing code that prevented the fix from working on RS6000. The at

[PATCH] Apply fix for PR68463 to RS6000

2016-05-10 Thread James Norris
/ChangeLog b/gcc/ChangeLog index dfbb1c3..1052980 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,11 @@ +2016-05-10 James Norris <jnor...@codesourcery.com> + + * config/rs6000/sysv4.h (CRTOFFLOADBEGIN): Define. Add crtoffloadbegin.o + if offloading is enabled and -fopenacc or -f

Re: [gomp4] Fix handling of subarrays with update directive

2016-03-23 Thread James Norris
Jakub, On 03/23/2016 05:24 AM, Jakub Jelinek wrote: Otherwise LGTM, but please repost it with all the testcase changes you want to make. Attached is the updated patch with the castings added, as well as the updated tests. Thanks! Jim == 2016-03-23 James Norris <j

[gomp4] Fix PR64748

2016-02-16 Thread James Norris
/ChangeLog.gomp (working copy) @@ -1,3 +1,10 @@ +2016-02-15 James Norris <jnor...@codesourcery.com> + + Backport from trunk: + PR c/64748 + * parser.c (cp_parser_oacc_data_clause_deviceptr): Remove checking. + * semantics.c (finish_omp_clauses): Add deviceptr checking. + 2016-02-03 James

Re: [PATCH] Fix PR64748

2016-02-15 Thread James Norris
Hi, Ping! Thanks, Jim On 02/02/2016 08:51 AM, James Norris wrote: Hi! On 02/01/2016 02:03 PM, Jakub Jelinek wrote: On Mon, Feb 01, 2016 at 01:41:50PM -0600, James Norris wrote: The attached patch resolves c/PR64748. The patch adds the use of parm's with the deviceptr clause. [snip

[gomp4] Fix use of declare'd vars by routine procedures.

2016-02-03 Thread James Norris
. Index: gcc/ChangeLog.gomp === --- gcc/ChangeLog.gomp (revision 233104) +++ gcc/ChangeLog.gomp (working copy) @@ -1,3 +1,9 @@ +2016-02-03 James Norris <jnor...@codesourcery.com + + Backport form trunk: + 2016-02-02 James Norris &l

Re: [PATCH] Fix PR64748

2016-02-02 Thread James Norris
Hi! On 02/01/2016 02:03 PM, Jakub Jelinek wrote: On Mon, Feb 01, 2016 at 01:41:50PM -0600, James Norris wrote: The attached patch resolves c/PR64748. The patch adds the use of parm's with the deviceptr clause. [snip snip] --- a/gcc/c/c-parser.c +++ b/gcc/c/c-parser.c @@ -10760,7 +10760,7

[PATCH] Fix PR64748

2016-02-01 Thread James Norris
.c: Add tests. diff --git a/gcc/c/ChangeLog b/gcc/c/ChangeLog index 5341f04..f2d114c 100644 --- a/gcc/c/ChangeLog +++ b/gcc/c/ChangeLog @@ -1,3 +1,8 @@ +2016-02-XX James Norris <jnor...@codesourcery.com> + + PR c/64748 + * c-parser.c (c_parser_oacc_data_clause_deviceptr): Allow parms. + 2

Re: [PATCH] Fix use of declare'd vars by routine procedures.

2016-02-01 Thread James Norris
Hi! On 01/29/2016 02:31 AM, Jakub Jelinek wrote: On Thu, Jan 28, 2016 at 12:26:38PM -0600, James Norris wrote: I think the attached change is what you had in mind with regard to doing the check at gimplification time. Nope, this is still a wrong location for that. If you look at the next

Re: [PATCH] Fix use of declare'd vars by routine procedures.

2016-01-28 Thread James Norris
/ChangeLog (working copy) @@ -1,3 +1,7 @@ +2016-01-XX James Norris <jnor...@codesourcery.com> + + * gimplify.c (gimplify_var_or_parm_decl): Add usage check. + 2016-01-25 Jeff Law <l...@redhat.com> PR tree-optimization/69196 Index: gc

[gomp4] Fix handling of subarrays with update directive

2016-01-22 Thread James Norris
: ChangeLog.gomp === --- ChangeLog.gomp (revision 232740) +++ ChangeLog.gomp (revision 232741) @@ -1,3 +1,11 @@ +2016-01-22 James Norris <jnor...@codesourcery.com> + + * oacc-mem.c (delete_copyout, update_dev_host): Fix device a

[PATCH] Fix use of declare'd vars by routine procedures.

2016-01-17 Thread James Norris
copy) @@ -1,3 +1,7 @@ +2016-01-XX James Norris <jnor...@codesourcery.com> + + * c-parser.c (build_external_ref): Add usage check. + 2016-01-06 David Malcolm <dmalc...@redhat.com> * c-parser.c (c_parser_unary_expression): For dereferences, build Index: gcc/

[gomp4] Remove unnecessary attribute.

2016-01-14 Thread James Norris
/ChangeLog.gomp (revision 232371) +++ gcc/c/ChangeLog.gomp (revision 232372) @@ -1,3 +1,8 @@ +2016-01-14 James Norris <jnor...@codesourcery.com> + + * c-parser.c (c_finish_oacc_routine): Remove attribute. + * c-typeck.c (build_external_ref): Change usage check. + 2016-01-07 James Norris

[gomp4] OpenACC documentation for libgomp.

2016-01-12 Thread James Norris
Hi, Backported: 2016-01-12 James Norris <jnor...@codesourcery.com> * libgomp.texi: Updates for OpenACC. from trunk. Thanks, Jim Index: ChangeLog.gomp === --- ChangeLog.gomp (revision 232292) +++ ChangeLog.gomp (w

Re: [PATCH] OpenACC documentation for libgomp

2016-01-12 Thread James Norris
Bernd, On 01/11/2016 11:23 AM, Bernd Schmidt wrote: On 01/05/2016 04:47 PM, James Norris wrote: I've updated the original patch after some very helpful comments from Sandra (thank you, thank you). OK to commit to trunk? I'm probably not fully qualified to review the contents either, but few

Re: [PATCH] OpenACC documentation for libgomp

2016-01-12 Thread James Norris
Hi! On 01/11/2016 11:35 AM, Jakub Jelinek wrote: On Tue, Jan 05, 2016 at 09:47:59AM -0600, James Norris wrote: I've updated the original patch after some very helpful comments from Sandra (thank you, thank you). I'd prefer if OpenMP * Enabling OpenMP::How to enable OpenMP

Re: [gomp4] Fix use of declare'd vars by routine procedures.

2016-01-11 Thread James Norris
Hi! On 01/11/2016 05:55 AM, Thomas Schwinge wrote: Hi! On Thu, 7 Jan 2016 12:57:32 -0600, James Norris <jnor...@codesourcery.com> wrote: The checking of variables declared by OpenACC declare directives used within an OpenACC routine procedure was not being done correctly. This fi

Re: [PATCH] Remove PTX link option

2016-01-08 Thread James Norris
On 01/08/2016 10:32 AM, Jakub Jelinek wrote: On Fri, Jan 08, 2016 at 10:21:16AM -0600, James Norris wrote: And CU_JIT_TARGET / CU_TARGET_COMPUTE_30 requests JITting only on sm_30 and nothing else, or just on sm_30 or later, something else? This really should be reviewed by somebody familiar

Re: [PATCH] Remove PTX link option

2016-01-08 Thread James Norris
Jakub, On 01/08/2016 09:30 AM, Jakub Jelinek wrote: On Fri, Jan 08, 2016 at 09:24:14AM -0600, James Norris wrote: This patch removes the constraint whereby the PTX emitted was only for sm_30 GPU's. With this removal, the PTX emitted will be targeted for the current context, i.e., attached GPU

Re: [PATCH] Remove PTX link option

2016-01-08 Thread James Norris
Jakub, On 01/08/2016 09:44 AM, Jakub Jelinek wrote: On Fri, Jan 08, 2016 at 09:39:11AM -0600, James Norris wrote: On 01/08/2016 09:30 AM, Jakub Jelinek wrote: On Fri, Jan 08, 2016 at 09:24:14AM -0600, James Norris wrote: This patch removes the constraint whereby the PTX emitted was only

[PATCH] Remove PTX link option

2016-01-08 Thread James Norris
Hi, This patch removes the constraint whereby the PTX emitted was only for sm_30 GPU's. With this removal, the PTX emitted will be targeted for the current context, i.e., attached GPU. Bootstrapped/regtested on x86_64-linux, ok for trunk? Thanks, Jim diff --git a/libgomp/plugin/plugin-nvptx.c

[gomp4] Fix use of declare'd vars by routine procedures.

2016-01-07 Thread James Norris
-01-07 James Norris <jnor...@codesourcery.com> + + * c-parser.c (c_finish_oacc_routine): Add new attribute. + * c-typeck.c (build_external_ref): Add usage check. + 2015-12-08 Thomas Schwinge <tho...@codesourcery.com> * c-parser.c (c_parser_oacc_clause_bind, c_parser_oacc_routine

[gomp4] Remove PTX link option

2016-01-07 Thread James Norris
=== --- libgomp/ChangeLog.gomp (revision 232139) +++ libgomp/ChangeLog.gomp (revision 232142) @@ -1,5 +1,10 @@ 2016-01-07 James Norris <jnor...@codesourcery.com> + Alexander Monakov <amona...@ispras.ru> + * plugin/plugin-nvptx.c (link_

Re: [PATCH] Remove use of 'struct map' from plugin (nvptx)

2016-01-05 Thread James Norris
Ping! Thanks, Jim On 12/16/2015 02:35 PM, James Norris wrote: Hi, The attached patch removes the use of the map structure (struct map) from the NVPTX plugin. Regtested on x86_64-pc-linux-gnu Ok for trunk? Thanks! Jim ChangeLog = 2015-12-XX James Norris <j

Re: [PATCH] Fix Fortran deviceptr clause.

2016-01-05 Thread James Norris
Ping! Thanks, Jim On 12/06/2015 02:10 PM, James Norris wrote: Hi, Attached is a patch that fixes some runtime issues dealing with the deviceptr clause in Fortran. There were some corner cases that were not being dealt with correctly, e.g., specifying the deviceptr clause and not using

Re: [PATCH] OpenACC documentation for libgomp

2016-01-05 Thread James Norris
-XX James Norris <jnor...@codesourcery.com> + Thomas Schwinge <tho...@codesourcery.com> + + * libgomp.texi (CUDA Streams Usage): New chapter. + 2016-01-04 Jakub Jelinek <ja...@redhat.com> * libgomp.texi: Bump @copying's copyright year. diff --git a/libgomp/libg

[PATCH] Remove use of 'struct map' from plugin (nvptx)

2015-12-16 Thread James Norris
Hi, The attached patch removes the use of the map structure (struct map) from the NVPTX plugin. Regtested on x86_64-pc-linux-gnu Ok for trunk? Thanks! Jim ChangeLog = 2015-12-XX James Norris <jnor...@codesourcery.com> libgomp/ * plugin/plugin-nvptx.c (stru

Re: [PATCH] Fix Fortran deviceptr clause.

2015-12-16 Thread James Norris
Hi, This is an update of my previous patch. Cesar (thanks!) pointed out some issues with the original patch that have now been addressed. Regtested on x86_64 OK for trunk? Thanks! Jim diff --git a/gcc/fortran/openmp.c b/gcc/fortran/openmp.c index 276f2f1..9350dc4 100644 ---

[PATCH] OpenACC documentation for libgomp

2015-12-16 Thread James Norris
Hi, Attached is the patch to add OpenACC documentation for libgomp. Ok to commit to trunk? Thanks! Jim Index: libgomp.texi === --- libgomp.texi (revision 231662) +++ libgomp.texi (working copy) @@ -94,10 +94,25 @@ @comment

[gomp4] Fix handling of kernel launch mappings.

2015-12-14 Thread James Norris
: libgomp/ChangeLog.gomp === --- libgomp/ChangeLog.gomp (revision 231614) +++ libgomp/ChangeLog.gomp (working copy) @@ -1,3 +1,10 @@ +2015-12-14 James Norris <jnor...@codesourcery.com> + + * plugin/plugin-nvptx.c (struct map): R

Re: [gomp4] Fix Fortran deviceptr

2015-12-09 Thread James Norris
Cesar, On 12/08/2015 11:10 AM, Cesar Philippidis wrote: On 12/08/2015 08:22 AM, James Norris wrote: 2. It appears that deviceptr code in GOACC_parallel_keyed is mostly identical to GOACC_data_start. Can you put that duplicate code into a function? That would be easier

Re: [gomp4] Fix Fortran deviceptr

2015-12-08 Thread James Norris
Cesar, On 12/07/2015 09:55 AM, Cesar Philippidis wrote: [snip snip] Two observations: 1. Why is deviceptr so special that gomp_map_vars can't handle it directly? Recall that the deviceptr clause in Fortran presents as two mappings: FORCE_DEVICEPTR and POINTER. The former has the

[gomp4] Add Fortran runtime test

2015-12-08 Thread James Norris
) @@ -1,3 +1,7 @@ +2015-12-08 James Norris <jnor...@codesourcery.com> + + * testsuite/libgomp.oacc-fortran/kernels-map-1.f90: Add new test. + 2015-12-08 Thomas Schwinge <tho...@codesourcery.com> James Norris <jnor...@codesourcery.com> Index: libgomp/testsuite/libgomp.oa

[gomp4] Fix Fortran deviceptr

2015-12-06 Thread James Norris
--git a/libgomp/ChangeLog.gomp b/libgomp/ChangeLog.gomp index a2f1c31..791aa4c 100644 --- a/libgomp/ChangeLog.gomp +++ b/libgomp/ChangeLog.gomp @@ -1,3 +1,10 @@ +2015-12-06 James Norris <jnor...@codesourcery.com> + + * oacc-parallel.c (GOACC_parallel_keyed, GOACC_data_start): + Handle F

[PATCH] Fix Fortran deviceptr clause.

2015-12-06 Thread James Norris
region. Also a new set of test cases has been added. Regtested on x86_64-pc-linux-gnu Ok for trunk? Thanks! Jim diff --git a/libgomp/ChangeLog b/libgomp/ChangeLog index cde0b5c..df26e7c 100644 --- a/libgomp/ChangeLog +++ b/libgomp/ChangeLog @@ -1,3 +1,10 @@ +2015-12-XX James Norris <j

Re: [PATCH] fortran/openmp.c -- Fix bootstrap

2015-11-22 Thread James Norris
Hi, Patch committed to trunk as obvious. Thanks to Dominique and Steve. Jim On 11/22/2015 12:59 PM, Steve Kargl wrote: I have no idea if this is actually correct, but it restores bootstrap. OK to commit? 2015-11-22 Steven G. Kargl * openmp.c

Re: OpenACC declare directive updates

2015-11-19 Thread James Norris
construct. On 11/06/2015 01:49 PM, Jakub Jelinek wrote: On Fri, Nov 06, 2015 at 01:45:09PM -0600, James Norris wrote: Okay, I'll fix this. After fixing, OK to commit? Thank you for taking the time for the review. Well, isn't this patch really dependent on the other one? Also, wonder about BLOCK

[PATCH] Fix unused variable.

2015-11-12 Thread James Norris
) +++ gcc/cp/ChangeLog (working copy) @@ -1,4 +1,8 @@ 2015-11-12 James Norris <jnor...@codesourcery.com> + + * parser.c (cp_parser_oacc_declare): Remove unused. + +2015-11-12 James Norris <jnor...@codesourcery.com> Joseph Myers <jos...@codesourcery.com&

Re: [OpenACC] declare directive

2015-11-12 Thread James Norris
Jakub On 11/12/2015 03:09 AM, Jakub Jelinek wrote: On Wed, Nov 11, 2015 at 07:07:58PM -0600, James Norris wrote: + oacc_declare_returns->remove (t); + + if (oacc_declare_returns->elements () == 0) + { +

Re: [OpenACC] declare directive

2015-11-11 Thread James Norris
, Jakub Jelinek wrote: On Mon, Nov 09, 2015 at 05:11:44PM -0600, James Norris wrote: >diff --git a/gcc/c-family/c-pragma.h b/gcc/c-family/c-pragma.h >index 953c4e3..c6a2981 100644 >--- a/gcc/c-family/c-pragma.h >+++ b/gcc/c-family/c-pragma.h >@@ -30,6 +30,7 @@ e

Re: [OpenACC] declare directive

2015-11-09 Thread James Norris
Jakub, On 11/09/2015 10:21 AM, Jakub Jelinek wrote: On Mon, Nov 09, 2015 at 10:01:32AM -0600, James Norris wrote: + if (lookup_attribute ("omp declare target", DECL_ATTRIBUTES (decl))) Here you only look up "omp declare target", not "omp declare target link"

Re: [OpenACC] declare directive

2015-11-09 Thread James Norris
Jakub, This is an update of the patch from: https://gcc.gnu.org/ml/gcc-patches/2015-11/msg00893.html. There was an unused variable in c/c-parser.c that was removed. I've included the ChangeLog as a convenience, but nothing was changed in the file. Thanks! Jim 2015-XX-XX James Norris <j

Re: [OpenACC] declare directive

2015-11-09 Thread James Norris
with determining which identifier to use with an attribute. Thanks! Jim 2015-XX-XX James Norris <jnor...@codesourcery.com> Joseph Myers <jos...@codesourcery.com> gcc/c-family/ * c-pragma.c (oacc_pragmas): Add entry for declare directive. * c-pr

Re: OpenACC declare directive updates

2015-11-08 Thread James Norris
: On Fri, Nov 06, 2015 at 01:45:09PM -0600, James Norris wrote: Also, wonder about BLOCK stmt in Fortran, that can give you variables that don't live through the whole function, but only a portion of it even in Fortran. OK to commit to trunk? Thanks! Jim 2015-XX-XX James Norris <j

Re: [OpenACC] declare directive

2015-11-08 Thread James Norris
trunk. I need some guidance from you whether I can leave the code as is and resolve the issue at stage3 time, or remove the code and the associated function device_resident_() and address the issue at stage 3. OK to commit to trunk? Thanks! Jim 2015-XX-XX James Norris <jnor...@codesourcery.com

Re: OpenACC declare directive updates

2015-11-08 Thread James Norris
give you variables that don't live through the whole function, but only a portion of it even in Fortran." OK to commit to trunk? Thanks! Jim 2015-XX-XX James Norris <jnor...@codesourcery.com> Joseph Myers <jos...@codesourcery.com> gcc/c-family

Re: [OpenACC] declare directive

2015-11-06 Thread James Norris
ready for you when you walk in on your Monday. Thank you, Jim On 11/04/2015 10:49 AM, Thomas Schwinge wrote: Hi Jim! On Tue, 3 Nov 2015 10:31:32 -0600, James Norris <jnor...@codesourcery.com> wrote: On 10/27/2015 03:18 PM, James Norris wrote: This patch adds the processing of O

Re: [OpenACC] declare directive

2015-11-06 Thread James Norris
On 11/06/2015 10:08 AM, James Norris wrote: Thomas, I've added the issues that you pointed out. Attached is the updated patch and ChangeLog. Thanks for taking the time for your review! Errr, make that 'addressed the issues that you pointed out." Opps, Jim

Re: [OpenACC] declare directive

2015-11-06 Thread James Norris
Jakub, Ping. Do you need more information before you can review this patch? Thanks! Jim On 10/27/2015 03:18 PM, James Norris wrote: Hi! This patch adds the processing of OpenACC declare directive in C and C++. (Note: Support in Fortran is already in trunk.) Commentary

Re: OpenACC declare directive updates

2015-11-06 Thread James Norris
Jakub, On 11/06/2015 01:49 PM, Jakub Jelinek wrote: On Fri, Nov 06, 2015 at 01:45:09PM -0600, James Norris wrote: Okay, I'll fix this. After fixing, OK to commit? Thank you for taking the time for the review. Well, isn't this patch really dependent on the other one? Yes. Should I combine

Re: OpenACC declare directive updates

2015-11-06 Thread James Norris
Jakub, On 11/06/2015 01:31 PM, Jakub Jelinek wrote: On Wed, Nov 04, 2015 at 06:32:00AM -0600, James Norris wrote: +/* Node in the linked list used for storing !$oacc declare constructs. */ + +typedef struct gfc_oacc_declare +{ + struct gfc_oacc_declare *next; + bool module_var

Re: [OpenACC] declare directive

2015-11-06 Thread James Norris
Jakub, On 11/06/2015 01:03 PM, Jakub Jelinek wrote: On Fri, Nov 06, 2015 at 10:08:26AM -0600, James Norris wrote: 2015-10-27 James Norris <jnor...@codesourcery.com> Joseph Myers <jos...@codesourcery.com> gcc/ * c-family/c-pragma.c (oacc_pragmas

Re: [OpenACC] declare directive

2015-11-06 Thread James Norris
Jakub, On 11/06/2015 01:22 PM, Jakub Jelinek wrote: On Fri, Nov 06, 2015 at 08:03:52PM +0100, Jakub Jelinek wrote: What exactly do you want to achieve? Why do you record it in gimplify_omp_ctx, but then only look at it in gimplify_body? The way you abuse gimplify_omp_ctx for that is just too

Re: [OpenACC] declare directive

2015-11-06 Thread James Norris
On 11/06/2015 02:28 PM, Jakub Jelinek wrote: On Fri, Nov 06, 2015 at 02:18:11PM -0600, James Norris wrote: On 11/06/2015 01:22 PM, Jakub Jelinek wrote: On Fri, Nov 06, 2015 at 08:03:52PM +0100, Jakub Jelinek wrote: What exactly do you want to achieve? Why do you record it in gimplify_omp_ctx

Re: OpenACC declare directive updates

2015-11-06 Thread James Norris
Jakub, Ping Do you need more information before you can review this patch? Thanks! Jim On 11/04/2015 06:32 AM, James Norris wrote: This patch updates the processing of OpenACC declare directive for Fortran in the following areas: 1) module support 2

OpenACC declare directive updates

2015-11-04 Thread James Norris
compile and runtime tests have been added. Also some have been modified. 2015-10-29 James Norris <jnor...@codesourcery.com> Cesar Philippidis <ce...@codesourcery.com> gcc/fortran/ * dump-parse-tree.c (show_namespace): Reimplement.

Re: [OpenACC] declare directive

2015-11-04 Thread James Norris
Hi Thomas, On 11/04/2015 10:49 AM, Thomas Schwinge wrote: Hi Jim! On Tue, 3 Nov 2015 10:31:32 -0600, James Norris <jnor...@codesourcery.com> wrote: On 10/27/2015 03:18 PM, James Norris wrote: This patch adds the processing of OpenACC declare directive in C and C++.

Re: [OpenACC] declare directive

2015-11-03 Thread James Norris
On 10/27/2015 03:18 PM, James Norris wrote: Hi! This patch adds the processing of OpenACC declare directive in C and C++. (Note: Support in Fortran is already in trunk.) Commentary on the changes is included as an attachment (NOTES). All of the code is in the gomp-4_0

OpenACC declare directive updates

2015-11-02 Thread James Norris
This patch updates the processing of OpenACC declare directive for Fortran in the following areas: 1) module support 2) device_resident and link clauses 3) clause checking 4) directive generation Commentary on the changes is included as an attachment

Re: [OpenACC] declare directive

2015-10-28 Thread James Norris
Cesar, On 10/28/2015 11:32 AM, Cesar Philippidis wrote: On 10/27/2015 01:18 PM, James Norris wrote: > This patch adds the processing of OpenACC declare directive in C > and C++. (Note: Support in Fortran is already in trunk.) > Commentary on the changes is

[OpenACC] declare directive

2015-10-27 Thread James Norris
so these tests will appear once the support has been committed.) 2015-10-27 James Norris <jnor...@codesourcery.com> gcc/ * builtin-types.def (BT_FN_VOID_PTR_INT_UINT): New type. * c-family/c-common.c (c_common_attribute_table): New oacc_declare. * c

Re: [Bulk] [OpenACC 0/7] host_data construct

2015-10-23 Thread James Norris
anks! Jim 2015-10-23 Julian Brown <jul...@codesourcery.com> James Norris <jnor...@codesourcery.com> gcc/c-family/ * c-pragma.c (oacc_pragmas): Add host_data pragma definition. * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC

[OpenACC 0/7] host_data construct

2015-10-22 Thread James Norris
Hi! This patch series adds the handling of OpenACC host_data construct in the C and C++ front-ends, gimple, and supporting functions in libgomp. Commentary on the changes is included in each individual patch. All of the code is in the gomp-4_0-branch. Regtested on

[OpenACC 5/7] host_data construct (gcc tests)

2015-10-22 Thread James Norris
gcc/testsuite/c-c++-common/goacc/host_data-1.c b/gcc/testsuite/c-c++-common/goacc/host_data-1.c gcc/testsuite/c-c++-common/goacc/host_data-2.c b/gcc/testsuite/c-c++-common/goacc/host_data-2.c gcc/testsuite/c-c++-common/goacc/host_data-3.c

[OpenACC 6/7] host_data construct

2015-10-22 Thread James Norris
libgomp/libgomp.map b/libgomp/libgomp.map - Add new symbol GOACC_deviceptr. libgomp/oacc-mem.c b/libgomp/oacc-mem.c - Add new function GOACC_deviceptr() to handle pointer lookup for host_data regions. diff --git a/libgomp/libgomp.map b/libgomp/libgomp.map index

[OpenACC 4/7] host_data construct (middle end)

2015-10-22 Thread James Norris
gcc/gimplify.c b/gcc/gimplify.c - Add new enum for use_device clause handling to gimplify_omp_var_data. - Add new enum for host_data regions to omp_region_type. - Move handling of use_device clause in gimplify_scan_omp_clauses(). - Add new functions

[OpenACC 1/7] host_data construct (C/C++ common)

2015-10-22 Thread James Norris
gcc/c-family/c-pragma.c b/gcc/c-family/c-pragma.c - Add host_data pragma definition to list in oacc_pragma[]. gcc/c-family/c-pragma.h b/gcc/c-family/c-pragma.h - Add host_data pragma enum to list in pragma_kind[]. - Add use_device clause enum to list in

[OpenACC 3/7] host_data construct (C front-end)

2015-10-22 Thread James Norris
gcc/cp/cp-tree.h b/gcc/cp/cp-tree.h - Add definition for c_finish_oacc_host_data(). gcc/cp/parser.c b/gcc/cp/parser.c - Add handling of use_device clause in cp_parser_omp_clause_name(). - Add handling of use_device clause in cp_parser_oacc_all_clauses().

[OpenACC 2/7] host_data construct (C FE)

2015-10-22 Thread James Norris
gcc/c/c-parser.c b/gcc/c/c-parser.c - Add handling of use_device clause in c_parser_omp_clause_name(). - Add new function c_parser_oacc_clause_use_device() to handle use_device clause with host_data. - Add handling of use_device clause in

[OpenACC 7/7] host_data construct (runtime tests)

2015-10-22 Thread James Norris
libgomp/testsuite/libgomp.oacc-c-c++-common/host_data-1.c b/libgomp/testsuite/libgomp.oacc-c-c++-common/host_data-1.c libgomp/testsuite/libgomp.oacc-c-c++-common/host_data-2.c b/libgomp/testsuite/libgomp.oacc-c-c++-common/host_data-2.c - New runtime tests for host_data. diff

Re: [OpenACC 0/7] host_data construct

2015-10-22 Thread James Norris
To all, On 10/22/2015 03:36 PM, Joseph Myers wrote: I think this patch is small enough, and the pieces insufficiently self-contained, that splitting it up rather than posting as one patch just makes it harder to understand. My strong preference is that the same patch that introduces a feature

[PATCH] Fix libgomp OpenACC test

2015-10-12 Thread James Norris
Hi, The attached patch fixes a test where the for-loop iterator was not initialized. Committed to trunk as obvious. Jim diff --git a/libgomp/testsuite/libgomp.oacc-c-c++-common/vector-loop.c b/libgomp/testsuite/libgomp.oacc-c-c++-common/vector-loop.c index cc915a9..8a51ee3 100644 ---

[gomp4] Backport from trunk

2015-10-12 Thread James Norris
Hi, The attached patch was backported from trunk. commit 140722d9d2d574574c982f4616a80bb0ef766276 Author: jnorris Date: Mon Oct 12 20:22:30 2015 + * testsuite/libgomp.oacc-c-c++-common/vector-loop.c: Fix loop initializer.

Re: Add -foffload-abi support for PPC

2015-10-09 Thread James Norris
David, On 10/08/2015 11:53 AM, David Edelsohn wrote: On Thu, Oct 8, 2015 at 12:19 PM, James Norris <jnor...@codesourcery.com> wrote: I've revised the patch from the review comments (thank you) and is attached. Regtested on x86_64 and powerpcle64. OK for trunk? What is the goal?

[gomp4] Revert patch

2015-10-09 Thread James Norris
Hi, The attached patch reverts a previously attached patch. 2015-10-06 James Norris <jnor...@codesourcery.com> * common.opt (OFFLOAD_ABI_PPC64): New enum. * config/nvptx/mkoffload.c (compile_native): Handle new enum. (main): Handle new option. *

[gomp4] Backport from trunk

2015-10-09 Thread James Norris
Hi, The attached patch was backported from trunk. commit 13d478244d380d1564eefc204201b7f681218ce3 Author: jnorris Date: Fri Oct 9 12:35:58 2015 + * config/rs6000/rs6000.c (rs6000_offload_options): New.

Re: Add -foffload-abi support for PPC

2015-10-08 Thread James Norris
Hi! On 10/07/2015 08:51 AM, David Edelsohn wrote: On Wed, Oct 7, 2015 at 4:02 AM, Thomas Schwinge wrote: From a quick look at the *_TYPE_SIZE definitions in gcc/config/rs6000/rs6000.h as well as , "3-1

Re: [PATCH] Remove restriction for remote testing

2015-10-07 Thread James Norris
Hi, On 10/05/2015 01:56 PM, Mike Stump wrote: I don't think this is appropriate. The design is for remote host testing to have the compete shape of an installed compiler as I recall. When it does, it then is indistinguishable from an installed compiler, and when it is installed, then no

[gomp4] Remove restriction for remote testing

2015-10-07 Thread James Norris
Hi, The attached patch is a backport from trunk. commit 3dabf8ddc9b4f0da3277991d20525d062e5b5138 Author: jnorris Date: Wed Oct 7 17:09:46 2015 + * testsuite/lib/atomic-dg.exp (atomic_link_flags): Move flag setting to

[gomp4] Add -foffload-abi support for PPC

2015-10-06 Thread James Norris
/ChangeLog.gomp +++ b/gcc/ChangeLog.gomp @@ -1,3 +1,11 @@ +2015-10-06 James Norris <jnor...@codesourcery.com> + + * common.opt (OFFLOAD_ABI_PPC64): New enum. + * config/nvptx/mkoffload.c (compile_native): Handle new enum. + (main): Handle new option. + * config/rs6000/rs6000.c (rs6000_offload_options): Ne

Re: [PATCH] Remove restriction for remote testing

2015-10-05 Thread James Norris
Ping. On 09/28/2015 07:35 AM, James Norris wrote: Hi, The attached patch fixes a problem when doing remote testing. Specifically, testing of the atomic tests found in gcc/atomic. The code in atomic_init precludes the setting of the variable 'link_flags' when doing remote testing

Re: [gomp4] Remove erroneous test and unreachable situation.

2015-09-29 Thread James Norris
) +++ libgomp/ChangeLog.gomp (working copy) @@ -1,3 +1,7 @@ +2015-09-29 James Norris <jnor...@codesourcery.com> + + * testsuite/libgomp.oacc-fortran/routine-9.f90: New test. + 2015-09-29 Nathan Sidwell <nat...@codesourcery.com> * oacc-init.c (acc_on_device): Compile with optimization. In

[gomp4] Remove erroneous test and unreachable situation.

2015-09-28 Thread James Norris
Hi, The attached patch removes an erroneous attribute test and an unreachable situation. Both showed up when dealing with the routine directive and the name option where the name was the identical to the name of the function / subroutine. Committed after regtest on x86_64 and powerpc64le.

[PATCH] Remove restriction for remote testing

2015-09-28 Thread James Norris
Hi, The attached patch fixes a problem when doing remote testing. Specifically, testing of the atomic tests found in gcc/atomic. The code in atomic_init precludes the setting of the variable 'link_flags' when doing remote testing. The conditional test can be safely removed as get_multilibs will

[gomp4] Fix handling of declare'd variable.

2015-09-14 Thread James Norris
Hi, The attached patch fixes an issue where a declare'd variable, with the link clause, wasn't marked as offloadable. Committed after regtesting on x86_64. Thanks! Jim Index: libgomp/testsuite/libgomp.oacc-c-c++-common/declare-4.c

[gomp4] Update fortran tests.

2015-09-11 Thread James Norris
Hi! Attached is a patch to update two (2) tests that were failing because the test cases were incorrect. Committed after regtesting on x86_64 and powerpc64le. Thanks! Jim Index: lib-12.f90 === --- lib-12.f90 (revision 227667) +++

[gomp4] Override default target hook

2015-09-11 Thread James Norris
Hi! The attached patch overrides the hook's default action for anchored address usage. Committed after regtest on x86_64 and powerpc64le Thanks! Jim Index: nvptx.c === --- nvptx.c (revision 227683) +++ nvptx.c (working copy) @@

[gomp4] declare directive

2015-08-12 Thread James Norris
Hi, The attached patch is a revision of the functionality required to handle the declare directive. The motivation for the change was that the original code was deemed to fragile and difficult to maintain. The new code is now smaller, in terms of line count, and hopefully, easier to understand.

[gomp4] finish_oacc_declare fix

2015-07-31 Thread James Norris
Hi, The attached patch adds a constraint to prevent finish_oacc_declare from being passed thru multiple times when dealing with a template and and instance of a template. Also cleaned up the interface to finish_oacc_declare. Committed to gomp-4_0-branch. Jim diff --git a/gcc/cp/decl.c

Re: [gomp4] Additional tests for routine directive

2015-07-27 Thread James Norris
Thomas, The attached patch adds XFAILs so as to quiet the errors until such time as the development is complete. Committed to gomp-4_0-branch. Thank you, thank you Jim On 07/27/2015 08:36 AM, Thomas Schwinge wrote: Hi! On Fri, 24 Jul 2015 15:43:36 -0500, James Norris jnor

[gomp4] Additional tests for routine directive

2015-07-24 Thread James Norris
Hi, The attached patch adds additional test for the routine directive for C/C++/Fortran. Committed to gomp-4_0-branch. Jim diff --git a/libgomp/testsuite/libgomp.oacc-c-c++-common/routine-3.c b/libgomp/testsuite/libgomp.oacc-c-c++-common/routine-3.c new file mode 100644 index 000..73ca528

[gomp4] Fix variable initialization

2015-07-24 Thread James Norris
Hi, The attached patch fixes a couple of missing variable initializations. Committed to gomp-4_0-branch. Jim diff --git a/libgomp/target.c b/libgomp/target.c index 16283ad..0470d3b 100644 --- a/libgomp/target.c +++ b/libgomp/target.c @@ -1130,7 +1130,7 @@ gomp_load_plugin_for_device (struct

[gomp4] Fix acc_shutdown issue.

2015-07-21 Thread James Norris
Hi, The attached patch fixes an issue that showed up when running the C/C++ version of asyncwait-1 within the libgomp testsuite. The issue arose because the entries added for the address mapping tables were not complete. Now that they are, a special function is no longer needed to remove the

[gomp4] Additional tests for kernels directive.

2015-07-21 Thread James Norris
Hi, The attached file contains additional tests for the if, async, and wait clauses associated with the kernels directive. Jim diff --git a/libgomp/testsuite/libgomp.oacc-c-c++-common/asyncwait-1.c b/libgomp/testsuite/libgomp.oacc-c-c++-common/asyncwait-1.c index 22cef6d..d478ce2 100644 ---

Re: [gomp4.1] Handle new form of #pragma omp declare target

2015-07-17 Thread James Norris
Jakub, On 07/17/2015 08:05 AM, Jakub Jelinek wrote: Hi! ... I believe OpenACC has something similar, but no idea if it is already implemented. Yes, it is implemented in gomp-4_0-branch. While the purpose for 'omp declare target' and 'acc declare' are similar, the data movement, via the

[gomp4] Additional tests

2015-07-15 Thread James Norris
Hi, The attached patch add tests for combined directives for, i.e., the parallel + loop directive and the kernel + loop directive for C/C++/Fortran. Tests also added for the private, num_gangs, num_workers, and vector_length clauses with the parallel directive in Fortran. Jim diff --git

[gomp4] New test loop independent clause

2015-07-14 Thread James Norris
Hi, The attached adds testing for the independent clause with the loop directive in Fortran. Committed to gomp-4_0-branch. Jim diff --git a/libgomp/testsuite/libgomp.oacc-fortran/kernels-independent.f90 b/libgomp/testsuite/libgomp.oacc-fortran/kernels-independent.f90 new file mode 100644 index

[gomp4] Add additional test for declare directive

2015-07-13 Thread James Norris
Hi, The attached patch adds a test for the copyout clause with the declare directive. The testing of this clause was overlooked. Committed to gomp-4_0-branch. Jim diff --git a/libgomp/testsuite/libgomp.oacc-c-c++-common/declare-1.c b/libgomp/testsuite/libgomp.oacc-c-c++-common/declare-1.c

Re: [gomp4] Handle deviceptr from an outer directive

2015-07-10 Thread James Norris
Hi Thomas! On 07/09/2015 03:51 AM, Thomas Schwinge wrote: Hi Jim! On Tue, 7 Jul 2015 10:19:39 -0500, James Norris jnor...@codesourcery.com wrote: This patch fixes an issue where the deviceptr clause in an outer directive was being ignored during implicit variable definition on a nested

Re: [gomp4] Handle Fortran deviceptr clause.

2015-07-10 Thread James Norris
Hi Thomas, On 07/09/2015 03:29 AM, Thomas Schwinge wrote: Hi Jim! On Wed, 8 Jul 2015 13:00:16 -0500, James Norris jnor...@codesourcery.com wrote: This patch adds handling of the deviceptr clause when used within a Fortran program. Please motivate such non-obvious code changes by a test

  1   2   >