public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Mikael Morin <mikael.morin@sfr.fr>
To: Alessandro Fanfarillo <fanfarillo.gcc@gmail.com>,
	gcc-patches	<gcc-patches@gcc.gnu.org>,
	gfortran <fortran@gcc.gnu.org>
Subject: Re: [Fortran, Patch] Passing function pointer to co_reduce
Date: Wed, 15 Jul 2015 13:13:00 -0000	[thread overview]
Message-ID: <55A6590C.4090700@sfr.fr> (raw)
In-Reply-To: <CAHqFgjVcUC0C=OtK73HFq7sif_18YWO+eLpccJFf4wC+jZZk5w@mail.gmail.com>

Hello,

Le 13/07/2015 17:31, Alessandro Fanfarillo a écrit :
> Dear all,
> 
> during the implementation of co_reduce in OpenCoarrays I noticed that
> GFortran passes a pointer to function instead of the function name to
> co_reduce.
> 
More exactly there are two address operators ('&') in a row (the dumping
removes one of them).

> Currently the compiler produces the following call:
> 
> _gfortran_caf_co_reduce (&desc.0, &simple_reduction, 0, 0, 0B, 0B, 0, 0);
> 
> where simple_reduction is the pure function that has to be used by co_reduce.
> 
> The attached patch seems to fix the issue, any comments?
> 
The patch itself looks good to me.
A ChangeLog entry should be provided with it.
The test is missing the usual dejagnu pattern matching directives to
check the generated code.
Do you have commit rights?

Mikael

  reply	other threads:[~2015-07-15 12:59 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-13 15:31 Alessandro Fanfarillo
2015-07-15 13:13 ` Mikael Morin [this message]
2015-07-16 14:58   ` Damian Rouson
2015-07-17  9:28     ` Mikael Morin
2015-07-17 13:54       ` Mikael Morin
2015-07-17 14:42         ` Damian Rouson
2015-07-17 14:43         ` Alessandro Fanfarillo
2015-07-17 18:47         ` Steve Kargl
2015-07-17 19:47           ` Mikael Morin
2015-07-17 20:47             ` Mikael Morin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=55A6590C.4090700@sfr.fr \
    --to=mikael.morin@sfr.fr \
    --cc=fanfarillo.gcc@gmail.com \
    --cc=fortran@gcc.gnu.org \
    --cc=gcc-patches@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).