barry@pico.math.ucla.edu (Barry Merriman) (09/27/90)
I'm trying to port a Cray Fortran code to Sun Fortran (f77) (the direction of the future? -). Is there a filter available to do this? There is a filter to convert from Vax VMS Fortran to Sun, so a Cray -> VMS filter would be enough. The Cray code runs under the CTSS op sys, on the NERSC Crays (formerly MFE) by the way. Thanks for any help you can give, -- Barry Merriman UCLA Dept. of Math UCLA Inst. for Fusion and Plasma Research barry@math.ucla.edu (Internet)
seibel@cgl.ucsf.edu (George Seibel) (09/27/90)
barry@pico.math.ucla.edu (Barry Merriman) writes: >I'm trying to port a Cray Fortran code to Sun Fortran (f77) >(the direction of the future? -). Is there a filter available >to do this? >There is a filter to convert from Vax VMS Fortran to Sun, so >a Cray -> VMS filter would be enough. >The Cray code runs under the CTSS op sys, on the NERSC Crays >(formerly MFE) by the way. Cray Research has only recently started putting a lot of extensions in their compiler, so there's a good chance that what you have is mostly standard fortran. If you are real lucky, all you'll have to do is comment out the "call dropfile()" that CTSS insists all programs contain. You probably won't be quite that lucky, though. If the code was tweaked for the cray, there's a good chance you'll find some calls to library routines, like the CVMGx() series. You'll need to provide fortran (or whatever) versions of all those, or recode the program. Now that the cray compilers are a lot smarter than they used to be, some of the old library routines are no longer required for good performance. You might find that the software is relying on ints and reals being the same size, which is ok on a cray where they are both 64 bits; but if the software is not numerically stable in 32 bit precision, you might have some trouble making it double precision. Or maybe not. It all depends on whether or not the original programmer knew what he was doing, or cared. At any rate, I kinda doubt that you need a filter, (or that a robust/complete one exists) rather I suspect a fortran version of any library routines your code calls is what you'll need, if anything. Of course, if the code is really bizarre, all bets are off... Your VMStran converter would probably clean up some extensions that might be found in "Cray" fortran. Wouldn't it be nice if people just wrote portable code? If we'd gotten a new ANSI standard around 1983 that just added the simple extensions that have become almost-de facto standards? blah blah blah... oh well. good luck. George Seibel, UCSF seibel@cgl.ucsf.edu
mcneill@eplrx7.uucp (Keith McNeill) (09/27/90)
From article <415@kaos.MATH.UCLA.EDU>, by barry@pico.math.ucla.edu (Barry Merriman): > I'm trying to port a Cray Fortran code to Sun Fortran (f77) > (the direction of the future? -). Is there a filter available > to do this? > > There is a filter to convert from Vax VMS Fortran to Sun, so > a Cray -> VMS filter would be enough. > The Sun Fortran compliler comes with many VMS Fortran extensions. Keith -- Keith D. McNeill | E.I. du Pont de Nemours & Co. eplrx7!mcneill@uunet.uu.net | Engineering Physics Laboratory (302) 695-9353/7395 | P.O. Box 80357 | Wilmington, Delaware 19880-0357 -- The UUCP Mailer