public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jeff Law <law@redhat.com>
To: Mark Eggleston <mark.eggleston@codethink.co.uk>,
	Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>,
	sgk@troutmask.apl.washington.edu
Cc: fortran <fortran@gcc.gnu.org>, gcc-patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH PR Fortran/89286] Intrinsic sign and GNU Extension
Date: Tue, 23 Jul 2019 00:26:00 -0000	[thread overview]
Message-ID: <f55d3285-be9d-399a-a833-9dfd5b069faa@redhat.com> (raw)
In-Reply-To: <d686ac6b-806e-61a9-4fa4-6bd0c09bc435@codethink.co.uk>

On 7/11/19 6:16 AM, Mark Eggleston wrote:
> 
> On 10/07/2019 17:20, Bernhard Reutner-Fischer wrote:
>> On 10 July 2019 17:52:40 CEST, Steve Kargl
>> <sgk@troutmask.apl.washington.edu> wrote:
>>> On Wed, Jul 10, 2019 at 02:50:47PM +0100, Mark Eggleston wrote:
>>>> The attached patch treats the intrinsic SIGN in the same way as MOD
>>> and
>>>> DIM as it has the same arguments.
>>>>
>>>> Tested using make -j 8 check-fortran on x86_64
>>>>
>>>> Conditional compilation using #ifdef __GFC_REAL_16__ has been
>>> employed
>>>> where appropriate in the test cases so should be OK on platforms
>>> without
>>>> REAL(16).
>>>>
>>>> Change logs:
>>>>
>>>> gcc/fortran
>>>>
>>>>       Mark Eggleston  <mark.eggleston@codethink.com>
>>>>
>>>>       PR fortran/89286
>>>>           * check.c (gfc_check_sign): Deleted.
>> ChangeLog has to be in present tense per convention.
>>
>>>>       * intrinsic.c (add_functions): Call add_sym_2 with gfc_check_a_p
>>>>       instead of gfc_check_sign for "sign".
>>>>       * intrinsic.h: Remove declaration of gfc_check_sign.
>>>>       * iresolve.c (gfc_resolve_sign): Check for largest kind of the
>>> actual
>>>>       arguments and convert the smaller. Set return kind to be the
>>> largest.
>>>>       * simplify.c (gfc_simplify_sign): Use the largest kind of the
>>> actual
>>>>       arguments for return
>>>>       * intrinsic.texi: Add GNU extension notes for return value to
>>> SIGN.
>>>> gcc/testsuite
>>>>
>>>>       Mark Eggleston <mark.eggleston@codethink.com>
>>>>
>>>>       PR fortran/89240
>>>>       * gfortran.dg/sign_gnu_extension_1.f90: New test.
>>>>       * gfortran.dg/sign_gnu_extension_2.f90: New test.
>>>>       * gfortran.dg/pr78619.f90: Check for "must have" instead of
>>> "must be".
>>>> If OK please can someone commit as I do not have the privileges.
>>>>
>>> We really need to get you commit access to the tree.
>>>
>>> I also am not a fan of this type of change.  Having spent the
>>> last few days working on fixing BOZ to conform to F2018, I'm
>>> finding all sorts of undocumented "extensions".  Personally,
>>> I think gfortran should be moving towards the standard by
>>> deprecating of these types of extensions.
> 
> I agree.
> 
> I think that -std=gnu should not be the default, if gnu extensions are
> required you have to ask for them.
> 
>> At least make them explicit under explicit extension or at least
>> -legacy or whatever its called.
>>
>> thanks,
> 
> I agree, at the moment the GNU extension is silently supported by DIM
> and MOD
So if Mark was to put this behavior behind the -fdec or whatever the
appropriate switch is, could this move forward?

jeff

  reply	other threads:[~2019-07-23  0:25 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-10 14:04 Mark Eggleston
2019-07-10 16:14 ` Steve Kargl
2019-07-10 16:23   ` Bernhard Reutner-Fischer
2019-07-11 12:22     ` Mark Eggleston
2019-07-23  0:26       ` Jeff Law [this message]
2019-07-23  0:25   ` Jeff Law
2019-07-23  0:35 ` Jeff Law

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=f55d3285-be9d-399a-a833-9dfd5b069faa@redhat.com \
    --to=law@redhat.com \
    --cc=fortran@gcc.gnu.org \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=mark.eggleston@codethink.co.uk \
    --cc=rep.dot.nop@gmail.com \
    --cc=sgk@troutmask.apl.washington.edu \
    /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).