Thanks for the replies. What I really want to know is whether the double precision version of the real copied from the single as above, will always have the same value irrespective of which options are used in the Fortan compilation.
ie. it is not 'garbage' that gets copied into the extra 4 bytes, but rather a set of binary zeros, which will always translate into the same double precision value. Is that correct?
The answer to that is "it depends". For a value of real(4) copied from memory to a value of real(8) copied into memory then the answer is they are identical in bit patterns as read right to left in the mantissa. However, at a given point in a computation using the virtual FPP87 in the ia-32 areceture if you were to save the value of a partialy completed expression (intermediary value is more than 4 bytes) then the answer is no.
Secondly, When you print the real(4) out you are printing less of the precision of the variable than when you print the real(8) out. Therefore you were able to see the difference in the mantissa of ...03nnn which is less than the 0.5 rounding of the formatted printout. Try using E16.12 on the format for the real(4) printout. You will likely see the stuff you interpret as junk. This junk represents the error in the real(4) due to roundoff of a fraction that exceeds the precision of the real(4). The error in the VAX system using real(4) exceeds that of the error in the real(8) on the Intel system. Expect the computations to produce different results when using real(4) vs real(8) variables in your program.
If you are intending on testing results between the before port on the VAX system to the after port on the IA-32/64 system then specify your data as real(4) when you make your verification runs. Once you are satisfied that computation to the same precision yields reasonable results then you can extend the precision to real(8) to produce better (and different) results.