[Bug fortran/104908] [11/12 Regression] incorrect Fortran out-of-bound runtime error.

2022-04-21 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104908

Richard Biener  changed:

   What|Removed |Added

   Target Milestone|11.3|11.4

--- Comment #3 from Richard Biener  ---
GCC 11.3 is being released, retargeting bugs to GCC 11.4.

[Bug fortran/104908] [11/12 Regression] incorrect Fortran out-of-bound runtime error.

2022-03-22 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104908

Richard Biener  changed:

   What|Removed |Added

   Target Milestone|--- |11.3

[Bug fortran/104908] [11/12 Regression] incorrect Fortran out-of-bound runtime error.

2022-03-17 Thread anlauf at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104908

anlauf at gcc dot gnu.org changed:

   What|Removed |Added

 CC||albandil at atlas dot cz

--- Comment #2 from anlauf at gcc dot gnu.org ---
*** Bug 104972 has been marked as a duplicate of this bug. ***

[Bug fortran/104908] [11/12 Regression] incorrect Fortran out-of-bound runtime error.

2022-03-15 Thread anlauf at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104908

anlauf at gcc dot gnu.org changed:

   What|Removed |Added

Summary|gfortran 11/trunk   |[11/12 Regression]
   |regression: incorrect   |incorrect Fortran
   |Fortran out-of-bound|out-of-bound runtime error.
   |runtime error.  |
 Ever confirmed|0   |1
 Status|UNCONFIRMED |NEW
   Last reconfirmed||2022-03-15
   Priority|P3  |P4

--- Comment #1 from anlauf at gcc dot gnu.org ---
Likely caused by the fix for PR95331 (r11-1235).  Class-related.
Applying

diff --git a/gcc/fortran/trans-array.cc b/gcc/fortran/trans-array.cc
index cfb6eac11c7..3a14600101f 100644
--- a/gcc/fortran/trans-array.cc
+++ b/gcc/fortran/trans-array.cc
@@ -3864,8 +3864,8 @@ gfc_conv_array_ref (gfc_se * se, gfc_array_ref * ar,
gfc_expr *expr,
 }

   decl = se->expr;
-  if (IS_CLASS_ARRAY (sym) && sym->attr.dummy && ar->as->type != AS_DEFERRED)
-decl = sym->backend_decl;
+  // if (IS_CLASS_ARRAY (sym) && sym->attr.dummy && ar->as->type !=
AS_DEFERRED)
+  //   decl = sym->backend_decl;

   cst_offset = offset = gfc_index_zero_node;
   add_to_offset (&cst_offset, &offset, gfc_conv_array_offset (decl));

apparently "fixes" the wrong bounds check.