[Info-vax] VMS port to x86
Bob Koehler
koehler at eisner.nospam.encompasserve.org
Thu May 31 10:27:39 EDT 2012
In article <jq60p7$2st$1 at speranza.aioe.org>, glen herrmannsfeldt <gah at ugcs.caltech.edu> writes:
>
> To make that work, the linker fixes things up.
I've seen the linker on TOPS-20 do that. But not on VMS. The
TOPS-20 calling standard incudes sufficent flags in the high bits
of the address field to figure it out. I'm not aware of anything
in the VMS object file that would allow the linker to figure it out.
Can you generate an example using a VMS Fortran compiler?
I have not seen any compiler that would generate different calling
conventions depending on whether the CHARACTER data was a variable
or a constant.
>
> It is more usual for Fortran 77 compilers to pass the length
> of CHARACTER expressions as extra arguments on the end of
> the argument list. They are then ignored if the called routine
> doesn't use CHARACTER dummy variables. That wasn't consistent
> with the VAX/VMS calling convention, though.
I've seen compilers do that, and I've seen them pass the length
as an extra argument immediately after the address of the CHARACTER,
where it could not so easily be ignored.
IIRC, the earliest Fortran compiler for VMS was "Fortran IV Plus", and
actually had CHARACTER and other Fortran 77 pieces, so there was no
need to mix Fortran 66 and 77 calling conventions for character data.
TOPS-20, as a different example, had only a Fortran 66 compiler for a
long time and the system did need to be able to mix Fortran 66 and 77
character conventions.
More information about the Info-vax
mailing list