(j3.2006) Adventures in sections of constant arrays
Steidel, Jon L
jon.l.steidel
Mon Mar 6 16:33:21 EST 2017
It used to be that Cray made a copy of constants to pass as actual arguments, so that if the argument was overwritten, the original constant was untouched. That still be the case for the Cray implementation.
-jon
From: j3-bounces at mailman.j3-fortran.org [mailto:j3-bounces at mailman.j3-fortran.org] On Behalf Of Steve Lionel
Sent: Monday, March 6, 2017 4:03 PM
To: fortran standards email list for J3 <j3 at mailman.j3-fortran.org>
Subject: Re: (j3.2006) Adventures in sections of constant arrays
Might it be that Cray (and maybe PGI) doesn't put constants in write-protected memory, thus allowing overwriting the constant? I know of many compilers (including Intel's for a while) that did this, and it was a classic issue further in the past.
Steve
On Mon, Mar 6, 2017 at 3:53 PM, Bill Long <longb at cray.com<mailto:longb at cray.com>> wrote:
Next: Cray
???????
> module swap PrgEnv-intel PrgEnv-cray
> ftn test.f90
> ./a.out
Hello, world!
So, it is possible, although uncommon, to get this to work.
Cheers,
Bill
.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.j3-fortran.org/pipermail/j3/attachments/20170306/6f200f78/attachment.html
More information about the J3
mailing list