public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/22244] dimension information is lost for multi-dimension array
       [not found] <bug-22244-10906@http.gcc.gnu.org/bugzilla/>
@ 2006-01-09 23:31 ` pinskia at gcc dot gnu dot org
  2006-08-03 13:45 ` tom dot horsley at ccur dot com
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-01-09 23:31 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from pinskia at gcc dot gnu dot org  2006-01-09 23:31 -------
Also this causes us to lose information lowering in the middle-end that what
the size of the arrays were.


-- 


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



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

* [Bug fortran/22244] dimension information is lost for multi-dimension array
       [not found] <bug-22244-10906@http.gcc.gnu.org/bugzilla/>
  2006-01-09 23:31 ` [Bug fortran/22244] dimension information is lost for multi-dimension array pinskia at gcc dot gnu dot org
@ 2006-08-03 13:45 ` tom dot horsley at ccur dot com
  2007-08-28 16:09 ` jakub at gcc dot gnu dot org
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 14+ messages in thread
From: tom dot horsley at ccur dot com @ 2006-08-03 13:45 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from tom dot horsley at ccur dot com  2006-08-03 13:45 -------
I'd add that this isn't a problem just for multi-dimension arrays. If you
declare different arrays like "integer a1(5)" "integer a2(1:5)" "integer
a3(2:6)"
they all show up with incorrect lower bound of 0 and upper bound of 4, making
it impossible to actually reference the correct array element in a subscript
expression in a debugger.


-- 

tom dot horsley at ccur dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |tom dot horsley at ccur dot
                   |                            |com


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


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

* [Bug fortran/22244] dimension information is lost for multi-dimension array
       [not found] <bug-22244-10906@http.gcc.gnu.org/bugzilla/>
  2006-01-09 23:31 ` [Bug fortran/22244] dimension information is lost for multi-dimension array pinskia at gcc dot gnu dot org
  2006-08-03 13:45 ` tom dot horsley at ccur dot com
@ 2007-08-28 16:09 ` jakub at gcc dot gnu dot org
  2007-09-25  9:33 ` jakub at gcc dot gnu dot org
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 14+ messages in thread
From: jakub at gcc dot gnu dot org @ 2007-08-28 16:09 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from jakub at gcc dot gnu dot org  2007-08-28 16:09 -------
Subject: Bug 22244

Author: jakub
Date: Tue Aug 28 16:08:57 2007
New Revision: 127864

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=127864
Log:
        PR fortran/22244
        * Make-lang.in (fortran/trans-types.o): Depend on $(FLAGS_H).
        * trans-types.c: Include flags.h.
        (gfc_get_nodesc_array_type): Add TYPE_DECL TYPE_NAME with
        correct bounds and dimensions for packed arrays.

Modified:
    trunk/gcc/fortran/ChangeLog
    trunk/gcc/fortran/Make-lang.in
    trunk/gcc/fortran/trans-types.c


-- 


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


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

* [Bug fortran/22244] dimension information is lost for multi-dimension array
       [not found] <bug-22244-10906@http.gcc.gnu.org/bugzilla/>
                   ` (2 preceding siblings ...)
  2007-08-28 16:09 ` jakub at gcc dot gnu dot org
@ 2007-09-25  9:33 ` jakub at gcc dot gnu dot org
  2007-10-04 21:47 ` tobi at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 14+ messages in thread
From: jakub at gcc dot gnu dot org @ 2007-09-25  9:33 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #8 from jakub at gcc dot gnu dot org  2007-09-25 09:32 -------
Subject: Bug 22244

Author: jakub
Date: Tue Sep 25 09:32:44 2007
New Revision: 128747

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=128747
Log:
        PR fortran/22244
        * Make-lang.in (fortran/trans-types.o): Depend on $(FLAGS_H).
        * trans-types.c: Include flags.h.
        (gfc_get_nodesc_array_type): Add TYPE_DECL TYPE_NAME with
        correct bounds and dimensions for packed arrays.

Modified:
    branches/redhat/gcc-4_1-branch/gcc/fortran/ChangeLog
    branches/redhat/gcc-4_1-branch/gcc/fortran/Make-lang.in
    branches/redhat/gcc-4_1-branch/gcc/fortran/trans-types.c


-- 


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


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

* [Bug fortran/22244] dimension information is lost for multi-dimension array
       [not found] <bug-22244-10906@http.gcc.gnu.org/bugzilla/>
                   ` (3 preceding siblings ...)
  2007-09-25  9:33 ` jakub at gcc dot gnu dot org
@ 2007-10-04 21:47 ` tobi at gcc dot gnu dot org
  2007-11-02 18:26 ` fxcoudert at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 14+ messages in thread
From: tobi at gcc dot gnu dot org @ 2007-10-04 21:47 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #9 from tobi at gcc dot gnu dot org  2007-10-04 21:46 -------
Can this be closed?


-- 

tobi at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |tobi at gcc dot gnu dot org


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


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

* [Bug fortran/22244] dimension information is lost for multi-dimension array
       [not found] <bug-22244-10906@http.gcc.gnu.org/bugzilla/>
                   ` (4 preceding siblings ...)
  2007-10-04 21:47 ` tobi at gcc dot gnu dot org
@ 2007-11-02 18:26 ` fxcoudert at gcc dot gnu dot org
  2007-11-12 10:50 ` jakub at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 14+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2007-11-02 18:26 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #10 from fxcoudert at gcc dot gnu dot org  2007-11-02 18:26 -------
I think there are other issues with array information, so I think this PR
shouldn't be closed yet.


-- 

fxcoudert at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |fxcoudert at gcc dot gnu dot
                   |                            |org
                URL|http://gcc.gnu.org/ml/gcc-  |
                   |patches/2007-               |
                   |08/msg00851.html            |


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


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

* [Bug fortran/22244] dimension information is lost for multi-dimension array
       [not found] <bug-22244-10906@http.gcc.gnu.org/bugzilla/>
                   ` (5 preceding siblings ...)
  2007-11-02 18:26 ` fxcoudert at gcc dot gnu dot org
@ 2007-11-12 10:50 ` jakub at gcc dot gnu dot org
  2007-11-27  9:57 ` burnus at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 14+ messages in thread
From: jakub at gcc dot gnu dot org @ 2007-11-12 10:50 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #11 from jakub at gcc dot gnu dot org  2007-11-12 10:50 -------
Attempt to deal with assumed shape, allocated etc. arrays:
http://gcc.gnu.org/ml/gcc-patches/2007-11/msg00612.html
Does not yet implement the DW_AT_associated and DW_AT_allocated attributes.
For those, guess for ALLOCATABLE, but non-POINTER, DW_AT_allocated could be
just
a test whether varx.data != NULL.  For POINTER I have no idea yet.
Any help would be appreciated.


-- 

jakub at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |jakub at gcc dot gnu dot org
                   |dot org                     |
                URL|                            |http://gcc.gnu.org/ml/gcc-
                   |                            |patches/2007-
                   |                            |11/msg00612.html
             Status|NEW                         |ASSIGNED
   Last reconfirmed|2005-12-30 19:36:08         |2007-11-12 10:50:45
               date|                            |


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


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

* [Bug fortran/22244] dimension information is lost for multi-dimension array
       [not found] <bug-22244-10906@http.gcc.gnu.org/bugzilla/>
                   ` (6 preceding siblings ...)
  2007-11-12 10:50 ` jakub at gcc dot gnu dot org
@ 2007-11-27  9:57 ` burnus at gcc dot gnu dot org
  2007-12-09 17:08 ` jakub at gcc dot gnu dot org
  2007-12-09 22:53 ` burnus at gcc dot gnu dot org
  9 siblings, 0 replies; 14+ messages in thread
From: burnus at gcc dot gnu dot org @ 2007-11-27  9:57 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #12 from burnus at gcc dot gnu dot org  2007-11-27 09:56 -------
I think the patch also fixes PR 17905.
Current patch links:
  http://gcc.gnu.org/ml/gcc-patches/2007-11/msg00888.html
  http://gcc.gnu.org/ml/gcc-patches/2007-11/msg00903.html


-- 


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


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

* [Bug fortran/22244] dimension information is lost for multi-dimension array
       [not found] <bug-22244-10906@http.gcc.gnu.org/bugzilla/>
                   ` (7 preceding siblings ...)
  2007-11-27  9:57 ` burnus at gcc dot gnu dot org
@ 2007-12-09 17:08 ` jakub at gcc dot gnu dot org
  2007-12-09 22:53 ` burnus at gcc dot gnu dot org
  9 siblings, 0 replies; 14+ messages in thread
From: jakub at gcc dot gnu dot org @ 2007-12-09 17:08 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #13 from jakub at gcc dot gnu dot org  2007-12-09 17:08 -------
Subject: Bug 22244

Author: jakub
Date: Sun Dec  9 17:08:06 2007
New Revision: 130724

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=130724
Log:
        PR fortran/22244
        * langhooks-def.h (LANG_HOOKS_GET_ARRAY_DESCR_INFO): Define.
        (LANG_HOOKS_FOR_TYPES_INITIALIZER): Add it.
        * langhooks.h (struct array_descr_info): Forward declaration.
        (struct lang_hooks_for_types): Add get_array_descr_info field.
        * dwarf2.h (DW_AT_bit_stride, DW_AT_byte_stride): New.
        (DW_AT_stride_size, DW_AT_stride): Keep around for Dwarf2
        compatibility.
        * dwarf2out.h (struct array_descr_info): New type.
        * dwarf2out.c (dwarf_attr_name): Rename DW_AT_stride to
        DW_AT_byte_stride and DW_AT_stride_size to DW_AT_bit_size.
        (descr_info_loc, add_descr_info_field, gen_descr_array_type_die):
        New functions.
        (gen_type_die_with_usage): Call lang_hooks.types.get_array_descr_info
        and gen_descr_array_type_die.

        * trans.h (struct array_descr_info): Forward declaration.
        (gfc_get_array_descr_info): New prototype.
        (enum gfc_array_kind): New type.
        (struct lang_type): Add akind field.
        (GFC_TYPE_ARRAY_AKIND): Define.
        * trans-types.c: Include dwarf2out.h.
        (gfc_build_array_type): Add akind argument.  Adjust
        gfc_get_array_type_bounds call.
        (gfc_get_nodesc_array_type): Include proper debug info even for
        assumed-size arrays.
        (gfc_get_array_type_bounds): Add akind argument, set
        GFC_TYPE_ARRAY_AKIND to it.
        (gfc_sym_type, gfc_get_derived_type): Adjust gfc_build_array_type
        callers.
        (gfc_get_array_descr_info): New function.
        * trans-array.c (gfc_trans_create_temp_array,
        gfc_conv_expr_descriptor): Adjust gfc_get_array_type_bounds
        callers.
        * trans-stmt.c (gfc_trans_pointer_assign_need_temp): Likewise.
        * trans-types.h (gfc_get_array_type_bounds): Adjust prototype.
        * Make-lang.in (fortran/trans-types.o): Depend on dwarf2out.h.
        * f95-lang.c (LANG_HOOKS_GET_ARRAY_DESCR_INFO): Define.

Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/dwarf2.h
    trunk/gcc/dwarf2out.c
    trunk/gcc/dwarf2out.h
    trunk/gcc/fortran/ChangeLog
    trunk/gcc/fortran/Make-lang.in
    trunk/gcc/fortran/f95-lang.c
    trunk/gcc/fortran/trans-array.c
    trunk/gcc/fortran/trans-stmt.c
    trunk/gcc/fortran/trans-types.c
    trunk/gcc/fortran/trans-types.h
    trunk/gcc/fortran/trans.h
    trunk/gcc/langhooks-def.h
    trunk/gcc/langhooks.h


-- 


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


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

* [Bug fortran/22244] dimension information is lost for multi-dimension array
       [not found] <bug-22244-10906@http.gcc.gnu.org/bugzilla/>
                   ` (8 preceding siblings ...)
  2007-12-09 17:08 ` jakub at gcc dot gnu dot org
@ 2007-12-09 22:53 ` burnus at gcc dot gnu dot org
  9 siblings, 0 replies; 14+ messages in thread
From: burnus at gcc dot gnu dot org @ 2007-12-09 22:53 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #14 from burnus at gcc dot gnu dot org  2007-12-09 22:53 -------
Close as FIXED (on the trunk/4.3.0). Note, for debugging multi-dimensional
arrays one also needs the following gdb patch:
  http://sourceware.org/ml/gdb-patches/2007-11/msg00438.html


-- 

burnus at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED


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


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

* [Bug fortran/22244] dimension information is lost for multi-dimension array
  2005-06-30  6:37 [Bug fortran/22244] New: " woodzltc at sources dot redhat dot com
                   ` (2 preceding siblings ...)
  2005-06-30 12:20 ` pinskia at gcc dot gnu dot org
@ 2005-06-30 13:29 ` tkoenig at gcc dot gnu dot org
  3 siblings, 0 replies; 14+ messages in thread
From: tkoenig at gcc dot gnu dot org @ 2005-06-30 13:29 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From tkoenig at gcc dot gnu dot org  2005-06-30 13:29 -------
g77 gets this right:

$ g77 -g array2.f
$ gdb ./a.out
GNU gdb Red Hat Linux (6.3.0.0-0.30.1rh)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "ia64-redhat-linux-gnu"...Using host libthread_db 
library "/lib/tls/libthread_db.so.1".

(gdb) b array2.f:8
Breakpoint 1 at 0x4000000000000db2: file array2.f, line 8.
(gdb) r
Starting program: /home/zfkts/Krempel/a.out

Breakpoint 1, MAIN__ () at array2.f:8
8                  write (*, *) a(i, j)
Current language:  auto; currently fortran
(gdb) p a
$1 = (( 1, 0, 65598, 0, -1357861061) ( -597610038, 65544, 0, -2147483648, -
169227304) ( 65513, 0, 0, -2019811328, 65515) ( 0, 448693, 0, 65598, 0) ( 0, 0, 
0, 0, 0) )
(gdb) p a(1,1)
$2 = 1


-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
OtherBugsDependingO|                            |19292
              nThis|                            |


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


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

* [Bug fortran/22244] dimension information is lost for multi-dimension array
  2005-06-30  6:37 [Bug fortran/22244] New: " woodzltc at sources dot redhat dot com
  2005-06-30  6:39 ` [Bug fortran/22244] " woodzltc at sources dot redhat dot com
  2005-06-30  8:42 ` tkoenig at gcc dot gnu dot org
@ 2005-06-30 12:20 ` pinskia at gcc dot gnu dot org
  2005-06-30 13:29 ` tkoenig at gcc dot gnu dot org
  3 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-06-30 12:20 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-06-30 12:20 -------
Confirmed, Paul B. said he was going to do this (IIRC).

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |pinskia at gcc dot gnu dot
                   |                            |org
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
   Last reconfirmed|0000-00-00 00:00:00         |2005-06-30 12:20:24
               date|                            |


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


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

* [Bug fortran/22244] dimension information is lost for multi-dimension array
  2005-06-30  6:37 [Bug fortran/22244] New: " woodzltc at sources dot redhat dot com
  2005-06-30  6:39 ` [Bug fortran/22244] " woodzltc at sources dot redhat dot com
@ 2005-06-30  8:42 ` tkoenig at gcc dot gnu dot org
  2005-06-30 12:20 ` pinskia at gcc dot gnu dot org
  2005-06-30 13:29 ` tkoenig at gcc dot gnu dot org
  3 siblings, 0 replies; 14+ messages in thread
From: tkoenig at gcc dot gnu dot org @ 2005-06-30  8:42 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From tkoenig at gcc dot gnu dot org  2005-06-30 08:42 -------
Confirmed.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |wrong-debug


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


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

* [Bug fortran/22244] dimension information is lost for multi-dimension array
  2005-06-30  6:37 [Bug fortran/22244] New: " woodzltc at sources dot redhat dot com
@ 2005-06-30  6:39 ` woodzltc at sources dot redhat dot com
  2005-06-30  8:42 ` tkoenig at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 14+ messages in thread
From: woodzltc at sources dot redhat dot com @ 2005-06-30  6:39 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From woodzltc at sources dot redhat dot com  2005-06-30 06:39 -------
This is Feng's comment:

http://gcc.gnu.org/ml/fortran/2005-06/msg00479.html

Just FYI.  Thanks. 

-- 


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


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

end of thread, other threads:[~2007-12-09 22:53 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-22244-10906@http.gcc.gnu.org/bugzilla/>
2006-01-09 23:31 ` [Bug fortran/22244] dimension information is lost for multi-dimension array pinskia at gcc dot gnu dot org
2006-08-03 13:45 ` tom dot horsley at ccur dot com
2007-08-28 16:09 ` jakub at gcc dot gnu dot org
2007-09-25  9:33 ` jakub at gcc dot gnu dot org
2007-10-04 21:47 ` tobi at gcc dot gnu dot org
2007-11-02 18:26 ` fxcoudert at gcc dot gnu dot org
2007-11-12 10:50 ` jakub at gcc dot gnu dot org
2007-11-27  9:57 ` burnus at gcc dot gnu dot org
2007-12-09 17:08 ` jakub at gcc dot gnu dot org
2007-12-09 22:53 ` burnus at gcc dot gnu dot org
2005-06-30  6:37 [Bug fortran/22244] New: " woodzltc at sources dot redhat dot com
2005-06-30  6:39 ` [Bug fortran/22244] " woodzltc at sources dot redhat dot com
2005-06-30  8:42 ` tkoenig at gcc dot gnu dot org
2005-06-30 12:20 ` pinskia at gcc dot gnu dot org
2005-06-30 13:29 ` tkoenig at gcc dot gnu dot org

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