tru64-unix-managers (formerly alpha-osf-managers) (1994-2012)
 help / color / mirror / Atom feed
From: SSridhar <ssridhar () raven ! pnu ! com>
To: tru64-unix-managers
Subject: SUMMARY:  fortran compatibility with 4.0G
Date: Wed, 27 Jun 2001 20:03:48 +0000	[thread overview]
Message-ID: <102653649622110.tru64-unix-managers.marc@archive.invalid> (raw)

Original question:

we recently upgraded our Alpha8400 from 4.0E to 4.0G. I also installed
the latest version of f77 (that came with 5.1 disks) after making sure
it was backward compatible. most programs run fine but one didn't - it
worked fine in 4.0E but now creates segmentation fault error. Also a
code that is a mix of fortran and c (f77 calling c code) after
recompilation creates error:
forrtl: severe (174): SIGSEGV, segmentation fault occurred
   0: _call_remove_gp_range [0x3ff81a6c374]
   1: _call_remove_gp_range [0x3ff81a74a00]
   2: _call_remove_gp_range [0x3ff800d9040]
   3: _call_remove_gp_range [0x3ff800da648]
   4: aacomp_ [0x120003398]
   5: main$cell_ [cell.f: 59, 0x120002424]
   6: main [for_main.c: 203, 0x120003c54]
   7: __start [0x120001ff8]

But if I run same code, compiled on older version of OS, on the 4.0G
system it works.
-------------------------------------------------------------------------

I was passing a filename as charcter string from fortran to c. I had
inserted a "\0" as last character in the string before passing. This was
fine in 5.2.0 and prior compilers but in 5.4A it adds a "\" at the end
of filename. Since such a file doesn't exist, the pointer is a null
pointer and that led to the crash. Now I use the statement

filename(i:i) = char(0)

where i is the position of first blank after end of string and this
works. I used dbx to figure this out. 

thanks to the following people for their responses:

        "Dr. Thomas.Blinn@Compaq.com" <tpb@doctor.zk3.dec.com>
        "Dyer, Steve J." <Steve.Dyer@alcoa.com>
         system administration account <sysadmin@astro.su.se>
        Serguei Patchkovskii <patchkov@ucalgary.ca>

Sridhar

                 reply	other threads:[~2001-06-27 20:03 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox