public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH v3 0/5] fortran: Ignore unused arguments for scalarisation [PR97896]
@ 2021-11-07 16:16 Mikael Morin
  2021-11-07 16:16 ` [PATCH v3 1/5] fortran: Tiny sort_actual internal refactoring Mikael Morin
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: Mikael Morin @ 2021-11-07 16:16 UTC (permalink / raw)
  To: fortran, gcc-patches


Hello,

This is the third submit of this patch series.
After submitting the v2 [2] for master, and a somewhat different variant for
backport [3], I thought it was defeating the purpose of the backporting
process.  So I have decided to rebase the master patches on the backport
patches, so that the backport patchs can get some testing on master first.

The problematic case is intrinsic procedures where an argument is actually
not used in the code generated (KIND argument of INDEX in the testcase),
which confuses the scalariser.

Thomas König comitted a change to workaround the problem, but it regressed
in PR97896.  These patches put the workaround where I think it is more
appropriate, namely at the beginning of the scalarisation procedure.
That’s what is done by the series [3] initially intended for backport only,
and now for master too.  This series is a followup to them.

What are left in this series are a couple of refactoring for the master
branch only.  They aim at being able to identify the KIND argument of the INDEX
intrinsic by its name, rather than counting the right number of next->next->next
indirections starting with the first argument.  It may seem overkill for just
this use case, but I think it’s worth having that facility in the long term.

Regression-tested on x86_64-linux-gnu.  Ok for master? 


Changes from v2 [2]:

  Rebase on the backport variant of the series.

Changes from v1 [1]:

  Use C structs and enums instead of C++ classes.


[1] https://gcc.gnu.org/pipermail/fortran/2021-August/056303.html
[2] https://gcc.gnu.org/pipermail/fortran/2021-August/056317.html
[3] https://gcc.gnu.org/pipermail/fortran/2021-August/056329.html


Mikael Morin (5):
  fortran: Tiny sort_actual internal refactoring
  fortran: Reverse actual vs dummy argument mapping
  fortran: simplify elemental arguments walking
  fortran: Delete redundant missing_arg_type field
  fortran: Identify arguments by their names

 gcc/fortran/gfortran.h        | 41 +++++++++++++++----
 gcc/fortran/interface.c       | 77 +++++++++++++++++++++++++++++++----
 gcc/fortran/intrinsic.c       | 53 ++++++++++++++++--------
 gcc/fortran/trans-array.c     | 35 +++++-----------
 gcc/fortran/trans-array.h     |  2 +-
 gcc/fortran/trans-expr.c      |  9 +++-
 gcc/fortran/trans-intrinsic.c |  2 +-
 gcc/fortran/trans-stmt.c      | 22 ----------
 gcc/fortran/trans.h           |  4 +-
 9 files changed, 161 insertions(+), 84 deletions(-)

-- 
2.33.0


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2021-11-11 18:32 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-07 16:16 [PATCH v3 0/5] fortran: Ignore unused arguments for scalarisation [PR97896] Mikael Morin
2021-11-07 16:16 ` [PATCH v3 1/5] fortran: Tiny sort_actual internal refactoring Mikael Morin
2021-11-07 16:16 ` [PATCH v3 2/5] fortran: Reverse actual vs dummy argument mapping Mikael Morin
2021-11-07 16:16 ` [PATCH v3 3/5] fortran: simplify elemental arguments walking Mikael Morin
2021-11-07 16:16 ` [PATCH v3 4/5] fortran: Delete redundant missing_arg_type field Mikael Morin
2021-11-07 16:16 ` [PATCH v3 5/5] fortran: Identify arguments by their names Mikael Morin
2021-11-11 18:32 ` [PATCH v3 0/5] fortran: Ignore unused arguments for scalarisation [PR97896] Thomas Koenig

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).