[MPI3 Fortran] Fortran extra_state argument to MPI attributefunctions

N.M. Maclaren nmm1 at cam.ac.uk
Thu May 28 08:39:24 CDT 2009


On May 28 2009, Bill Long wrote:
>
>If you know about so-called "Cray pointers" (more accurately, Livermore 
>pointers from LRLtran),  C_PTR is just a typealias for a typeless Cray 
>pointer  (pointer(*,*)).   In fact, that's exactly how it's defined in 
>our iso_c_binding module.  Similarly, C_LOC has the same effect as the 
>Cray (and other vendors) LOC function.   The intent of C_PTR and C_LOC 
>was to give these common extensions standardized, and hence portable, 
>names and syntax. 

Yes and no.  There are a heck of a lot of restrictions to C_PTR and C_LOC
that are intended to exclude the most problematic aspects of Cray pointers,
especially those introduced by the compilers that allowed postively C-like
use of them.  In my experience, the names and syntax didn't cause many or
serious portability problems - the semantic differences did, and how!
As usual, these showed up when porting from more extended systems to less
extended ones, and not the other way round.

So don't assume that C_PTR and C_LOC allow you to do everything that your
local Cray pointer implementation does.


Regards,
Nick Maclaren,
University of Cambridge Computing Service,
New Museums Site, Pembroke Street, Cambridge CB2 3QH, England.
Email:  nmm1 at cam.ac.uk
Tel.:  +44 1223 334761    Fax:  +44 1223 334679






More information about the mpiwg-fortran mailing list