From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6076 invoked by alias); 1 Jul 2005 21:09:13 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 6066 invoked by uid 22791); 1 Jul 2005 21:09:09 -0000 Received: from diamondback.brooks.af.mil (HELO diamondback.brooks.af.mil) (140.140.58.5) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Fri, 01 Jul 2005 21:09:09 +0000 Received: from citsmr0.brooks.af.mil (citsmr0.brooks.af.mil [140.140.57.198]) by diamondback.brooks.af.mil with SMTP id j61LCRZh011754 for ; Fri, 1 Jul 2005 16:12:27 -0500 (CDT) Received: from fscnbc15.brooks.af.mil ([140.140.249.120]) by citsmr0.brooks.af.mil (SMSSMTP 4.1.0.19) with SMTP id M2005070116090627803 for ; Fri, 01 Jul 2005 16:09:06 -0500 Received: by FSCNBC15.brooks.afmc.ds.af.mil with Internet Mail Service (5.5.2657.72) id ; Fri, 1 Jul 2005 16:09:06 -0500 Message-ID: <6AC29D5306A1CD4AB6A168570B1176A40797B2E9@casino.brooks.af.mil> From: Parker James E Contr AFRL/HEDR To: "'gdb@sources.redhat.com'" Subject: gdb and Fortran90 arrays Date: Fri, 01 Jul 2005 21:09:00 -0000 MIME-Version: 1.0 Content-Type: text/plain X-SW-Source: 2005-07/txt/msg00007.txt.bz2 Hello, I was wondering if anyone could help me decipher the output from gdb when debugging Fortran90 code. Since gdb doesn't currently support Fortran90, it defaults to a language format called "minimal", which is fine for most uses, but for arrays the output is cryptic for me. Example define an array real(KIND(1.0D0)), dimension(6)::x If I wanted to examine x(2), I normally (fortran 77) would use (gdb) p x(2) But under the minimal language setting, gdb interprets parenthesis as a function call--that of course doesn't exist--and therefore gdb complains with an error. I tried using [ ] to replace the parentheses, but gdb correctly replies that operator [] is undefined. The best result I have is at a gdb prompt type (gdb) p x And you get a list that contains an offset, ecode, base and info. Can anyone tell me what these things are? Ecode seems to represent the size of each element in the array, but that's just a guess. The rest is some sort of memory pointer, but I can't decipher it. Jim Parker