[Bug fortran/20938] Dependency checking fails for equivalences

2005-04-10 Thread tobi at gcc dot gnu dot org

--- Additional Comments From tobi at gcc dot gnu dot org  2005-04-11 00:16 
---
Yes this is the problem, as evidenced in the tree dumps, and as confirmed by
looking through dependency.c.

-- 
   What|Removed |Added

 Status|UNCONFIRMED |NEW
 Ever Confirmed||1
   Last reconfirmed|-00-00 00:00:00 |2005-04-11 00:16:40
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20938


[Bug fortran/20938] Dependency checking fails for equivalences

2006-02-18 Thread pault at gcc dot gnu dot org


--- Comment #2 from pault at gcc dot gnu dot org  2006-02-18 16:16 ---
A patch is on its way - it's regtesting right now.

This fixes the problem with where_19.f90 as well.

Paul


-- 

pault at gcc dot gnu dot org changed:

   What|Removed |Added

 AssignedTo|unassigned at gcc dot gnu   |pault at gcc dot gnu dot org
   |dot org |
 Status|NEW |ASSIGNED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20938



[Bug fortran/20938] Dependency checking fails for equivalences

2006-02-19 Thread tobi at gcc dot gnu dot org


--- Comment #3 from tobi at gcc dot gnu dot org  2006-02-19 18:56 ---
I might be a little late, given that you already posted a patch which
completely fixes this issue
, but I thought of fixing
this back before we had the in_equivalence attribute, by simply assuming that
the RHS and the LHS are dependent if both are members of equivalences.  I'm not
convinced that this pathological case is worth all the effort.  Nevertheless
I'll review your patch during the next 48 hours.


-- 

tobi at gcc dot gnu dot org changed:

   What|Removed |Added

   Keywords||patch


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20938



[Bug fortran/20938] Dependency checking fails for equivalences

2006-02-19 Thread paulthomas2 at wanadoo dot fr


--- Comment #4 from paulthomas2 at wanadoo dot fr  2006-02-19 19:25 ---
Subject: Re:  Dependency checking fails for equivalences

tobi,

>--- Comment #3 from tobi at gcc dot gnu dot org  2006-02-19 18:56 ---
>I might be a little late, given that you already posted a patch which
>completely fixes this issue
>, but I thought of fixing
>this back before we had the in_equivalence attribute, by simply assuming that
>the RHS and the LHS are dependent if both are members of equivalences.  I'm not
>convinced that this pathological case is worth all the effort.  Nevertheless
>I'll review your patch during the next 48 hours.
>  
>
Thanks - I gave thought to the same fix. It has its advantages; like 
avoiding a quadratic term.  However, it will cause temporaries to 
sprout, where none are necessary.

The effort was not that great; similar code exists in match.c that I 
adapted.  I could not quite see how to combine them into one function, 
though.

Paul


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20938



[Bug fortran/20938] Dependency checking fails for equivalences

2006-02-25 Thread patchapp at dberlin dot org


--- Comment #5 from patchapp at dberlin dot org  2006-02-25 08:15 ---
Subject: Bug number PR20938

A patch for this bug has been added to the patch tracker.
The mailing list url for the patch is
http://gcc.gnu.org/ml/gcc-patches/2006-02/msg01891.html


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20938



[Bug fortran/20938] Dependency checking fails for equivalences

2006-03-01 Thread pault at gcc dot gnu dot org


--- Comment #6 from pault at gcc dot gnu dot org  2006-03-01 22:24 ---
Subject: Bug 20938

Author: pault
Date: Wed Mar  1 22:24:19 2006
New Revision: 111616

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=111616
Log:
2006-03-01  Paul Thomas  <[EMAIL PROTECTED]>

* iresolve.c (gfc_resolve_dot_product):  Remove any difference in
treatment of logical types.
* trans-intrinsic.c (gfc_conv_intrinsic_dot_product):  New function. 

PR fortran/26393
* trans-decl.c (gfc_get_symbol_decl): Extend condition that symbols
must be referenced to include unreferenced symbols in an interface
body. 

PR fortran/20938
* trans-array.c (gfc_conv_resolve_dependencies): Add call to
gfc_are_equivalenced_arrays.
* symbol.c (gfc_free_equiv_infos, gfc_free_equiv_lists): New
functions. (gfc_free_namespace): Call them.
* trans-common.c (copy_equiv_list_to_ns): New function.
(add_equivalences): Call it.
* gfortran.h: Add equiv_lists to gfc_namespace and define
gfc_equiv_list and gfc_equiv_info.
* dependency.c (gfc_are_equivalenced_arrays): New function.
(gfc_check_dependency): Call it.
* dependency.h: Prototype for gfc_are_equivalenced_arrays.

2006-03-01  Paul Thomas  <[EMAIL PROTECTED]>

* gfortran.dg/logical_dot_product.f90: New test. 

PR fortran/26393
* gfortran.dg/used_interface_ref.f90: New test.

PR fortran/20938
* gfortran.dg/dependency_2.f90: New test.
* gfortran.fortran-torture/execute/where17.f90: New test.
* gfortran.fortran-torture/execute/where18.f90: New test.
* gfortran.fortran-torture/execute/where19.f90: New test.
* gfortran.fortran-torture/execute/where20.f90: New test.


Added:
trunk/gcc/testsuite/gfortran.dg/dependency_2.f90
trunk/gcc/testsuite/gfortran.dg/logical_dot_product.f90
trunk/gcc/testsuite/gfortran.dg/used_interface_ref.f90
trunk/gcc/testsuite/gfortran.fortran-torture/execute/where17.f90
trunk/gcc/testsuite/gfortran.fortran-torture/execute/where18.f90
trunk/gcc/testsuite/gfortran.fortran-torture/execute/where19.f90
trunk/gcc/testsuite/gfortran.fortran-torture/execute/where20.f90
Modified:
trunk/MAINTAINERS
trunk/gcc/fortran/ChangeLog
trunk/gcc/fortran/dependency.c
trunk/gcc/fortran/dependency.h
trunk/gcc/fortran/gfortran.h
trunk/gcc/fortran/iresolve.c
trunk/gcc/fortran/symbol.c
trunk/gcc/fortran/trans-array.c
trunk/gcc/fortran/trans-common.c
trunk/gcc/fortran/trans-decl.c
trunk/gcc/fortran/trans-intrinsic.c
trunk/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20938



[Bug fortran/20938] Dependency checking fails for equivalences

2006-03-01 Thread pault at gcc dot gnu dot org


--- Comment #7 from pault at gcc dot gnu dot org  2006-03-01 23:26 ---
Fixed on mainline.  Patch ready for 4.1 to reopen.

Paul


-- 

pault at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20938



[Bug fortran/20938] Dependency checking fails for equivalences

2006-03-06 Thread pault at gcc dot gnu dot org


--- Comment #8 from pault at gcc dot gnu dot org  2006-03-07 00:06 ---
Subject: Bug 20938

Author: pault
Date: Tue Mar  7 00:06:37 2006
New Revision: 111796

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=111796
Log:
2006-03-07  Paul Thomas  <[EMAIL PROTECTED]>

PR fortran/26107
* resolve.c (resolve_function): Add name after test for pureness.

* iresolve.c (gfc_resolve_dot_product):  Remove any difference in
treatment of logical types.
* trans-intrinsic.c (gfc_conv_intrinsic_dot_product):  New function. 

PR fortran/26393
* trans-decl.c (gfc_get_symbol_decl): Extend condition that symbols
must be referenced to include unreferenced symbols in an interface
body. 

PR fortran/20938
* trans-array.c (gfc_conv_resolve_dependencies): Add call to
gfc_are_equivalenced_arrays.
* symbol.c (gfc_free_equiv_infos, gfc_free_equiv_lists): New
functions. (gfc_free_namespace): Call them.
* trans-common.c (copy_equiv_list_to_ns): New function.
(add_equivalences): Call it.
* gfortran.h: Add equiv_lists to gfc_namespace and define
gfc_equiv_list and gfc_equiv_info.
* dependency.c (gfc_are_equivalenced_arrays): New function.
(gfc_check_dependency): Call it.
* dependency.h: Prototype for gfc_are_equivalenced_arrays.

PR fortran/24519
* dependency.c (gfc_is_same_range): Correct typo.
(gfc_check_section_vs_section): Call gfc_is_same_range.

PR fortran/25395
* trans-common.c (add_equivalences): Add a new flag that is set when
an equivalence is seen that prevents more from being reset until the
start of a new traversal of the list, thus ensuring completion of
all the equivalences.

PR fortran/25054
* resolve.c (is_non_constant_shape_array): New function.
(resolve_fl_variable): Remove code for the new function and call it.
(resolve_fl_namelist): New function.  Add test for namelist array
with non-constant shape, using is_non_constant_shape_array.
(resolve_symbol): Remove code for resolve_fl_namelist and call it.

PR fortran/25089
* match.c (match_namelist): Increment the refs field of an accepted
namelist object symbol.
* resolve.c (resolve_fl_namelist): Test namelist objects for a conflict
with contained or module procedures.

PR fortran/24557
* trans-expr.c (gfc_add_interface_mapping): Use the actual argument
for character(*) arrays, rather than casting to the type and kind
parameters of the formal argument.

2006-03-07  Paul Thomas  <[EMAIL PROTECTED]>

PR fortran/26107
* resolve.c (resolve_function): Add name after test for pureness.

* gfortran.dg/logical_dot_product.f90: New test. 

PR fortran/26393
* gfortran.dg/used_interface_ref.f90: New test.

PR fortran/20938
* gfortran.dg/dependency_2.f90: New test.
* gfortran.fortran-torture/execute/where17.f90: New test.
* gfortran.fortran-torture/execute/where18.f90: New test.
* gfortran.fortran-torture/execute/where19.f90: New test.
* gfortran.fortran-torture/execute/where20.f90: New test.

PR fortran/24519
* gfortran.dg/dependency_3.f90: New test.
* gfortran.fortran-torture/execute/vect-3.f90: Remove two of the
XFAILs.

PR fortran/25395
* gfortran.dg/equiv_6.f90: New test.

PR fortran/25054
* gfortran.dg/namelist_5.f90: New test.

PR fortran/25089
* gfortran.dg/namelist_4.f90: New test.

PR fortran/24557
* gfortran.dg/assumed_charlen_needed_1.f90: New test.

Added:
   
branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/assumed_charlen_needed_1.f90
branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/dependency_2.f90
branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/dependency_3.f90
branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/equiv_6.f90
branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/logical_dot_product.f90
branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/namelist_4.f90
branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/namelist_5.f90
branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/pure_dummy_length_1.f90
branches/gcc-4_1-branch/gcc/testsuite/gfortran.dg/used_interface_ref.f90
   
branches/gcc-4_1-branch/gcc/testsuite/gfortran.fortran-torture/execute/where17.f90
   
branches/gcc-4_1-branch/gcc/testsuite/gfortran.fortran-torture/execute/where18.f90
   
branches/gcc-4_1-branch/gcc/testsuite/gfortran.fortran-torture/execute/where19.f90
   
branches/gcc-4_1-branch/gcc/testsuite/gfortran.fortran-torture/execute/where20.f90
Modified:
branches/gcc-4_1-branch/MAINTAINERS
branches/gcc-4_1-branch/gcc/fortran/ChangeLog
branches/gcc-4_1-branch/gcc/fortran/dependency.c
branches/gcc-4_1-branch/gcc/for

[Bug fortran/20938] Dependency checking fails for equivalences

2006-03-06 Thread pinskia at gcc dot gnu dot org


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

   Target Milestone|--- |4.1.1


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20938