(j3.2006) (SC22WG5.4797) Fwd: Fourth WG5 ballot on interpretations

Bill Long longb
Mon Sep 24 18:18:40 EDT 2012


Sorry, should have been sent to the WG5 list, not J3.

Cheers,
Bill


-------- Original Message --------
Subject: Re: (j3.2006) (SC22WG5.4752) Fourth WG5 ballot on interpretations
Date: Mon, 24 Sep 2012 17:17:22 -0500
From: Bill Long <longb at cray.com>
Reply-To: <longb at cray.com>
Organization: Cray Inc.
To: fortran standards email list for J3 <j3 at mailman.j3-fortran.org>



On 9/2/12 11:08 AM, John Reid wrote:
> WG5,
>
> Here is
>
> N1934 WG5 letter ballot 4 on Fortran 2008 interpretations.
>
> I have set the deadline as 0900 UK time on Friday, 28 September 2012.
>

The following Fortran 2008 interpretations are being balloted:

Yes  No Number     Title

-Y-  ---  F08/0043   Executing a type-bound procedure on a coindexed
                       object
-C-  ---  F08/0048   Sequence association for coarrays
-Y-  ---  F08/0054   Requirements for needing an explicit interface
-C-  ---  F08/0055   G editing for reals
-Y-  ---  F08/0056   Non-polymorphic ALLOCATE with polymorphic SOURCE=
-Y-  ---  F08/0057   Interoperability with empty types
-Y-  ---  F08/0058   ENTRY point RESULT variable
-C-  ---  F08/0059   Auto-targetting requirements
-Y-  ---  F08/0060   Procedure pointer assignment with an EXTERNAL target
-Y-  ---  F08/0061   Description of the CONTIGUOUS attribute misworded?
-Y-  ---  F08/0062   Mixing default initialization with DATA
                       initialization
-Y-  ---  F08/0063   G editing to a narrow output field
-Y-  ---  F08/0064   STATUS of GET_ENVIRONMENT_VARIABLE
-Y-  ---  F08/0065   Should certain procedures in intrinsic modules be
                       pure?
-Y-  ---  F08/0066   Are certain expressions with pointer initialization
                       constant?
-Y-  ---  F08/0067   Passing arrays of extended type objects
-C-  ---  F08/0068   Pointer association and extended type arrays
-Y-  ---  F08/0069   Which part of an effective argument becomes
                       undefined?
-Y-  ---  F08/0070   Finalization of INTENT(OUT) arguments
-C-  ---  F08/0072   Final subroutines with corank
-Y-  ---  F08/0073   Polymorphic auto-targetting


Ballot comments:

F08/0048: I think it would be clearer if the last word of the edit
were changed from "array" to "coarray".  I know that further
restriction could be deduced from 12.5.2.8p1, but why be unnecessarily
obscure?

Does the interp open the door to a whole room full of "clever
programming" opportunities? For example, you can pass a different
element on each image.  An only slightly more complicated example than
the outline in the interp is:

program test
    interface
       subroutine sub (x)
          real x(10)[*]
       end subroutine
    end interface

    real :: x(100)[*]
    integer :: ti
    ti = this_image()
    x = 666
    call sub (x(ti))
    print *, "For image ", ti, "x(1:15) = ", x(1:15)
end program test

subroutine sub(y)
real y(10)[*]

y = 999
end subroutine sub

Testing this out does lead to the expected results:

> aprun -n4 ./a.out
  For image  3 x(1:15) =  2*666.,  10*999.,  3*666.
  For image  4 x(1:15) =  3*666.,  10*999.,  2*666.
  For image  2 x(1:15) =  666.,  10*999.,  4*666.
  For image  1 x(1:15) =  10*999.,  5*666.
>

If sub contained coindexed references to y, it could get confusing
about what elements of x you are really accessing on the remote
images.  In principle this is OK, but I wanted to be sure we were all
agreeing to the same consequences for this interp.

---------

F08/0055: Particularly for an interp about G output formatting, it
would be very helpful to actually display the expected output.
[Generally, when there is example code that has output, it would be
helpful to state the correct output if the code is claimed to be
conforming.]

---------

F08/0059: The last sentence of the Answer should begin "Edits are"
instead of "An edit is". There are two edits.

---------

F08/0068: I think that the second bullets in each of the two edits is
trying to say that the dummy argument becomes associated with the part
of the actual argument (target) with the declared type of the dummy
argument.  The current "declared type part of that actual argument
(target)" could be confused to refer to the declared type of the
actual argument.

---------

F08/0072: It would be helpful to supply more explanation than just
"No." for the answer. Specification of rank is allowed for a FINAL
subroutine dummy argument. Why should corank be different?

-------------------------------------------------------
Cheers,
Bill

-- 
Bill Long                                           longb at cray.com
Fortran Technical Support    &                 voice: 651-605-9024
Bioinformatics Software Development            fax:   651-605-9142
Cray Inc./Cray Plaza, Suite 210/380 Jackson St./St. Paul, MN 55101







More information about the J3 mailing list