From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22740 invoked by alias); 13 Aug 2004 22:14:15 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 22732 invoked from network); 13 Aug 2004 22:14:14 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sourceware.org with SMTP; 13 Aug 2004 22:14:14 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.12.10/8.12.10) with ESMTP id i7DMEEe1010076 for ; Fri, 13 Aug 2004 18:14:14 -0400 Received: from zenia.home.redhat.com (porkchop.devel.redhat.com [172.16.58.2]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id i7DMECa10908; Fri, 13 Aug 2004 18:14:12 -0400 To: David Lecomber Cc: patches Subject: Re: [PATCH/RFA] PR gdb/648 References: <1091830216.4188.23.camel@localhost> From: Jim Blandy Date: Fri, 13 Aug 2004 22:14:00 -0000 In-Reply-To: <1091830216.4188.23.camel@localhost> Message-ID: User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2004-08/txt/msg00496.txt.bz2 David Lecomber writes: > 2004-08-06 David Lecomber > > Fix PR gdb/648 > * dwarf2read.c (read_array_type): Handle column major arrays > correctly. Assume column major for Fortran except with G77 > compiler. > * eval.c (evaluate_subexp_standard): Assume Fortran arrays are > oriented large to small in type structure. Thanks very much for the patch and test program. It was helpful to be able to actually look at what GNU F77 was producing for a real Fortran program. For the dwarf2read.c part, I think the essential approach is fine. However: - Rather than recognizing Fortran specially in read_array_type, I'd rather have a new member of 'struct language_defn' giving the array ordering for that language. - I'd like to have the logic that chooses a byte order pulled out of read_array_type into its own function that takes a die, a cu, and returns a DW_ORD_ value. That function would take care of looking for a DW_AT_ordering attribute, recognizing the appropriate versions of GNU F77, and so on. read_array_type should call that function and build the type appropriately.