This is the mail archive of the gdb@sourceware.cygnus.com mailing list for the GDB project. See the GDB home page for more information.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
On 31 Jan 1999, Stan Shebs wrote: > andy@maxwell.la.asu.edu (Andy Vaught) writes: > > > Of course, only after the patch has actually been *sent* does an alternate > > explanation occur-- g77 may be at fault! Running gdb on AIX works fine, > > so it looks like g77 is the one that is backwards.... > > Yes, this particular convention was set up for the benefit of other > Fortran compilers. Craig Burley keeps saying that g77's debug info > generation needs a bunch of work, and not to worry about what GDB > makes of it yet. So if this is important to you, you might want to > consider delving into g77 a bit. > > Stan I tested it on an SGI running irix 6, and it works fine as well. It really looks like g77 is the only one generating fortran array elements in the wrong order. I have delved into g77 a bunch, but it looks like the place where the symbols are actually exported to stabs may have other things dependent on them. Craig doesn't seem too keen on fixing code that is part of a large block that he thinks should be removed and rewritten. I don't think he has had a lot of time to work on g77 anyway. One thing that *is* wrong with gdb is that the output of the 'whatis x' where x is an array prints the dimensions in reverse order, this on AIX and irix. On a g77-compiled program it prints the correct order (because g77 and gdb are backwards). I've also been thinking about some enhancements to gdb's fortran mode: Extend the expression parser to accept <, >, ==, etc in expressions instead of just the usual .eq., .gt., which can be kind of cumbersome. This is trivial to implement. Implement something like the :: operator in fortran mode, so that variables that are SAVEd or common in a program block can be viewed without that block having to be on the stack. Have the parser automatically insert the dereferencing operater when it sees a pointer variable. Fortran 77 doesn't have pointers, and its clumsy in gdb to have to say 'b if *a .eq. 1' or 'p (*a)(1,1)' if 'a' is a dummy variable (which are always pointers). Fix the printing of complex and double complex variables (although this may be a g77 issue). Andy ----------------- XOLD(K,IC,I)= Andy Vaught .... DO ITERS=1, 10 XOLD(K,IC,I) andy@maxwell.la.asu.edu | | /CALLMSOLVE(A,B,X,I,ITERS,TOL)+(RANNYU(0) Arizona State University ======|WRITE(6,'(I5,2X,F12.6)')ITERS,TOL -HALF) Tempe, Arizona USA OOOOOO \ENDDORETURN PARAMETER(ZERO=1.D0)*TENTH*DELTA