Re: PR fortran/39627 [meta-bug] Fortran 2008 support

2023-10-13 Thread Paul Richard Thomas
://gcc.gnu.org/wiki/Fortran2008Status and https://gcc.gnu.org/wiki/Fortran2018Status. I will update these pages once I am entirely sure of the state of each. Cheers Paul On Fri, 13 Oct 2023 at 07:32, Richard Biener wrote: > On Thu, Oct 12, 2023 at 6:54 PM Paul Richard Thomas > wrote: >

Re: [PATCH] Fortran: diagnostics of MODULE PROCEDURE declaration conflicts [PR104649]

2023-10-27 Thread Paul Richard Thomas
Hi Harald, That's good for mainline. Thanks for the patch Paul On Thu, 26 Oct 2023 at 21:43, Harald Anlauf wrote: > Dear all, > > the attached patch improves the diagnostics of MODULE PROCEDURE declaration > conflicts, when one of the declarations is an alternate return. We used to > ICE

[Patch, fortran] PR98498 - Interp request: defined operators and unlimited polymorphic

2023-11-01 Thread Paul Richard Thomas
The interpretation request came in a long time ago but I only just got around to implementing it. The updated text from the standard is in the comment. Now I am writing this, I think that I should perhaps use switch(op)/case rather than using if/else if and depending on the order of the

Re: [Patch, fortran] PR98498 - Interp request: defined operators and unlimited polymorphic

2023-11-02 Thread Paul Richard Thomas
* gfortran.dg/interface_50.f90: New test. On Wed, 1 Nov 2023 at 20:12, Harald Anlauf wrote: > Hi Paul, > > Am 01.11.23 um 19:02 schrieb Paul Richard Thomas: > > The interpretation request came in a long time ago but I only just got > > around to implementing it. > > > > T

[Patch, fortran] PR112316 - [13 Regression] Fix for PR87477 rejects valid code with a bogus error...

2023-11-03 Thread Paul Richard Thomas
Hi All, I have pushed as 'obvious' a fix for this regression to both 13-branch and mainline. The patch itself looks substantial but it consists entirely of the removal of a condition and repagination of the corresponding block. Please see below for part of my first comment on the PR for an

Re: [PATCH] Fortran: passing of allocatable/pointer arguments to OPTIONAL+VALUE [PR92887]

2023-11-03 Thread Paul Richard Thomas
Hi Harald, This looks good to me. OK for mainline. Thanks for the patch. Paul On Wed, 1 Nov 2023 at 22:10, Harald Anlauf wrote: > Dear all, > > I've dusted off and cleaned up a previous attempt to fix the handling > of allocatable or pointer actual arguments to OPTIONAL+VALUE dummies. > The

[Patch, fortran] PR104555 - ICE in gfc_compare_derived_types, at fortran/interface.cc:628 since r10-2912-g70570ec192745095

2023-10-29 Thread Paul Richard Thomas
Bizarrely, since the fix for pr101625, the testcase compiles and runs correctly with s/select type (y => x)/select type (y => (x))/ ! The fix is straightforward and appears to be one of those wrinkles arising from the use of associate variables as a selector. The fault is reasonable since the

[Patch, fortran] PR64120

2023-10-31 Thread Paul Richard Thomas
I found this 'obvious' fix, while going through PRs assigned to me. Regtests. OK for mainline? Cheers Paul Fortran: Allocatable automatic charlen must not be saved [PR64120]. 2023-10-31 Paul Thomas gcc/fortran PR fortran/64120 * trans-decl.cc (gfc_trans_deferred_vars): Detect automatic

[Patch, fortran] PR104625 ICE in fixup_array_ref, at fortran/resolve.cc:9275 since r10-2912-g70570ec192745095

2023-10-26 Thread Paul Richard Thomas
Hi All, The attached patch fixes the original problem, in which parentheses around the selector in select type constructs caused ICES. Stacked parentheses caused problems in trans-stmt.cc. Rather than tracking this down, the redundant parentheses were removed on resolution of the selector

Re: [PATCH] Fortran: Fix generate_error library function fnspec

2023-11-04 Thread Paul Richard Thomas
Hi Martin, This looks to be 'obvious' and is certainly OK for mainline. Backport if you wish. Thanks Paul On Fri, 3 Nov 2023 at 12:54, Martin Jambor wrote: > Hi, > > when developing an otherwise unrelated patch I've discovered that the > fnspec for the Fortran library function

Re: [Fortran, Patch, Coarray, PR 37336] Fix crash in finalizer when derived type coarray is already freed.

2023-10-01 Thread Paul Richard Thomas
Thanks for the fast review. > > > > Regards, > > Andre > > > > On Fri, 29 Sep 2023 13:38:57 +0100 > > Paul Richard Thomas wrote: > > > > > Hi Andre, > > > > > > Yes indeed - it's fine for trunk and, I w

[Patch, fortran] PR111674 - [13/14 regression] Failure to finalize an allocatable subobject of a non-finalizable type

2023-10-04 Thread Paul Richard Thomas
This was fixed as 'obvious' with an off-list OK, posted on the PR, from Harald. Applied to 13-branch and trunk then closed as fixed. Cheers Paul Fortran: Alloc comp of non-finalizable type not finalized [PR111674] 2023-10-04 Paul Thomas gcc/fortran PR fortran/37336 PR fortran/111674 *

Re: [Patch, fortran] PR67740 - Wrong association status of allocatable character pointer in derived types

2023-10-11 Thread Paul Richard Thomas
> > you'll likely want > > ! { dg-do run } > > (Note the space before the dg-command.) > > Cheers, > Harald > > On 10/11/23 21:06, Harald Anlauf wrote: > > Hi Paul, > > > > On 10/11/23 10:48, Paul Richard Thomas wrote: > >> Hi All, >

PR fortran/39627 [meta-bug] Fortran 2008 support

2023-10-12 Thread Paul Richard Thomas
I have posted the version 4 of Ian Chivers and Jane Sleightholme's F2008 compliance table as an attachment to PR39627. With Harald Anlauf's help it has been updated to correspond to gfortran 13.2. In the previous return for gfortran, a number of lines had not been filled out at all. This has now

[Patch, fortran] PR67740 - Wrong association status of allocatable character pointer in derived types

2023-10-11 Thread Paul Richard Thomas
Hi All, The title line of the PR should have been changed a long time since. As noted in comment 5, the original problem was fixed in 10.5. This patch fixes the problem described in comments 4 and 6, where the hidden string length component was not being set in pointer assignment of character

Re: {Patch, fortran] PR112834 - Class array function selector causes chain of syntax and other spurious errors

2023-12-17 Thread Paul Richard Thomas
> Hi Paul, > > On 12/6/23 17:09, Paul Richard Thomas wrote: > > Dear All, > > > > This patch was rescued from my ill-fated and long winded attempt to > provide > > a fix-up for function selector references, where the function is parsed > > after the procedure

{Patch, fortran] PR112834 - Class array function selector causes chain of syntax and other spurious errors

2023-12-06 Thread Paul Richard Thomas
Dear All, This patch was rescued from my ill-fated and long winded attempt to provide a fix-up for function selector references, where the function is parsed after the procedure containing the associate/select type construct (PRs 89645 and 99065). The fix-ups broke down completely once these

Re: [PATCH] Fortran: fix argument passing to CONTIGUOUS, TARGET dummy [PR97592]

2023-12-17 Thread Paul Richard Thomas
Hi Harald, It might be a simple patch but I have to confess it took a while for me to get my head around the difference between gfc_is_not_contiguous and !gfc_is_simply_contigous :-( Yes, this is OK for mainline and, after a short delay, for 13-branch. Thanks for the patch Paul On Sat, 16

Re: Fortran: Use non conflicting file extensions for intermediates [PR81615]

2024-01-02 Thread Paul Richard Thomas
Hi Harald, 'from' is slightly better but either will be understood. Cheers Paul Happy New Year to you all! On Mon, 1 Jan 2024 at 21:25, Harald Anlauf wrote: > Hi Thomas! > > Am 30.12.23 um 12:08 schrieb Thomas Koenig: > > Replying to myself... > > > > > >> I think this also desevers a

[Patch, fortran PR89645/99065 No IMPLICIT type error with: ASSOCIATE( X => function() )

2024-01-06 Thread Paul Richard Thomas
These PRs come about because of gfortran's single pass parsing. If the function in the title is parsed after the associate construct, then its type and rank are not known. The point at which this becomes a problem is when expressions within the associate block are parsed. primary.cc

Re: [PATCH] Fortran: fix TARGET attribute of associating entity in ASSOCIATE [PR112764]

2023-11-30 Thread Paul Richard Thomas
Hi Harald, The original testcase is accepted by the two other brands to which I have access. OK for mainline and, I would suggest, 13-branch. Thanks Paul On Wed, 29 Nov 2023 at 21:16, Harald Anlauf wrote: > Dear all, > > the attached simple patch fixes the handling of the TARGET >

Bug 85836 (F2018) - [meta-bug] Fortran 2018 support

2023-12-03 Thread Paul Richard Thomas
Dear All, I have attached a mostly completed version of the Chivers and Sleightholme F2018 compliance table to the above PR. For features 1.x to 6.x, I wrote explicit tests, which are also attached to the PR. Much of the rest, I was able to fill out by inspection of the gfortran source or the

Re: [PATCH] Fortran: allow RESTRICT qualifier also for optional arguments [PR100988]

2023-12-04 Thread Paul Richard Thomas
Hi Harald, The patch is OK for mainline. Thanks Paul On Mon, 4 Dec 2023 at 22:47, Harald Anlauf wrote: > Dear all, > > the attached patch picks up an observation by Tobias that we did > not specify the RESTRICT qualifier for optional arguments even > if that was allowed. In principle this

Re: [PATCH v2] Fortran: fix reallocation on assignment of polymorphic variables [PR110415]

2023-11-29 Thread Paul Richard Thomas
Hi Andrew, This is OK by me. I attach a slightly edited version of the patch itself in the hope that it will make the code a bit clearer. Thanks and welcome! Paul On Mon, 27 Nov 2023 at 17:35, Andrew Jenner wrote: > This is the second version of the patch - previous discussion at: >

[Patch, fortran] PR112459 - gfortran -w option causes derived-type finalization at creation time

2023-11-11 Thread Paul Richard Thomas
Hi All, Evidently -w causes gfc_option.allow_std to be set to default, which allows anything and everything to happen, including these f2003/8 finalizations. The fix is trivial. Regtests fine - OK for mainline and -13 branch? Paul Fortran: Prevent unwanted finalization with -w option

Re: [Patch, fortran PR89645/99065 No IMPLICIT type error with: ASSOCIATE( X => function() )

2024-03-03 Thread Paul Richard Thomas
/trans-stmt.cc:2383 > [...] > > I don't see anything wrong with it: NAG groks it, like Nvidia and Flang, > while Intel crashes at runtime. > > Can you have another brief look? > > Thanks, > Harald > > > On 1/6/24 18:26, Paul Richard Thomas wrote: > > These

Re: [PATCH] Fortran: error recovery while simplifying expressions [PR103707, PR106987]

2024-03-06 Thread Paul Richard Thomas
Hi Harald, This all looks good to me. OK for mainline and, according to intestinal fortitude on your part, earlier branches. Thanks Paul On Tue, 5 Mar 2024 at 21:24, Harald Anlauf wrote: > Dear all, > > error recovery on arithmetic errors during simplification has bugged > me for a long

Re: [PATCH] Fortran: handle procedure pointer component in DT array [PR110826]

2024-03-12 Thread Paul Richard Thomas
Hi Harald, This looks good to me. OK for mainline and, since it is so straightforward, for backporting. Thanks for the patch. Paul On Mon, 11 Mar 2024 at 21:20, Harald Anlauf wrote: > Dear all, > > the attached patch fixes an ICE-on-valid code when assigning > a procedure pointer that is a

Re: [Patch, fortran PR89645/99065 No IMPLICIT type error with: ASSOCIATE( X => function() )

2024-03-12 Thread Paul Richard Thomas
Hi All, This is the last posting of this patch before I push it. Harald is OK with it on the grounds that the inferred_type flag guards the whole lot, except for the chunks in trans-stmt.cc. In spite of Harald's off-list admonition not to try to fix everything at once, this version fixes most of

Re: [PATCH] Fortran: fix IS_CONTIGUOUS for polymorphic dummy arguments [PR114001]

2024-03-13 Thread Paul Richard Thomas
Hi Harald, This looks good to me. The testcase gives the same result with other brands. OK for mainline and for backporting. Thanks Paul On Tue, 12 Mar 2024 at 22:12, Harald Anlauf wrote: > Dear all, > > here's another small fix: IS_CONTIGUOUS did erroneously always > return .true. for

Re: [Patch, fortran PR89645/99065 No IMPLICIT type error with: ASSOCIATE( X => function() )

2024-03-12 Thread Paul Richard Thomas
s approach was very clever but has found it's limit with the associate construct. The sad thing is that this is the only blocker that I know of. Thanks Paul On Tue, 12 Mar 2024 at 21:07, Harald Anlauf wrote: > Hi Paul, > > On 3/12/24 15:54, Paul Richard Thomas wrote: > > Hi All,

Re: [PATCH v3 2/2] fortran: Fix specification expression error with dummy procedures [PR111781]

2024-03-19 Thread Paul Richard Thomas
Hi Mikael, This is very good. I am pleased to see global variables disappear and I like the new helper functions. As before, OK for mainline and, if you wish, 13-branch. Thanks Paul On Tue, 19 Mar 2024 at 15:49, Mikael Morin wrote: > This fixes a spurious invalid variable in specification

Re: [PATCH v3 0/2] fortran: Fix specification checks [PR111781]

2024-03-19 Thread Paul Richard Thomas
Hi Mikael, Sorry, I am replying to these in the order that they appear in my intray :-) OK for mainline and, if you wish, 13-branch. Thanks Paul On Tue, 19 Mar 2024 at 15:49, Mikael Morin wrote: > Hello, > > these patches correct diagnostics dealing with variables in specification >

Re: [PATCH v3 1/2] testsuite: Declare fortran array bound variables

2024-03-19 Thread Paul Richard Thomas
Hi Mikael, This looks completely "obvious" to me. OK for mainline and, I would suggest, 13-branch. Thanks Paul On Tue, 19 Mar 2024 at 15:49, Mikael Morin wrote: > This fixes invalid undeclared fortran array bound variables > in the testsuite. > > gcc/testsuite/ChangeLog: > > *

Re: gfortran wiki

2024-03-25 Thread Paul Richard Thomas
Hi Harald, Yes, that's a good idea. I'll take a look tomorrow morning to see what I think needs doing and then let's put heads together. Regards Paul On Sun, 24 Mar 2024 at 20:23, Harald Anlauf wrote: > Dear all, > > the gfortran wiki (https://gcc.gnu.org/wiki/GFortran) seems to have been >

[Patch, fortran] PR112407 - [13/14 Regression] Fix for PR37336 triggers an ICE in gfc_format_decoder while constructing a vtab

2024-03-30 Thread Paul Richard Thomas
Hi All, This bug emerged in a large code and involves possible recursion with a "hidden" module procedure; ie. where the symtree name starts with '@'. This throws the format decoder. As the last message in the PR shows, I have vacillated between silently passing on the possible recursion or

Re: gfortran wiki

2024-03-28 Thread Paul Richard Thomas
Hi Harald, I have made a start on this: I have updated the text around bug reports in the developers section, added the bugs fixed etc.. for 2022/23 and eliminated the links to the Doxygen documentation. The biggest part of the job will be to add "what's new" in 10-14 branches and F2003/8/18

[Patch, fortran] PR110987 and PR113885 - gimplifier ICEs and wrong results in finalization

2024-03-28 Thread Paul Richard Thomas
Hi All, The attached patch has two elements: (i) A fix for gimplifier ICEs with derived type having no components. The reporter himself suggested (thanks Kirill!): - if (derived && derived->attr.zero_comp) + if (derived && (derived->components == NULL)) As far as I can tell, this is the

[Patch, fortran] PR106999 [11/12/13/14 Regression] ICE tree check: expected record_type or union_type or qual_union_type, have function_type in gfc_class_data_get, at fortran/trans-expr.cc:233

2024-03-31 Thread Paul Richard Thomas
This regression has a relatively simple fix. The passing of a subroutine procedure pointer component to a dummy variable was being missed completely. The error has been added. Conversely, an error was generated for a procedure pointer variable but no use was being made of the interface, if one was

Re: [Patch, fortran] PR112407 - [13/14 Regression] Fix for PR37336 triggers an ICE in gfc_format_decoder while constructing a vtab

2024-03-31 Thread Paul Richard Thomas
Hi Harald, > > I had only a quick glance at your patch. I guess you unintentionally > forgot to remove those parts that you already committed for PR110987, > along with the finalize-testcases. > Guilty as charged. I guess I got out of the wrong side of the bed :-) > > I am still trying to find

[Patch, fortran] PR113956 - [13/14 Regression] ice in gfc_trans_pointer_assignment, at fortran/trans-expr.cc:10524

2024-04-09 Thread Paul Richard Thomas
Patch pushed after pre-approval by Harald on Bugzilla. Fortran: Fix ICE in gfc_trans_pointer_assignment [PR113956] 2024-04-09 Paul Thomas gcc/fortran PR fortran/113956 * trans-expr.cc (gfc_trans_pointer_assignment): Remove assert causing the ICE since it was

Re: [patch, libgfortran] PR114304 - [13/14 Regression] libgfortran I/O – bogus "Semicolon not allowed as separator with DECIMAL='point'"

2024-04-04 Thread Paul Richard Thomas
Hi Jerry, It looks good to me. Noting that this is not a regression, OK for mainline on condition that you keep a sharp eye out for any associated problems. Likewise with backporting to 13-branch. Thanks Paul On Thu, 4 Apr 2024 at 02:34, Jerry D wrote: > Hi all, > > The attached log entry

Re: [PATCH] Fortran: no size check passing NULL() without MOLD argument [PR55978]

2024-03-24 Thread Paul Richard Thomas
Hi Harald, This is completely fine - if you haven't committed, please do so. Thanks Paul On Fri, 22 Mar 2024 at 17:32, Harald Anlauf wrote: > Dear all, > > here's a simple and obvious patch for a rejects-valid case when > we pass a NULL() actual to an optional dummy for variants where >

[Patch, fortran] PR114535 - [13/14 regression] ICE with elemental finalizer

2024-04-08 Thread Paul Richard Thomas
Hi All, This one is blazingly 'obvious'. I haven't had the heart to investigate why somebody thought that it is a good idea to check if unreferenced symbols are finalizable because, I suspect, that 'somebody' was me. Worse, I tried a couple of other fixes before I hit on the 'obvious' one :-(

Re: [Patch, fortran] PR110987 and PR113885 - gimplifier ICEs and wrong results in finalization

2024-03-29 Thread Paul Richard Thomas
Hi Harald, Thanks for the thumbs-up. Committed as 3c793f0361bc66d2a6bf0b3e1fb3234fc511e2a6. I will backport to 13-branch in a couple of weeks. Best regards Paul On Thu, 28 Mar 2024 at 22:27, Harald Anlauf wrote: > ...snip... > yes, this looks good here. > > ...snip... The patch looks

[Patch, fortran] PR113363 - ICE on ASSOCIATE and unlimited polymorphic function

2024-04-10 Thread Paul Richard Thomas
Hi All, This patch corrects incorrect results from assignment of unlimited polymorphic function results both in assignment statements and allocation with source. The first chunk in trans-array.cc ensures that the array dtype is set to the source dtype. The second chunk ensures that the lhs _len

[Patch, fortran] PR114739 [14 Regression] ice in gfc_find_derived_types, at fortran/symbol.cc:2458

2024-04-17 Thread Paul Richard Thomas
This ICE was caused by my patch r14-9489-g3fd46d859cda10. However, the ICE hid a wrong error going back to at least 6.4.1 20180703. The patch fixes both and exposed incorrect error messages in existing tests in gfortran.dg. The fix for these was to add 'IMPLICIT NONE' in call cases so that there

[Patch, fortran] PR103471 - [11/12/13/14 Regression] ICE in gfc_typenode_for_spec, at fortran/trans-types.c:1114

2024-04-19 Thread Paul Richard Thomas
Hi All, This is a more or less obvious patch. The action is in resolve.cc. The chunk in symbol.cc is a tidy up of a diagnostic marker to distinguish where the 'no IMPLICIT type' error was coming from and the chunk in trans-decl.cc follows from discussion with Harald on the PR. Regtests fine. OK

Re: [Patch, fortran] PR103471 - [11/12/13/14 Regression] ICE in gfc_typenode_for_spec, at fortran/trans-types.c:1114

2024-04-20 Thread Paul Richard Thomas
Hi Harald, > > the patch is OK, but I had to manually fix it. I wonder how you managed > to produce: > Yes, I had to use --whitespace fix when I reapplied it a few minutes ago. > > diff --git a/gcc/testsuite/gfortran.dg/pr93484.f90 > I had followed comment 1 in the PR and wrongly named the

Re: [Patch, fortran] PR103471 - [11/12/13/14 Regression] ICE in gfc_typenode_for_spec, at fortran/trans-types.c:1114

2024-04-20 Thread Paul Richard Thomas
> > > Hi Harald, > Indeed, the gfc_fatal_error always wins. :-( > > This PR is marked as a regression. Depending on your progress, > it might be worth to consider fixing what you think is needed > to get rid of the regression marker and defer the improvement > of the diagnostics to a second

[Patch, fortran] PR89462 - [11/12/13/14 Regression] gfortran loops in code generation

2024-04-23 Thread Paul Richard Thomas
Hi All, Jakub pinpointed the source of this bug in comment 6 of the PR. The rest was 'obvious' :-) I plan to push the patch to mainline in the next 24 hours unless there are opinions to the contrary. Backporting is proposed to occur a couple of weeks later. Best regards Paul Fortran: Generate

Re: [Patch, fortran] PR89462 - [11/12/13/14 Regression] gfortran loops in code generation

2024-04-24 Thread Paul Richard Thomas
PS ignore the chunk in trans-array.cc. It is an attempt to fix PR93678 that literally did nothing. Paul On Wed, 24 Apr 2024 at 07:05, Paul Richard Thomas < paul.richard.tho...@gmail.com> wrote: > Hi, > > The linaro pre-commit error testing picked up errors for arm and aarch &

Re: [Patch, fortran] PR89462 - [11/12/13/14 Regression] gfortran loops in code generation

2024-04-24 Thread Paul Richard Thomas
more. Paul On Tue, 23 Apr 2024 at 16:25, Paul Richard Thomas < paul.richard.tho...@gmail.com> wrote: > Hi All, > > Jakub pinpointed the source of this bug in comment 6 of the PR. The rest > was 'obvious' :-) > > I plan to push the patch to mainline in the next 24 hours unl

[Patch, fortran] PR93678 - [11/12/13/14 Regression] ICE with TRANSFER and typebound procedures

2024-04-24 Thread Paul Richard Thomas
Hi there, This regression turned out to be low hanging fruit, although it has taken four years to reach it :-( The ChangeLog says it all. OK for mainline and backporting after a suitable delay? Paul Fortran: Fix ICE in gfc_trans_create_temp_array from bad type [PR93678] 2024-04-24 Paul

Re: [PATCH] Fortran: fix issues with class(*) assignment [PR114827]

2024-04-29 Thread Paul Richard Thomas
Hi Harald, This patch is verging on 'obvious', . once one sees it :-) Yes, it's good for mainline and all active branches, when available. Thanks Paul PS The fall-out pr114874 is so peculiar that I am dropping everything to find the source. On Mon, 29 Apr 2024 at 19:39, Harald Anlauf

[Patch, fortran] PR114859 - [14/15 Regression] Seeing new segmentation fault in same_type_as since r14-9752

2024-04-28 Thread Paul Richard Thomas
Hi All, Could this be looked at quickly? The timing of this regression is more than a little embarrassing on the eve of the 14.1 release. The testcase and the comment in gfc_trans_class_init_assign explain what this problem is all about and how the patch fixes it. OK for 15-branch and

Re: [Patch, fortran] PR84006 [11/12/13/14/15 Regression] ICE in storage_size() with CLASS entity

2024-05-09 Thread Paul Richard Thomas
40 40 4 5$ > >abcdefghij^@^@^@^@^@^@^@^@^@^@<$ > > So since the physical representation of chr_a is sufficient > to hold star_a (F2023:16.9.212), no reallocation with a wrong > calculated size should happen. (Intel and NAG get this right.) >

Re: [Patch, fortran] PR84006 [11/12/13/14/15 Regression] ICE in storage_size() with CLASS entity

2024-05-11 Thread Paul Richard Thomas
. A resubmission of the patch for PR113363 will follow since it depends on this one to fix all the memory problems. OK for mainline? Regards Paul On Thu, 9 May 2024 at 08:52, Paul Richard Thomas < paul.richard.tho...@gmail.com> wrote: > Hi Harald, > > The Linaro people caught that

Re: [Patch, fortran] PR113363 - ICE on ASSOCIATE and unlimited polymorphic function

2024-05-12 Thread Paul Richard Thomas
Hi Harald, Please find attached my resubmission for pr113363. The changes are as follows: (i) The chunk in gfc_conv_procedure_call is new. This was the source of one of the memory leaks; (ii) The incorporation of the _len field in trans_class_assignment was done for the pr84006 patch; (iii) The

Re: [PATCH] fortran: Assume there is no cyclic reference with submodule symbols [PR99798]

2024-05-12 Thread Paul Richard Thomas
Hi Mikael, That is an ingenious solution. Given the complexity, I think that the comments are well warranted. OK for master and, I would suggest, 14-branch after a few weeks. Thanks! Paul On Sun, 12 May 2024 at 14:16, Mikael Morin wrote: > Hello, > > Here is my final patch to fix the ICE of

[Patch, fortran] PR114874 - [14/15 Regression] ICE with select type, type is (character(*)), and substring

2024-05-15 Thread Paul Richard Thomas
Hi All, I have been around several circuits with a patch for this regression. I posted one in Bugzilla but rejected it because it was not direct enough. This one, however, is more to my liking and fixes another bug lurking in the shadows. The way in which select type has been implemented is a

Re: [Patch, fortran] PR114859 - [14/15 Regression] Seeing new segmentation fault in same_type_as since r14-9752

2024-04-29 Thread Paul Richard Thomas
: > Hello, > > Le 28/04/2024 à 23:37, Paul Richard Thomas a écrit : > > Hi All, > > > > Could this be looked at quickly? The timing of this regression is more > > than a little embarrassing on the eve of the 14.1 release. The testcase > > and the comment in g

Re: [PATCH] Fortran: fix issues with class(*) assignment [PR114827]

2024-05-05 Thread Paul Richard Thomas
Hi Harald, Please do commit, with or without the extra bit for the function result. As well as having to get back to pr113363, I have patches in a complete state for pr84006 and 98534. However they clash with yours. You arrived at the head of the queue first and so after you :-) Regards Paul

[Patch, fortran] PR84006 [11/12/13/14/15 Regression] ICE in storage_size() with CLASS entity

2024-05-08 Thread Paul Richard Thomas
This fix is straightforward and described by the ChangeLog. Jose Rui Faustino de Sousa posted the same fix for the ICE on the fortran list slightly more than three years ago. Thinking that he had commit rights, I deferred but, regrettably, the patch was never applied. The attached patch also fixes

Re: [Patch, fortran] PR103312 - [11/12/13/14/15 Regression] ICE in gfc_find_component since r9-1098-g3cf89a7b992d483e

2024-05-23 Thread Paul Richard Thomas
Hi Harald, You were absolutely right about returning 'false' :-) The patch is duly corrected. Committed to mainline and will be followed by backports in a few weeks. Regards Paul On Tue, 21 May 2024 at 19:58, Harald Anlauf wrote: > Hi Paul, > > Am 20.05.24 um 11:06 schrieb Pau

[Patch, fortran] PR103312 - [11/12/13/14/15 Regression] ICE in gfc_find_component since r9-1098-g3cf89a7b992d483e

2024-05-20 Thread Paul Richard Thomas
Hi All, I don't think that this PR is really a regression although the fact that it is marked as such brought it to my attention :-) The fix turned out to be remarkably simple. It was found after going down a silly number of rabbit holes, though! The chunk in dependency.cc is probably more

Re: [Patch, fortran V3] PR fortran/100683 - Array initialization refuses valid

2021-06-21 Thread Paul Richard Thomas via Fortran
Hi Jose and Tobias, I am glad that you produced the list of patches waiting for approval. I have been out of action following a house move and will likely not be doing any reviewing or contributing for another month or so. As soon as I am ready, I will make use of this list to check out what has

[Patch, fortran] PR84119 - Type parameter inquiry for PDT returns array instead of scalar

2021-05-05 Thread Paul Richard Thomas via Fortran
Ping! On Tue, 20 Apr 2021 at 12:51, Paul Richard Thomas < paul.richard.tho...@gmail.com> wrote: > Hi All, > > This is another PDT warm-up patch before tackling the real beast: PR82649. > > As the contributor wrote in the PR, "The F08 standard clearly > disting

[Patch, fortran] PRs 46691 and 99819: Assumed and explicit size class arrays

2021-05-06 Thread Paul Richard Thomas via Fortran
Hi All, Although I had undertaken to concentrate on PDTs, PR99819 so intrigued me that I became locked into it :-( After extensive, fruitless rummaging through decl.c and trans-decl.c, I realised that the problem was far simpler than it seemed and that it lay in class.c. After that PR was fixed,

Re: [Patch, fortran] PRs 46691 and 99819: Assumed and explicit size class arrays

2021-05-06 Thread Paul Richard Thomas via Fortran
PR fortran/46691 PR fortran/99819 * gfortran.dg/class_dummy_6.f90: New test. * gfortran.dg/class_dummy_7.f90: New test. On Thu, 6 May 2021 at 07:57, Paul Richard Thomas < paul.richard.tho...@gmail.com> wrote: > Hi All, > > Although I had undertaken to concentrate on PDTs, PR99819

Re: [PATCH] PR fortran/100551 - [11/12 Regression] Passing return value to class(*) dummy argument

2021-05-23 Thread Paul Richard Thomas via Fortran
Hi Harald, I meant to deal with this myself since I am the guilty party. However, the last two weeks have been taken up by a house move and so gfortran has been on the backburner. The patch looks good and seems to do the job - OK for master and 11-branch. Thanks a million for dealing with it!

Re: PING [PATCH] PR fortran/99839 - [9/10/11/12 Regression] ICE in inline_matmul_assign, at fortran/frontend-passes.c:4234

2021-06-04 Thread Paul Richard Thomas via Fortran
Hi Harald, Looks good to me - OK for as many branches as you have sufficient fortitude for. Regards Paul On Thu, 3 Jun 2021 at 21:22, Harald Anlauf via Fortran wrote: > *PING* > > > Gesendet: Donnerstag, 27. Mai 2021 um 22:20 Uhr > > Von: "Harald Anlauf" > > An: "fortran" , "gcc-patches" <

Re: [Patch, fortran] PR fortran/100120/100816/100818/100819/100821 problems raised by aggregate data types

2021-06-04 Thread Paul Richard Thomas via Fortran
Hi José, I can second Dominique's thanks. I applied it to my tree when you first posted, set the regtest in motion and have not been able to return to gfortran matters since. OK for master. I am especially happy that you have tackled this area and have rationalised it to a substantial degree.

Re: [Patch] PR fortran/100154 - [9/10/11/12 Regression] ICE in gfc_conv_procedure_call, at fortran/trans-expr.c:6131

2021-04-24 Thread Paul Richard Thomas via Fortran
Hi Harald, It looks good to me! Keep clear of 11-branch until release but OK for the others. Thanks Paul On Fri, 23 Apr 2021 at 00:18, Harald Anlauf via Fortran wrote: > Now with the correct patch attached ... > > Sorry for the confusion! > > --- > > Dear Fortranners, > > we need to check

Re: [Patch] PR fortran/100218 - target of pointer from evaluation of function-reference

2021-04-24 Thread Paul Richard Thomas via Fortran
Hi Harald, Another good one - OK for master but wait a while for 11-branch. I am a bit hesitant about 10-branch because this is not a regression. That said, this is harmless because it is permissive, so I will leave it to you to decide. Is there a test for an error with -std=f2003? If not, you

Re: [Patch, fortran] PR fortran/82376 - Duplicate function call using -fcheck=pointer

2021-04-25 Thread Paul Richard Thomas via Fortran
Hi José! The fix is fine. Note however that the testcase will pass even without the fix because you haven't included the ! { dg-options "-fcheck=pointer" }. In fact, I suggest that you use the version of the tescase that I have attached that does not run but counts the number of occurrences of

Re: [Patch] Fortran: Fix func decl mismatch [PR93660]

2021-03-23 Thread Paul Richard Thomas via Fortran
Hi Tobias, The patch looks fine to me. OK for 10- and 11-branches. I am not convinced that a delay is needed for the backport. Thanks Paul On Thu, 11 Mar 2021 at 18:19, Tobias Burnus wrote: > This fixes an ICE with OpenMP 'omp decare simd' but is a generic bug. > > Namely TREE_TYPE(fndecl)

Re: [Patch, fortran] 99307 - FAIL: gfortran.dg/class_assign_4.f90 execution test

2021-03-26 Thread Paul Richard Thomas via Fortran
Hi Dominique, What I meant was a test that would confirm the fix on all targets. BTW thanks for testing the patch! A Paul On Fri, 26 Mar 2021 at 17:29, wrote: > Hi Paul, > > I have your first patch in my working tree for some time. It works as > expected without breaking anything in my own

Re: [Patch, fortran] PR99602 - [11 regression] runtime error: pointer actual argument not associated

2021-03-29 Thread Paul Richard Thomas via Fortran
> Hence: > - Please include the attached testcases or some variants of them. > - Check that removing !UNLIMITED_POLY does not cause any regressions > > If that works: OK for mainline > > Thanks for looking into this issue and working on the patches. > > Tobias > >

Re: [Patch] Fortran: Fix intrinsic null() handling [PR99651]

2021-03-23 Thread Paul Richard Thomas via Fortran
Hi Tobias, I took something of a detour in reviewing this patch. Although short, understanding it is not straightforward! Your patch works as advertised and regtests OK (with the patch for PR93660 on board as well). Is NULL the only case where this can happen? Just to aid my understanding, I

Re: [Patch] Fortran: Fix intrinsic null() handling [PR99651]

2021-03-23 Thread Paul Richard Thomas via Fortran
Cancel the thought on my patchlet null_5.f90 fails on excess errors. Paul On Tue, 23 Mar 2021 at 17:34, Paul Richard Thomas < paul.richard.tho...@gmail.com> wrote: > Hi Tobias, > > I took something of a detour in reviewing this patch. Although short, > understanding it is n

[Patch, fortran] PR99602 - [11 regression] runtime error: pointer actual argument not associated

2021-03-26 Thread Paul Richard Thomas via Fortran
This patch is straightforward but the isolation of the problem was rather less so. Many thanks to Juergen for testcase reduction. Regtested on FC33/x86_64 - OK for master? Paul Fortran: Fix problem with runtime pointer chack [PR99602]. 2021-03-26 Paul Thomas gcc/fortran/ChangeLog PR

Re: [Patch] Fortran: Fix intrinsic null() handling [PR99651]

2021-03-26 Thread Paul Richard Thomas via Fortran
Hi Tobias, Please go ahead and commit the patch. I think that your analysis is correct about expr_null and that your patch is the best way to deal with the problem. Best regards Paul On Tue, 23 Mar 2021 at 17:54, Tobias Burnus wrote: > Hi Paul, > > On 23.03.21 18:34, Paul Richa

Re: [PATCH] PR fortran/99112 - [11 Regression] ICE with runtime diagnostics for SIZE intrinsic function

2021-03-13 Thread Paul Richard Thomas via Fortran
Hi Harald, I am not sure of the etiquette for this - it looks OK to me :-) Cheers Paul On Fri, 12 Mar 2021 at 21:20, Harald Anlauf via Fortran wrote: > Dear all, > > the addition of runtime checks for the SIZE intrinsic created a regression > that showed up for certain CLASS arguments to

[Patch, fortran] PR99602 - [11 regression] runtime error: pointer actual argument not associated

2021-03-16 Thread Paul Richard Thomas via Fortran
Hi Everybody, Although this is 'obvious' I thought that I should post it because I believe that it was triggered by the fix for PR99602 but I just do not have the bandwidth at the moment to test that. The ChangeLog together with the patch is more than sufficient explanation. Regtests OK on

Re: [Patch, fortran] PR99602 - [11 regression] runtime error: pointer actual argument not associated

2021-03-18 Thread Paul Richard Thomas via Fortran
: > Hi Paul, hi all fortran@/gcc-patch@ reader, > > it looks as if you replied with your patch submission to the wrong email > address – and your re-submission ended up at > https://gcc.gnu.org/PR99602#c17 > > On 16.03.21 18:08, Tobias Burnus wrote: > > On 16.03.21 17:42,

Re: GCC 10.2.1 Status Report (2021-03-19)

2021-03-19 Thread Paul Richard Thomas via Fortran
Hi Tobias, I'll do the reviews for you tomorrow morning. Right now my brain has turned to mush after an excess of online meetings :-( I'll take a look through my PRs to see what might need pushing onto 10-branch. Cheers Paul On Fri, 19 Mar 2021 at 14:15, Tobias Burnus wrote: > FYI. > > On

[Patch, fortran] PR99545 [11 Regression] ICE in gfc_trans_assignment since r11-6253-gce8dcc9105cbd404

2021-03-15 Thread Paul Richard Thomas via Fortran
Applied to all three branches, after regtesting on each, as blindingly obvious. The testcase is the reduced version in comment #6 of the PR. Paul Fortran: Fix problem with allocate initialization [PR99545]. 2021-03-15 Paul Thomas gcc/fortran/ChangeLog PR fortran/99545 * trans-stmt.c

Re: [Patch, fortran] 99307 - FAIL: gfortran.dg/class_assign_4.f90 execution test

2021-04-15 Thread Paul Richard Thomas via Fortran
Pushed to master in commit 9a0e09f3dd5339bb18cc47317f2298d9157ced29 Thanks Paul On Wed, 14 Apr 2021 at 14:51, Tobias Burnus wrote: > On 11.04.21 09:05, Paul Richard Thomas wrote: > > Tobias noticed a major technical fault with the resubmission below: I > > forgot to a

[Patch, fortran] PR100110 - Parameterized Derived Types, problems with global variable

2021-04-19 Thread Paul Richard Thomas via Fortran
Hi All, I was just about to announce that I will only do backports and regressions, while I finally attack the fundamental problem with the representation of Parameterized Derived Types. Then this PR came up that was such clear low hanging fruit that I decided to fix it right away. Regtests on

Re: [PATCH] PR fortran/63797 - Bogus ambiguous reference to 'sqrt'

2021-04-16 Thread Paul Richard Thomas via Fortran
amp;& (gfc_option.allow_std & GFC_STD_F2003)) return; Modify or replace the comment, as desired. The change to the condition gives the desired result in terms of standard compliance. Regards Paul On Fri, 16 Apr 2021 at 09:32, Paul Richard Thomas < paul.richard.tho...@g

Re: [PATCH] PR fortran/63797 - Bogus ambiguous reference to 'sqrt'

2021-04-16 Thread Paul Richard Thomas via Fortran
Hi All, Harald, that is to say the least of it an elegant and minimalist fix. With the patch applied, gfortran behaves like the "other brand" and regtests OK. Bernhard correctly points out that there should be a comment. Not only this, there must be an F2003 standard check, since F95 forbids

Re: [Patch, fortran] PR100110 - Parameterized Derived Types, problems with global variable

2021-04-20 Thread Paul Richard Thomas via Fortran
aul, > > On 19.04.21 14:40, Paul Richard Thomas via Gcc-patches wrote: > > I was just about to announce that I will only do backports and > regressions, > > while I finally attack the fundamental problem with the representation of > > Parameterized Derived Types. Then this PR c

Re: [Patch, fortran] PR100110 - Parameterized Derived Types, problems with global variable

2021-04-20 Thread Paul Richard Thomas via Fortran
1:58, Tobias Burnus wrote: > > Hi Paul, > > > > is there a reason why you did not apply the patch to mainline ('master') > > but only to GCC 11 ('releases/gcc-11')? > > > > While GCC 11 is okay, I had expected it to be (only) on mainline! > > >

[Patch, fortran] PR84119 - Type parameter inquiry for PDT returns array instead of scalar

2021-04-20 Thread Paul Richard Thomas via Fortran
Hi All, This is another PDT warm-up patch before tackling the real beast: PR82649. As the contributor wrote in the PR, "The F08 standard clearly distinguishes between type parameter definition statements and component definition statements. See R425, R431, R435, and in particular see Note 6.7

Re: [Patch, fortran v2] PR fortran/84006, PR fortran/100027 - ICE on storage_size with polymorphic argument

2021-04-17 Thread Paul Richard Thomas via Fortran
Hi Jose, Please take a look at my reply on the PR, which points to PR98534. Regards Paul On Fri, 16 Apr 2021 at 20:47, José Rui Faustino de Sousa via Fortran < fortran@gcc.gnu.org> wrote: > Hi All! > > Proposed patch to: > PR84006 - [8/9/10/11 Regression] ICE in storage_size() with CLASS

Re: *PING**2 – Re: [Patch] Fortran: Fix Bind(C) char-len check, add ptr-contiguous check

2021-08-31 Thread Paul Richard Thomas via Fortran
Hi Tobias, s/However, as argument they are also iteroperable/However, as an argument they are also interoperable/ s/ /* else: valid only sind F2018 - and an assumed-shape/rank array; however, gfc_notify_std is already called when those array type are used. Thus, silently accept F200x. */

Re: Missing finalizations

2021-09-15 Thread Paul Richard Thomas via Fortran
Hi Andrew, Not long before I had to step aside (temporarily, I hope) from gfortran maintenance, I made quite a lot of progress on missing finalizations. I'll dig out the in-progress patch for you and remind myself of the remaining issues. One of these was a standards problem, where the patched

Re: [RFC] Fixing PR102685 and testsuite issues

2021-10-14 Thread Paul Richard Thomas via Fortran
Hi Harald, The overfilled constructor in transfer_simplify_2.f90 is indeed an error. The error is picked up correctly for arrays in expr.c(gfc_check_conformance):3579 but not for array components. Regards Paul On Thu, 14 Oct 2021 at 10:26, Tobias Burnus wrote: > Dear all, hello Harald, > >

Re: [Patch] Fortran: Fix CLASS conversion check [PR102745]

2021-10-17 Thread Paul Richard Thomas via Fortran
Hi Tobias, This is OK for mainline and as far back in the branches as you feel inclined to go. Thanks for the patch. Paul On Fri, 15 Oct 2021 at 22:19, Tobias Burnus wrote: > This patch fixes two issues: > > First, to print 'CLASS(t2)' instead of: > Error: Type mismatch in argument ‘x’ at

  1   2   3   >