From bleikamp@rsn.hp.com  Thu Jan 16 18:03:24 1997
Received: from hplb.hpl.hp.com (hplb.hpl.hp.com [15.255.59.2]) by dkuug.dk (8.6.12/8.6.12) with ESMTP id SAA05002 for <sc22wg5@dkuug.dk>; Thu, 16 Jan 1997 18:02:42 +0100
Received: from kiwi.rsn.hp.com by hplb.hpl.hp.com; Thu, 16 Jan 1997 17:02:28 GMT
Received: from kiwi (localhost) by kiwi.rsn.hp.com with SMTP
	(1.39.111.2/16.2) id AA240964142; Thu, 16 Jan 1997 11:02:22 -0600
Sender: bleikamp@rsn.hp.com
Message-Id: <32DE5F1D.6A88@rsn.hp.com>
Date: Thu, 16 Jan 1997 11:02:21 -0600
From: Richard Bleikamp <bleikamp@rsn.hp.com>
Organization: Hewlett Packard Company
X-Mailer: Mozilla 3.01 (X11; I; HP-UX B.10.01 9000/712)
Mime-Version: 1.0
To: "sc22wg5@dkuug.dk" <sc22wg5@dkuug.dk>
Subject: postscript version of 97-102
Content-Type: application/postscript; name="97-102.ps"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline; filename="97-102.ps"

%!PS-Adobe-3.0
%%BoundingBox: 24 24 588 768
%%Title: enscript output
%%For: Richard Bleikamp,d1w36-r,,
%%Creator: GNU enscript 1.4.0
%%CreationDate: Thu Jan 16 10:00:40 1997
%%Orientation: Portrait
%%Pages: (atend)
%%DocumentMedia: Letter 612 792 0 () ()
%%DocumentNeededResources: (atend)
%%EndComments
%%BeginProlog
%%BeginResource: procset Enscript-Prolog 1.4 0
%
% Procedures.
%

/_S {	% save current state
  /_s save def
} def
/_R {	% restore from saved state
  _s restore
} def

/S {	% showpage protecting gstate
  gsave
  showpage
  grestore
} bind def

/MF {	% fontname newfontname -> -	make a new encoded font
  /newfontname exch def
  /fontname exch def

  /fontdict fontname findfont def
  /newfont fontdict maxlength dict def

  fontdict {
    exch 
    dup /FID eq {
      % skip FID pair
      pop pop
    } {
      % copy to the new font dictionary
      exch newfont 3 1 roll put
    } ifelse
  } forall
  
  newfont /FontName newfontname put

  % insert only valid encoding vectors
  encoding_vector length 256 eq {
    newfont /Encoding encoding_vector put
  } if
  
  newfontname newfont definefont pop
} def

/M {moveto} bind def
/s {show} bind def

/Box {	% x y w h -> -			define box path
  /d_h exch def /d_w exch def /d_y exch def /d_x exch def
  d_x d_y  moveto 
  d_w 0 rlineto 
  0 d_h rlineto 
  d_w neg 0 rlineto 
  closepath
} def

% Highlight bars.
/highlight_bars {	% nlines lineheight output_y_margin gray -> -
  gsave
    setgray
    /ymarg exch def
    /lineheight exch def
    /nlines exch def

    % This 2 is just a magic number to sync highlight lines to text.
    0 d_header_y ymarg sub 2 sub translate
    
    /cw d_output_w cols div def
    /nrows d_output_h ymarg 2 mul sub lineheight div floor def

    % for each column
    0 1 cols 1 sub {
      cw mul /xp exch def

      % for each rows
      0 1 nrows 1 sub {
        /rn exch def 
        rn lineheight mul neg /yp exch def
        rn nlines idiv 2 mod 0 eq {
	  % Draw highlight bar.  4 is just a magic indentation.
	  xp 4 add yp cw 8 sub lineheight neg Box fill	  
	} if
      } for
    } for
    
  grestore
} def

% Line highlight bar.
/line_highlight {	% x y width height gray -> -
  gsave
    /gray exch def
    Box gray setgray fill
  grestore
} def

% Column separator lines.
/column_lines {
  gsave
    .1 setlinewidth
    0 d_footer_h translate
    /cw d_output_w cols div def
    1 1 cols 1 sub {
      cw mul 0 moveto
      0 d_output_h rlineto stroke
    } for
  grestore
} def

% Column borders.
/column_borders {
  gsave
    .1 setlinewidth
    0 d_footer_h moveto 
    0 d_output_h rlineto
    d_output_w 0 rlineto
    0 d_output_h neg rlineto
    closepath stroke
  grestore
} def

% Do the actual underlay drawing
/draw_underlay {
  ul_style 0 eq {
    ul_str true charpath stroke
  } { 
    ul_str show
  } ifelse
} def

% Underlay
/underlay {	% - -> -
  gsave
    0 d_page_h translate
    d_page_h neg d_page_w atan rotate

    ul_gray setgray
    ul_font setfont
    /dw d_page_h dup mul d_page_w dup mul add sqrt def
    ul_str stringwidth pop dw exch sub 2 div ul_ptsize -2 div moveto 
    draw_underlay
  grestore
} def

/user_underlay {	% - -> -
  gsave
    ul_x ul_y translate
    ul_angle rotate
    ul_gray setgray
    ul_font setfont 
    0 0 ul_ptsize 2 div sub moveto 
    draw_underlay
  grestore
} def

% Page prefeed
/page_prefeed {		% bool -> -
  statusdict /prefeed known {
    statusdict exch /prefeed exch put
  } {
    pop
  } ifelse
} def

% EPSF import.

/BeginEPSF {
  /b4_Inc_state save def    		% Save state for cleanup
  /dict_count countdictstack def	% Count objects on dict stack
  /op_count count 1 sub def		% Count objects on operand stack 
  userdict begin
  /showpage { } def
  0 setgray 0 setlinecap
  1 setlinewidth 0 setlinejoin
  10 setmiterlimit [ ] 0 setdash newpath
  /languagelevel where {
    pop languagelevel
    1 ne {
      false setstrokeadjust false setoverprint 
    } if
  } if
} bind def

/EndEPSF {
  count op_count sub { pos } repeat	% Clean up stacks
  countdictstack dict_count sub { end } repeat
  b4_Inc_state restore
} bind def

% Check PostScript language level.
/languagelevel where {
  pop /gs_languagelevel languagelevel def
} {
  /gs_languagelevel 1 def
} ifelse
%%EndResource
%%BeginResource: procset Enscript-Encoding-latin1 1.4 0
/encoding_vector [
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/space        	/exclam       	/quotedbl     	/numbersign   	
/dollar       	/percent      	/ampersand    	/quoteright   	
/parenleft    	/parenright   	/asterisk     	/plus         	
/comma        	/minus        	/period       	/slash        	
/zero         	/one          	/two          	/three        	
/four         	/five         	/six          	/seven        	
/eight        	/nine         	/colon        	/semicolon    	
/less         	/equal        	/greater      	/question     	
/at           	/A            	/B            	/C            	
/D            	/E            	/F            	/G            	
/H            	/I            	/J            	/K            	
/L            	/M            	/N            	/O            	
/P            	/Q            	/R            	/S            	
/T            	/U            	/V            	/W            	
/X            	/Y            	/Z            	/bracketleft  	
/backslash    	/bracketright 	/asciicircum  	/underscore   	
/quoteleft    	/a            	/b            	/c            	
/d            	/e            	/f            	/g            	
/h            	/i            	/j            	/k            	
/l            	/m            	/n            	/o            	
/p            	/q            	/r            	/s            	
/t            	/u            	/v            	/w            	
/x            	/y            	/z            	/braceleft    	
/bar          	/braceright   	/tilde        	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/.notdef      	/.notdef      	/.notdef      	/.notdef      	
/space        	/exclamdown   	/cent         	/sterling     	
/currency     	/yen          	/brokenbar    	/section      	
/dieresis     	/copyright    	/ordfeminine  	/guillemotleft	
/logicalnot   	/hyphen       	/registered   	/macron       	
/degree       	/plusminus    	/twosuperior  	/threesuperior	
/acute        	/mu           	/paragraph    	/bullet       	
/cedilla      	/dotlessi     	/ordmasculine 	/guillemotright	
/onequarter   	/onehalf      	/threequarters	/questiondown 	
/Agrave       	/Aacute       	/Acircumflex  	/Atilde       	
/Adieresis    	/Aring        	/AE           	/Ccedilla     	
/Egrave       	/Eacute       	/Ecircumflex  	/Edieresis    	
/Igrave       	/Iacute       	/Icircumflex  	/Idieresis    	
/Eth          	/Ntilde       	/Ograve       	/Oacute       	
/Ocircumflex  	/Otilde       	/Odieresis    	/multiply     	
/Oslash       	/Ugrave       	/Uacute       	/Ucircumflex  	
/Udieresis    	/Yacute       	/Thorn        	/germandbls   	
/agrave       	/aacute       	/acircumflex  	/atilde       	
/adieresis    	/aring        	/ae           	/ccedilla     	
/egrave       	/eacute       	/ecircumflex  	/edieresis    	
/igrave       	/iacute       	/icircumflex  	/idieresis    	
/eth          	/ntilde       	/ograve       	/oacute       	
/ocircumflex  	/otilde       	/odieresis    	/divide       	
/oslash       	/ugrave       	/uacute       	/ucircumflex  	
/udieresis    	/yacute       	/thorn        	/ydieresis    	
] def
%%EndResource
%%EndProlog
%%BeginSetup
%%IncludeResource: font Courier-Bold
%%IncludeResource: font Courier
/user_header_p false def
/HFpt 10 def
/Courier-Bold /HF-gs-font MF
/HF /HF-gs-font findfont HFpt scalefont def
/Courier /F-gs-font MF
/F-gs-font findfont 10 scalefont setfont
/#copies 1 def
/d_page_w 564 def
/d_page_h 744 def
/d_header_x 0 def
/d_header_y 744 def
/d_header_w 564 def
/d_header_h 0 def
/d_footer_x 0 def
/d_footer_y 0 def
/d_footer_w 564 def
/d_footer_h 0 def
/d_output_w 564 def
/d_output_h 744 def
/cols 1 def
%%EndSetup
%%Page: (1) 1
%%BeginPageSetup
_S
24 24 translate
/pagenum 1 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 731 M
(                                                        X3J3/97-102) s
5 720 M
(                                                      page 1 of 16) s
5 709 M
(        To: X3J3) s
5 698 M
(        From: Rich Bleikamp) s
5 687 M
(        Subject: Syntax and Edits for Async I/O ) s
5 676 M
(        Date: Jan. 15, 1997) s
5 665 M
(        ) s
5 654 M
(        \(a revision of X3J3/96-158r2\)) s
5 643 M
(        ) s
5 632 M
(        See paper X3J3/96-147r1 for the semantics previously) s
5 621 M
(        approved by X3J3 for this feature.) s
5 610 M
(        ) s
5 599 M
(        Also see the Rationale and Conceptual Model at the end of) s
5 588 M
(        this document.) s
5 577 M
(        ) s
5 566 M
(        Changes since 96-158r2 \(look for "|"s in the left margin\) :) s
5 555 M
(        ) s
5 544 M
(    |    - Added text to deal with COPYIN/COPYOUT semantics of) s
5 533 M
(    |      actual arguments passed to procedures.  We need to) s
5 522 M
(    |      prohibit copyin/copyout in some situations, to) s
5 511 M
(    |      avoid clobbering I/O list items being read into) s
5 500 M
(    |      by an asynchronous read.) s
5 489 M
(    |   ) s
5 478 M
(    |      I had several choices:) s
5 467 M
(    |   ) s
5 456 M
(    |        - disallow copyin/copyout as an argument passing) s
5 445 M
(    |          mechanism, at least some of the time.) s
5 434 M
(    |          Rejected: too big a change for async i/o) s
5 423 M
(    |   ) s
5 412 M
(    |        - disallow some obvious "triggers" for copyin/out,) s
5 401 M
(    |          but leave some behavior processor dependent.) s
5 390 M
(    |          Rejected: would work most of the time, for most) s
5 379 M
(    |          users, but isn't truly portable.) s
5 368 M
(    |   ) s
5 357 M
(    |        - Restrict how list items \(with active async I/O pending\)) s
5 346 M
(    |          can be passed as an actual argument.) s
5 335 M
(    |          I chose this approach.  See the last set of edits) s
5 324 M
(    |          for the new section 9.4.1.10.) s
_R
S
%%Page: (2) 2
%%BeginPageSetup
_S
24 24 translate
/pagenum 2 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 2 of 16) s
5 698 M
(    |   ) s
5 687 M
(    |    - Required the ASYNCHRONOUS attribute to be present in) s
5 676 M
(    |      all scoping units where an I/O list item that is) s
5 665 M
(    |      undergoing asynchronous I/O may be referenced or defined.) s
5 654 M
(    |      Even if the reference/definition is before the I/O) s
5 643 M
(    |      statement or after the WAIT operation.) s
5 632 M
(    |      This issue was discovered by Larry Meadows during an) s
5 621 M
(    |      HPF meeting where a subset of X3J3's async I/O proposal) s
5 610 M
(    |      was adopted \(more or less\) for a future HPF revision.) s
5 599 M
(    |      See edits for 5.1.2.12.) s
5 588 M
(    |   ) s
5 577 M
(    |      This change is required to prevent the optimizer from) s
5 566 M
(    |      moving references to such variables, when neither) s
5 555 M
(    |      the async READ/WRITE nor the corresponding CLOSE) s
5 544 M
(    |      statement are in scope.  For example:) s
5 533 M
(    |   ) s
5 522 M
(    |          INTEGER :: x      ! local variable X) s
5 511 M
(    |          READ \(1,ASYNCHRONOUS, ...\) x) s
5 500 M
(    |          call foo \(x\)) s
5 489 M
(    |          RETURN) s
5 478 M
(    |          END) s
5 467 M
(    |   ) s
5 456 M
(    |          SUBROUTINE foo \(x\)) s
5 445 M
(    |          INTEGER :: x     ! we need an ASYNCHRONOUS) s
5 434 M
(    |                           ! attribute here!) s
5 423 M
(    |   ) s
5 412 M
(    |          CALL who         ! WHO does a WAIT) s
5 401 M
(    |   ) s
5 390 M
(    |          a = x            ! optimizer may want to hoist) s
5 379 M
(    |                           ! a=x above the "CALL who",) s
5 368 M
(    |                           ! since there is no apparent) s
5 357 M
(    |                           ! reference to "x" in who.) s
5 346 M
(    |          END) s
5 335 M
(    |   ) s
5 324 M
(    |          SUBROUTINE who) s
5 313 M
(    |          WAIT\(1,...\)) s
5 302 M
(    |          RETURN) s
5 291 M
(    |          END) s
5 280 M
(        ) s
5 269 M
(        Changes since 96-158r1:) s
5 258 M
(        ) s
5 247 M
(          - Added an ASYNCHRONOUS statement  \(per the straw vote\).) s
5 236 M
(        ) s
5 225 M
(          - changed ASYNC to ASYNCHRONOUS \(attribute name,) s
5 214 M
(            specifier name\)) s
5 203 M
(        ) s
5 192 M
(          - fixed 9.6.1.14: sort of, the phrase is still awkward.) s
5 181 M
(        ) s
5 170 M
(          - added a conceptual model after the rationale.) s
5 159 M
(        ) s
5 148 M
(          - fixed NAMELIST, so only those variables affected by) s
5 137 M
(            the namelist I/O are restricted like other list items.) s
_R
S
%%Page: (3) 3
%%BeginPageSetup
_S
24 24 translate
/pagenum 3 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 3 of 16) s
5 698 M
(          - Added a paragraph about implied-do-variables) s
5 687 M
(            becoming undefined, in data transfer statements.) s
5 676 M
(            This will prohibit the user from examining said variables,) s
5 665 M
(            until the corresponding WAIT operation is performed.) s
5 654 M
(        ) s
5 643 M
(          - functions referenced in item lists in async data) s
5 632 M
(            transfer statements shall be PURE.) s
5 621 M
(        ) s
5 610 M
(          - I addressed the issue of PRIVATE components needing) s
5 599 M
(            the ASYNCHRONOUS attribute by adding the text) s
5 588 M
(            ", or shall be a subobject  of an object with the) s
5 577 M
(            ASYNCHRONOUS attribute" wherever we required a) s
5 566 M
(            variable to have that attribute.  I considered) s
5 555 M
(            interp 140 \(not approved yet\) in this context.  The) s
5 544 M
(            alternative is to change 6.1.2, where components) s
5 533 M
(            inherit some attributes from their parent object.) s
5 522 M
(          ) s
5 511 M
(        ) s
5 500 M
(        Unresolved Issues) s
5 489 M
(        ) s
5 478 M
(          - We have not decided if ID= variables should be of) s
5 467 M
(            some type other than default integer \(either pointer,) s
5 456 M
(            a new intrinsic type, or an implicitly defined derived) s
5 445 M
(            type\).  This request came from Robert Corbett of Sun.) s
5 434 M
(            This might simplify the implementation in the runtime) s
5 423 M
(            library of keeping track of pending I/O operations.) s
5 412 M
(        ) s
5 390 M
(        Resolved issues with no action taken:) s
5 379 M
(        ) s
5 368 M
(          - I've looked at the restrictions on namelist-group-) s
5 357 M
(            objects not being pointers, and it is similar to) s
5 346 M
(            other restrictions, namely, only arrays with constant) s
5 335 M
(            bounds are permissible.  So i've decided not to do) s
5 324 M
(            anything about this.  It is unrelated to ASYNC i/o.) s
5 313 M
(          ) s
5 302 M
(          ) s
5 291 M
(        "Notes to the reader"  are not notes to be included in the) s
5 280 M
(        standard.  Text to be included in the standard is either) s
5 269 M
(        "quoted" or indented.) s
5 258 M
(        ) s
5 247 M
(        Edits to 96-007R1:) s
5 236 M
(        ) s
5 225 M
(        In rule R426 \(component-attr-spec\), add:) s
5 214 M
(          or  ASYNCHRONOUS) s
5 203 M
(        ) s
5 192 M
(        In rule R503 \(attr-spec\), add:) s
5 181 M
(          or  ASYNCHRONOUS) s
5 170 M
(        ) s
_R
S
%%Page: (4) 4
%%BeginPageSetup
_S
24 24 translate
/pagenum 4 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 4 of 16) s
5 698 M
(        and add a new section \(page 57\):) s
5 687 M
(    |    5.1.2.12    ASYNCHRONOUS attribute) s
5 676 M
(    |   ) s
5 665 M
(    |    The ASYNCHRONOUS attribute may be specified for any) s
5 654 M
(    |    variable, in any scoping unit.) s
5 643 M
(    |   ) s
5 632 M
(    |    A variables that :) s
5 621 M
(    |   ) s
5 610 M
(    |      1\) is used in an asynchronous data transfer statement) s
5 599 M
(    |         input/output list, or) s
5 588 M
(    |   ) s
5 577 M
(    |      2\) is in a namelist group that is used in an) s
5 566 M
(    |         asynchronous data transfer statement, and is) s
5 555 M
(    |         actually read or written by that data transfer) s
5 544 M
(    |         statement, or) s
5 533 M
(    |   ) s
5 522 M
(    |      3\) is specified in a SIZE= specifier in an) s
5 511 M
(    |         asynchronous data transfer statement) s
5 500 M
(    |   ) s
5 489 M
(    |    shall have the ASYNCHRONOUS attribute,) s
5 478 M
(    |    or be a subobject of an object with the ASYNCHRONOUS) s
5 467 M
(    |    attribute, if :) s
5 456 M
(    |   ) s
5 445 M
(    |      1\) that variable is referenced, defined, or used as) s
5 434 M
(    |         an actual argument in a scoping unit other than the) s
5 423 M
(    |         scoping unit containing the asynchronous) s
5 412 M
(    |         data transfer statement, and) s
5 401 M
(    |   ) s
5 390 M
(    |      2\) any executable statement in such a scoping unit) s
5 379 M
(    |         might be executed while the asynchronous) s
5 368 M
(    |         data transfer operation is pending.) s
5 357 M
(    |   ) s
5 346 M
(        ) s
5 335 M
(          Note: A pending data transfer operation exists when a) s
5 324 M
(          READ or WRITE statement with the ASYNCHRONOUS) s
5 313 M
(          specifier is executed, but the corresponding wait) s
5 302 M
(          operation has not yet been executed.) s
5 291 M
(        ) s
5 280 M
(          ) s
5 269 M
(        Note to reader: we allow any variable to have the) s
5 258 M
(        asynchronous attribute so users can remove ASYNCHRONOUS) s
5 247 M
(        specifiers from data transfer statements without having to) s
5 236 M
(        delete the ASYNCHRONOUS attribute.) s
5 225 M
(          ) s
5 214 M
(          Note: The ASYNCHRONOUS attribute is similar to the) s
5 203 M
(          VOLATILE attribute provided by some processors, and is) s
5 192 M
(          intended to facilitate traditional code motion) s
5 181 M
(          optimizations in the presence of asynchronous input /) s
5 170 M
(          output.  Variables in asynchronous input / output lists) s
5 159 M
(          implicitly have the ASYNCHRONOUS attribute in the) s
5 148 M
(          scoping unit of that asynchronous READ or WRITE) s
5 137 M
(          statement, but shall have the ASYNCHRONOUS attribute in) s
5 126 M
(    |     other scoping units when those variables are referenced,) s
5 115 M
(    |     defined, or otherwise used in a scoping unit, and ANY) s
5 104 M
(    |     executable statements in that scoping unit might be) s
5 93 M
(    |     executed while the asynchrounous I/O is pending.) s
5 82 M
(          -- End Note) s
_R
S
%%Page: (5) 5
%%BeginPageSetup
_S
24 24 translate
/pagenum 5 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 5 of 16) s
5 698 M
(          ) s
5 687 M
(        Add a new section, 9.2.10 \(and renumber 9.2.10 and later) s
5 676 M
(        sections\):) s
5 665 M
(        ) s
5 654 M
(          9.2.10  ASYNCHRONOUS  statement) s
5 643 M
(          ) s
5 632 M
(          R5xx      is  ASYNCHRONOUS  [::]  <object-name-list>) s
5 621 M
(          ) s
5 610 M
(          The ASYNCHRONOUS statement specifes the ASYNCHRONOUS) s
5 599 M
(          attribute for a list of objects.) s
5 588 M
(          ) s
5 577 M
(        In rule R905 \(OPEN statement connect-spec\), add, after PAD=) s
5 566 M
(        \(on its own line\)\(pg. 140\):) s
5 555 M
(          or  ASYNCHRONOUS) s
5 544 M
(        ) s
5 533 M
(        Add section 9.3.4.11 \(page 142/143\):) s
5 522 M
(        ) s
5 511 M
(          9.3.4.11  ASYNCHRONOUS specifier in the OPEN statement) s
5 500 M
(        ) s
5 489 M
(          If the ASYNCHRONOUS specifier is specified for a unit) s
5 478 M
(          in an OPEN statement, then READ and WRITE statements) s
5 467 M
(          for that unit may include the ASYNCHRONOUS specifier) s
5 456 M
(          in the control information list.) s
5 445 M
(        ) s
5 434 M
(          The presence of an ASYNCHRONOUS specifier in a READ or) s
5 423 M
(          WRITE statement permits, but does not require, a) s
5 412 M
(          processor to perform the data transfer asynchronously.) s
5 401 M
(          The WAIT, CLOSE, and file positioning statements may be) s
5 390 M
(          used to wait for asynchronous data transfer operations) s
5 379 M
(          to complete, and the INQUIRE statement may be used to) s
5 368 M
(          inquire whether or not asynchronous data transfer) s
5 357 M
(          operations have completed.) s
5 346 M
(        ) s
5 335 M
(        Note to the reader: the above rules imply only external unit) s
5 324 M
(        input / output may specify an ASYNCHRONOUS specifier for) s
5 313 M
(        READs and WRITEs, since internal files are not OPENed.) s
5 302 M
(        ) s
5 291 M
(        In section 9.3.5 \(CLOSE statement\), page 143, add the) s
5 280 M
(        following paragraph and) s
5 269 M
(        notes after line 5:) s
5 258 M
(        ) s
5 247 M
(          Execution of a CLOSE statement causes the processor to) s
5 236 M
(          wait for all pending data transfer operations for the) s
5 225 M
(          specified unit to complete.) s
5 214 M
(        ) s
5 203 M
(          If a CLOSE statement is executed for a unit with) s
5 192 M
(          pending data transfer operations, that CLOSE statement) s
5 181 M
(          is considered to be the corresponding wait operation) s
5 170 M
(          for the READ or WRITE statements that initiated those) s
5 159 M
(          pending data transfer operations, and the CLOSE) s
5 148 M
(          statement is considered to be a data transfer statement) s
5 137 M
(          for purposes of end of file, end of record, and error) s
5 126 M
(          processing.) s
5 115 M
(        ) s
_R
S
%%Page: (6) 6
%%BeginPageSetup
_S
24 24 translate
/pagenum 6 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 6 of 16) s
5 698 M
(    |   ) s
5 687 M
(    |Deleted a big paragraph that discussed when a variable) s
5 676 M
(    |needed the asynchronous attribute.) s
5 665 M
(    |    ) s
5 654 M
(        ) s
5 643 M
(        In rule 912 \(io-control-spec\) \(page 144\), add:) s
5 632 M
(        ) s
5 621 M
(          or  ASYNCHRONOUS) s
5 610 M
(          or  ID = <scalar-default-int-variable>) s
5 599 M
(        ) s
5 588 M
(        Add the following constraint after the constraint on line) s
5 577 M
(        19, page 145:) s
5 566 M
(        ) s
5 555 M
(          Constraint: An ASYNCHRONOUS specifier shall be present) s
5 544 M
(          if an ID= specifier is present.) s
5 533 M
(          ) s
5 522 M
(          Constraint: An ASYNCHRONOUS specifier shall not be) s
5 511 M
(          specified if the <io-unit> is an <internal-file-unit>.) s
5 500 M
(        ) s
5 489 M
(        Note to the reader: the first constraint implies an ID=) s
5 478 M
(        specifier, typically used in a corresponding WAIT statement,) s
5 467 M
(        is NOT required in an asynchronous READ or WRITE statement.) s
5 456 M
(        The user would have to CLOSE the unit \(or execute another) s
5 445 M
(        wait operation\) before referencing any storage locations in) s
5 434 M
(        an input list or namelist, and to NOT define any storage) s
5 423 M
(        locations referenced by an output list or namelist in an) s
5 412 M
(        output statement.  This allows a knowledgeable user to) s
5 401 M
(        READ or WRITE massive amounts of data to a file, without) s
5 390 M
(        ever waiting for completion, as long as they close the file) s
5 379 M
(        or perform some other wait operation before modifying or) s
5 368 M
(        referencing any storage locations referenced by an) s
5 357 M
(        input / output list or namelist.) s
5 346 M
(        ) s
5 335 M
(        In section 9.4.1.9 \(page 147\), first sentence, insert) s
5 324 M
(        ) s
5 313 M
(          without an ASYNCHRONOUS specifier) s
5 302 M
(        ) s
5 291 M
(        before "terminates", and add the following as the last) s
5 280 M
(        sentence of that paragraph:) s
5 269 M
(        ) s
5 258 M
(          If an ASYNCHRONOUS specifier is present, the variable) s
5 247 M
(          specified in the SIZE= specifier, if any, will become) s
5 236 M
(          defined, with the value described above, when the wait) s
5 225 M
(          operation corresponding to the non-advancing input) s
5 214 M
(          statement is executed.) s
5 203 M
(        ) s
5 192 M
(          Note: A CLOSE, INQUIRE or a file positioning statement,) s
5 181 M
(          as well as a WAIT statement, can be a wait operation) s
5 170 M
(          \(9.3.5\).) s
5 159 M
(        ) s
_R
S
%%Page: (7) 7
%%BeginPageSetup
_S
24 24 translate
/pagenum 7 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 7 of 16) s
5 698 M
(        Insert a new section:) s
5 687 M
(        ) s
5 676 M
(          9.4.1.10  Asynchronous specifier) s
5 665 M
(          ) s
5 654 M
(          The ASYNCHRONOUS specifier indicates that this data) s
5 643 M
(          transfer operation can be performed asynchronously.) s
5 632 M
(          Records read or written by asynchronous data transfer) s
5 621 M
(          statements will be read, written, and processed in the) s
5 610 M
(          same order as they would have been if the data transfer) s
5 599 M
(          statement did not contain the ASYNCHRONOUS specifier.) s
5 588 M
(          ) s
5 577 M
(          The ASYNCHRONOUS specifier shall not be present in a) s
5 566 M
(          READ or WRITE statement unless the OPEN statement for) s
5 555 M
(          the unit referenced in the READ or WRITE statement) s
5 544 M
(          contained an ASYNCHRONOUS specifier.) s
5 533 M
(          ) s
5 522 M
(          When a data transfer statement with the ASYNCHRONOUS) s
5 511 M
(          specifier is executed, the program shall not execute) s
5 500 M
(          any statements that would cause any variable in the) s
5 489 M
(          input / output list, namelist, any do-variable in the) s
5 478 M
(          item list, or the variable specified in a SIZE=) s
5 467 M
(          specifier to become undefined as described in 14.7.6,) s
5 456 M
(          until the corresponding wait operation is performed.) s
5 445 M
(          When a namelist group name is specified in data transfer) s
5 434 M
(          statement with the ASYNCHRONOUS specifier, any) s
5 423 M
(          variables in the namelist group that are not actually) s
5 412 M
(          read or written by the data transfer statement are not) s
5 401 M
(          subject to the restrictions described in this) s
5 390 M
(          paragraph.) s
5 379 M
(          ) s
5 368 M
(          When a data transfer statement with the ASYNCHRONOUS) s
5 357 M
(          specifier is executed, the program shall not execute) s
5 346 M
(          any statements that would cause the pointer) s
5 335 M
(          association status of any variable in the input /) s
5 324 M
(          output list, namelist, any do-variable in the item) s
5 313 M
(          list, or a variable specified in the SIZE= specifier to) s
5 302 M
(          change, or would cause any such variable to become) s
5 291 M
(          associated with a different target, as described in) s
5 280 M
(          14.6.2, until the corresponding wait operation is) s
5 269 M
(          performed.  When a namelist group name is specified in) s
5 258 M
(          a data transfer statement, variables in the namelist) s
5 247 M
(          group not actually read or written by the data transfer) s
5 236 M
(          statement are not subject to the restrictions) s
5 225 M
(          described in this paragraph.) s
5 214 M
(          ) s
5 203 M
(          Note: These last two restrictions ensure that certain) s
5 192 M
(          variables referenced in asynchronous data transfer) s
5 181 M
(          statements must still exist and reference the same) s
5 170 M
(          storage locations when the corresponding wait operation) s
5 159 M
(          is performed, including the implicit CLOSE for open) s
5 148 M
(          units when a program is exiting.) s
5 137 M
(        ) s
_R
S
%%Page: (8) 8
%%BeginPageSetup
_S
24 24 translate
/pagenum 8 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 8 of 16) s
5 698 M
(        ) s
5 687 M
(          When an input data transfer statement with the) s
5 676 M
(          ASYNCHRONOUS specifier is executed, the input list or) s
5 665 M
(          namelist items, any implied-do-variables, and the) s
5 654 M
(          variable specified in the SIZE= specifier, if any,) s
5 643 M
(          become undefined until the corresponding wait operation) s
5 632 M
(          is executed \(9.3.5, 9.5\).  When a namelist group name) s
5 621 M
(          is specified in a data transfer statement, variables) s
5 610 M
(          in the namelist group not actually read by the data transfer) s
5 599 M
(          statement do not become undefined.) s
5 588 M
(        ) s
5 577 M
(          When an output data transfer statement with the) s
5 566 M
(          ASYNCHRONOUS specifier is executed, the output list or) s
5 555 M
(          namelist items, and any implied-do-variables in the) s
5 544 M
(          item list, shall not be redefined until the) s
5 533 M
(          corresponding wait operation is executed \(9.3.5, 9.5\).) s
5 522 M
(          When a namelist group name is specified in such an) s
5 511 M
(          data transfer statement, variables in the namelist) s
5 500 M
(          group not actually written by the data transfer) s
5 489 M
(          statement may be redefined before the corresponding) s
5 478 M
(          wait operation.) s
5 467 M
(          ) s
5 456 M
(          When an output data transfer statement with the) s
5 445 M
(          ASYNCHRONOUS specifier is executed, any implied-do-) s
5 434 M
(          variables in the item list become undefined until the) s
5 423 M
(          corresponding wait operation is performed, at which) s
5 412 M
(          time it becomes defined with the value it would have) s
5 401 M
(          at the end of execution of the original READ or WRITE) s
5 390 M
(          statement if that statement had not specified the) s
5 379 M
(          ASYNCHRONOUS specifier.) s
5 368 M
(          ) s
5 357 M
(          When a data transfer statement with the ASYNCHRONOUS) s
5 346 M
(          specifier is executed, all functions referenced in the) s
5 335 M
(          item list shall be pure functions.) s
5 324 M
(        ) s
5 313 M
(          Note: This restriction on functions appearing in item) s
5 302 M
(          lists for asynchronous data transfer statements applies) s
5 291 M
(          to all function references, including those used in) s
5 280 M
(          subscript, substring, and implied do loop calculations.) s
5 269 M
(          End Note) s
5 258 M
(        ) s
_R
S
%%Page: (9) 9
%%BeginPageSetup
_S
24 24 translate
/pagenum 9 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 9 of 16) s
5 698 M
(        ) s
5 687 M
(    |   ) s
5 676 M
(    |    When a READ statement with the ASYNCHRONOUS) s
5 665 M
(    |    specifier is executed, the program shall not execute) s
5 654 M
(    |    any procedure call where any variable :) s
5 643 M
(        ) s
5 632 M
(    |      1\) in the input / output list or namelist,) s
5 621 M
(    |      2\) which is a do-variable in the item list, or) s
5 610 M
(    |      3\) specified in a SIZE= specifier,) s
5 599 M
(    |   ) s
5 588 M
(    |    or subobject or parent object thereof, is passed as an) s
5 577 M
(    |    actual argument, until the corresponding wait operation) s
5 566 M
(    |    is executed, unless :) s
5 555 M
(    |   ) s
5 544 M
(    |      1\) the actual argument passed does not include any storage) s
5 533 M
(    |         location defined or referenced by the data transfer) s
5 522 M
(    |         statement, or) s
5 511 M
(    |   ) s
5 500 M
(    |      2\) the corresponding dummy argument is an assumed) s
5 489 M
(    |         shape array) s
5 478 M
(    |   ) s
5 467 M
(    |     Note: This restriction prevents interactions between) s
5 456 M
(    |           actual arguments passed with so-called) s
5 445 M
(    |           copyin/copyout semantics and asynchronous I/O.) s
5 434 M
(    |   ) s
5 423 M
(        Question:  Should we allow scalars?  Can they be passed) s
5 412 M
(        by copyin/out?  Any other ways to force pass by address) s
5 401 M
(        or descriptor?) s
5 390 M
(        ) s
5 379 M
(        Insert a new section 9.4.1.11:) s
5 368 M
(        ) s
5 357 M
(          9.4.1.11  ID= specifier) s
5 346 M
(        ) s
5 335 M
(          The ID= specifier identifies a variable that is) s
5 324 M
(          assigned a processor dependent value during the) s
5 313 M
(          execution of an asynchronous data transfer statement.) s
5 302 M
(          This value can be used in a WAIT statement to force) s
5 291 M
(          the processor to wait for a particular data transfer) s
5 280 M
(          operation to complete.) s
5 269 M
(        ) s
5 258 M
(        In section 9.4.4, list item \(5\), change "namelist" to) s
5 247 M
(        ) s
5 236 M
(          namelist, except that if the ASYNCHRONOUS= specifier) s
5 225 M
(          was also present, the entities specified in the) s
5 214 M
(          input/output list or namelist become undefined) s
5 203 M
(        ) s
5 192 M
(        In section 9.4.4, list item \(8\), change "defined" to) s
5 181 M
(        ) s
5 170 M
(          defined, except that a variable specified in a SIZE=) s
5 159 M
(          specifier becomes undefined if an ASYNCHRONOUS) s
5 148 M
(          specifier was also specified) s
5 137 M
(        ) s
_R
S
%%Page: (10) 10
%%BeginPageSetup
_S
24 24 translate
/pagenum 10 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 10 of 16) s
5 698 M
(        In section 9.4.4.4, page 152, before the paragraph that) s
5 687 M
(        starts "On output ...", insert the following paragraphs:) s
5 676 M
(        ) s
5 665 M
(          If an ASYNCHRONOUS specifier is specified in a data) s
5 654 M
(          transfer statement, the actual list processing and data) s
5 643 M
(          transfers may occur during execution of the input) s
5 632 M
(          statement, during execution of the corresponding wait) s
5 621 M
(          operation, or anywhere in-between.  The data transfer) s
5 610 M
(          operation is considered to be a pending data transfer) s
5 599 M
(          operation until a corresponding wait operation is) s
5 588 M
(          performed.) s
5 577 M
(        ) s
5 566 M
(          If an ASYNCHRONOUS specifier is specified on an input) s
5 555 M
(          statement, the list items or namelist variables, any do-) s
5 544 M
(          variable in the item list, and the variable specified) s
5 533 M
(          in the SIZE= specifier, if any, become undefined until) s
5 522 M
(          the corresponding wait operation is executed \(9.3.5,) s
5 511 M
(          9.5\).  When a namelist group name is specified in a) s
5 500 M
(          data transfer statement, variables in the namelist) s
5 489 M
(          group not actually read by the input statement do not) s
5 478 M
(          become undefined.) s
5 467 M
(          ) s
5 456 M
(          If an ASYNCHRONOUS specifier is specified on an output) s
5 445 M
(          statement, the list items or namelist variables, and) s
5 434 M
(          any do-variable in the item list shall not be redefined) s
5 423 M
(          until the corresponding wait operation is executed) s
5 412 M
(          \(9.3.5, 9.5\).  When a namelist group name is specified) s
5 401 M
(          in an output statement, variables in the namelist) s
5 390 M
(          group not actually written by the data transfer) s
5 379 M
(          statement are not subject to the restrictions described) s
5 368 M
(          in this paragraph.) s
5 357 M
(          ) s
5 346 M
(          When a data transfer operation is performed) s
5 335 M
(          asynchronously, any errors that would have caused the) s
5 324 M
(          ERR= branch on a non-asynchronous READ or WRITE to be) s
5 313 M
(          taken, and the IOSTAT variable to be defined with a non-) s
5 302 M
(          zero value, may instead occur during execution of the) s
5 291 M
(          corresponding wait operation \(a WAIT, CLOSE, INQUIRE) s
5 280 M
(          or file positioning statement\) and take the ERR= branch) s
5 269 M
(          of that wait operation instead.  If an ID= specifier is) s
5 258 M
(          not present in the initiating READ or WRITE statement,) s
5 247 M
(          the errors may occur during the execution of any) s
5 236 M
(          subsequent data transfer statement for that same unit,) s
5 225 M
(          and not just during the corresponding wait operation.) s
5 214 M
(        ) s
_R
S
%%Page: (11) 11
%%BeginPageSetup
_S
24 24 translate
/pagenum 11 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 11 of 16) s
5 698 M
(        Insert a new section 9.5, and renumber every section) s
5 687 M
(        thereafter appropriately:) s
5 676 M
(          ) s
5 665 M
(          9.5  WAIT statement) s
5 654 M
(          ) s
5 643 M
(          Execution of a WAIT statement causes the processor to) s
5 632 M
(          wait for one of more previously initiated \(pending\)) s
5 621 M
(          asynchronous data transfers to complete.) s
5 610 M
(          ) s
5 599 M
(              R919  <wait-statement> is  WAIT \(<wait-spec-list>\)) s
5 588 M
(          ) s
5 577 M
(              R920  <wait-spec>      is  [UNIT = ]) s
5 566 M
(                                              <external-file-unit>) s
5 555 M
(                              or  IOSTAT =) s
5 544 M
(                                     <scalar-default-int-variable>) s
5 533 M
(                              or  ERR = <label>) s
5 522 M
(                              or  ID =) s
5 511 M
(                                     <scalar-default-int-variable>) s
5 500 M
(                              or  END = <label>) s
5 489 M
(        ) s
5 478 M
(          Constraint: A <wait-spec-list> shall contain exactly one) s
5 467 M
(          <external-file-unit> specifier, and may contain at most) s
5 456 M
(          one of each of the other specifiers.) s
5 445 M
(          ) s
5 434 M
(          Constraint: If the optional characters UNIT= are) s
5 423 M
(          omitted from the unit specifier, the unit specifier) s
5 412 M
(          shall be the first item in the <wait-spec-list>.) s
5 401 M
(        ) s
5 390 M
(        ) s
5 379 M
(            \(note to Richard Maine: insert other appropriate) s
5 368 M
(             constraints, similar to the position-spec constraints,) s
5 357 M
(             and one for the END=label branch target\)) s
5 346 M
(        ) s
5 335 M
(          The IOSTAT=, ERR=, and END= specifiers are described in) s
5 324 M
(          x, x, and x respectively.) s
5 313 M
(        ) s
5 302 M
(          If an ID= specifier is not present, the processor waits) s
5 291 M
(          for all pending data transfers on the specified unit to) s
5 280 M
(          complete, if any.  If an ID= specifier is present, the) s
5 269 M
(          processor waits for the corresponding READ or WRITE) s
5 258 M
(          operation to complete.  The corresponding READ or WRITE) s
5 247 M
(          operation is that READ or WRITE that returned the same) s
5 236 M
(          value for the ID= specifier for the specified unit.) s
5 225 M
(          The value specified for the ID= specifier shall be a) s
5 214 M
(          value returned by a READ or WRITE statement for the) s
5 203 M
(          specified unit, for which a corresponding wait) s
5 192 M
(          operation has not been executed.) s
5 181 M
(        ) s
5 170 M
(          The data transfer operation specified in the) s
5 159 M
(          corresponding READ or WRITE statement may happen when) s
5 148 M
(          the WAIT statement is executed, when the corresponding) s
5 137 M
(          READ or WRITE statement was previously executed, or) s
5 126 M
(          anytime in-between.  The WAIT statement is considered) s
5 115 M
(          to be a data transfer statement for purposes of end of) s
5 104 M
(          file, end of record, and error processing.) s
5 93 M
(        ) s
_R
S
%%Page: (12) 12
%%BeginPageSetup
_S
24 24 translate
/pagenum 12 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 12 of 16) s
5 698 M
(    |   ) s
5 687 M
(    |Deleted a big paragraph that discussed when a variable) s
5 676 M
(    |needed the asynchronous attribute.) s
5 665 M
(    |    ) s
5 654 M
(          ) s
5 643 M
(          Note: The CLOSE , INQUIRE, and file positioning) s
5 632 M
(          statements, as well as the WAIT statement, can be a) s
5 621 M
(          "wait" operation.) s
5 610 M
(          ) s
5 599 M
(          Note: If an asynchronous READ attempts to read beyond) s
5 588 M
(          the end of a file, then the end of file condition may) s
5 577 M
(          occur either during execution of the READ statement or) s
5 566 M
(          during execution of the corresponding wait operation.) s
5 555 M
(          If the end of file condition occurs during the wait) s
5 544 M
(          operation, and there is not an END= or IOSTAT specifier) s
5 533 M
(          in the statement that is the corresponding wait) s
5 522 M
(          operation, then program execution terminates.  Error) s
5 511 M
(          conditions are handled in a similar manner.) s
5 500 M
(          ) s
5 489 M
(        and renumber all subsequent rules.  ) s
5 478 M
(        ) s
5 467 M
(        In the old section 9.5 \(File Positioning statements\), add) s
5 456 M
(        the following after the last sentence in that section:) s
5 445 M
(        ) s
5 434 M
(          Execution of a file positioning statement causes the) s
5 423 M
(          processor to wait for all pending data transfer) s
5 412 M
(          operations for the specified unit to complete.) s
5 401 M
(          ) s
5 390 M
(          If a file positioning statement is executed for a unit) s
5 379 M
(          with pending data transfer operations, that statement) s
5 368 M
(          is considered to be the corresponding wait operation) s
5 357 M
(          for the READ or WRITE statements that initiated the) s
5 346 M
(          pending data transfers, and is also considered to be an) s
5 335 M
(          data transfer statement for purposes of end of file,) s
5 324 M
(          error, and end of record processing.) s
5 313 M
(          ) s
5 302 M
(    |   ) s
5 291 M
(    |Deleted a big paragraph that discussed when a variable) s
5 280 M
(    |needed the asynchronous attribute.) s
5 269 M
(    |    ) s
5 258 M
(          ) s
5 247 M
(        In section 9.6.1, add the following to rule 924:) s
5 236 M
(          or  ID = <scalar-default-int-variable>) s
5 225 M
(          or  PENDING = <scalar-default-logical-variable>) s
5 214 M
(        ) s
5 203 M
(        and add these constraints around line 40 on page 156:) s
5 192 M
(          Constraint: The ID= and PENDING= specifiers shall not) s
5 181 M
(          appear in an INQUIRE statement if the FILE = specifier) s
5 170 M
(          is present.) s
5 159 M
(          ) s
5 148 M
(          Constraint: If an ID= specifier is present, a PENDING=) s
5 137 M
(          specifier shall also be present.) s
5 126 M
(          ) s
_R
S
%%Page: (13) 13
%%BeginPageSetup
_S
24 24 translate
/pagenum 13 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 13 of 16) s
5 698 M
(        ) s
5 687 M
(        On page 159, add section 9.6.1.23) s
5 676 M
(          9.6.1.23    ID= and PENDING= specifiers in the INQUIRE) s
5 665 M
(                      statement) s
5 654 M
(          If an ID= specifier is not present in an INQUIRE) s
5 643 M
(          statement, the variable specified in the PENDING=) s
5 632 M
(          specifier is assigned the value true if there are any) s
5 621 M
(          pending asynchronous data transfers for the specified) s
5 610 M
(          unit that have not completed.  If an ID= specifier is) s
5 599 M
(          present, the variable specified in the PENDING=) s
5 588 M
(          specifier is assigned the value true if the data) s
5 577 M
(          transfer identified by the ID= specifier for the) s
5 566 M
(          specified unit has not yet completed.  In all other) s
5 555 M
(          cases, the variable specified in the PENDING= specifier) s
5 544 M
(          is set to false.) s
5 533 M
(          ) s
5 522 M
(          When the variable specified in the PENDING= specifier is) s
5 511 M
(          set to false, then any pending data transfer operations) s
5 500 M
(          for this unit are considered to have completed, and) s
5 489 M
(          this INQUIRE is the corresponding wait operation for) s
5 478 M
(          the corresponding READ or WRITE statements.  When an) s
5 467 M
(          ID= specifier is present, the corresponding operation) s
5 456 M
(          is the READ or WRITE statement identified by the unit) s
5 445 M
(          and ID= specifier value.  When an ID= specifier was not) s
5 434 M
(          present, then this INQUIRE statement is the) s
5 423 M
(          corresponding wait operation for all pending data) s
5 412 M
(          transfer operations for the specified unit.  When an INQUIRE) s
5 401 M
(          statement is considered to be a wait operation, it is also) s
5 390 M
(          considered to be a data transfer statement for purposes) s
5 379 M
(          of end of file, end of record, and error processing.) s
5 368 M
(        ) s
5 357 M
(        In section 9.6.1.14, add the following sentence as the last) s
5 346 M
(        sentence of the paragraph.) s
5 335 M
(          If there are pending data transfer operations for the) s
5 324 M
(          specified unit, the value assigned to the variable specified) s
5 313 M
(          in a NEXTREC= specifier is computed as if all the pending) s
5 302 M
(          data transfers had already completed.) s
5 291 M
(          ) s
5 280 M
(        ) s
5 269 M
(        Note to the reader:  the POSITION= specifier does not appear) s
5 258 M
(        to need any edits.) s
5 247 M
(        ) s
5 236 M
(        Note to the reader.  In section 14, we discuss events) s
5 225 M
(        causing definition and undefinition of variables.  In item) s
5 214 M
(        \(3\) of 14.7.5, we discuss when input causes an item to be) s
5 203 M
(        defined, in terms of when the data is transferred, so no) s
5 192 M
(        edit is needed in \(3\).  Note that the second part of \(3\)) s
5 181 M
(        applies to internal units, which cannot be written to) s
5 170 M
(        asynchronously.) s
5 159 M
(        ) s
5 148 M
(        In section 14.7.5, item \(5\), change "an input/output) s
5 137 M
(        statement" to "an input/output statement without the) s
5 126 M
(        ASYNCHRONOUS specifier".) s
5 115 M
(        ) s
_R
S
%%Page: (14) 14
%%BeginPageSetup
_S
24 24 translate
/pagenum 14 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 14 of 16) s
5 698 M
(        ) s
5 687 M
(        In section 14.7.5, item \(8\), change "statement" to) s
5 676 M
(        "statement without an ASYNCHRONOUS specifier".) s
5 665 M
(        ) s
5 654 M
(        In section 14.7.5, insert this new item \(9\), and renumber) s
5 643 M
(        the remaining items:) s
5 632 M
(          \(9\) Execution of a READ statement containing both an) s
5 621 M
(          ASYNCHRONOUS and a SIZE= specifier may cause the) s
5 610 M
(          variable specified in the SIZE= specifier to become) s
5 599 M
(          defined, or the corresponding wait operation may cause) s
5 588 M
(          that variable to become defined.  Either the READ) s
5 577 M
(          statement or the corresponding wait operation will) s
5 566 M
(          cause that variable to become defined.) s
5 555 M
(        ) s
5 544 M
(        In section 14.7.6, item \(4\), change "input/output statement") s
5 533 M
(        to "input/output statement or its corresponding wait) s
5 522 M
(        operation".) s
5 511 M
(        ) s
5 500 M
(        In section 14.7.6, item \(5\), change "input/output statement") s
5 489 M
(        to "input/output statement or its corresponding wait) s
5 478 M
(        operation".) s
5 467 M
(        ) s
5 456 M
(        In section 14.7.6, item \(7\), change "input statement" to) s
5 445 M
(        "input statement or its corresponding wait operation".) s
5 434 M
(        ) s
5 423 M
(        In section 14.7.6, add a new item \(16\) \(the editor may) s
5 412 M
(        relocate to another part of the list if desired\):) s
5 401 M
(          Execution of a READ or WRITE statement with the) s
5 390 M
(          ASYNCHRONOUS specifier causes all variables in the item) s
5 379 M
(          list or namelist, all <implied-do-variables> in the item) s
5 368 M
(          list, and the variable specified in the SIZE=) s
5 357 M
(          specifier, if any, to become undefined.  Variables in a) s
5 346 M
(          namelist group specified in such a READ or WRITE) s
5 335 M
(          statement that are not actually read or written by the) s
5 324 M
(          data transfer statement do not become undefined.) s
5 313 M
(          ) s
_R
S
%%Page: (15) 15
%%BeginPageSetup
_S
24 24 translate
/pagenum 15 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 15 of 16) s
5 698 M
(        ) s
5 687 M
(        -------------------------------------------------------------) s
5 676 M
(        Rationale for Asynchronous I/O: may be inserted in the) s
5 665 M
(                                        appropriate annex if desired.) s
5 654 M
(        ) s
5 643 M
(        Rather than limit support for asynchronous I/O to what has) s
5 632 M
(        been traditionally provided by facilities such as BUFFERIN-) s
5 621 M
(        BUFFEROUT, this standard builds upon existing Fortran syntax.) s
5 610 M
(        This permits alternative approaches for implementing) s
5 599 M
(        asynchronous I/O, and simplifys the task of adapting existing) s
5 588 M
(        standard conforming programs to utilize asynchronous I/O.) s
5 577 M
(        ) s
5 566 M
(        Not all processors will actually perform I/O asynchronously,) s
5 555 M
(        nor will every processor that does be able to handle data) s
5 544 M
(        transfer statements with complicated I/O item lists in an) s
5 533 M
(        asynchronous manner.  Such processors can still be standard) s
5 522 M
(        conforming.  Hopefully, the documentation for each Fortran) s
5 511 M
(        processor will describe when, if ever, I/O will) s
5 500 M
(        be performed asynchronously.) s
5 478 M
(        ------------------------------------------------------------) s
5 467 M
(        Conceptual Model) s
5 456 M
(        ) s
5 445 M
(        This proposal accomodates at least two different conceptual) s
5 434 M
(        models for asynchronous I/O.) s
5 412 M
(        Model 1: the processor will perform asynchronous I/O when the) s
5 401 M
(        item list is simple \(perhaps one contiguous named array\) and the) s
5 390 M
(        I/O is unformatted \(possibly MAGTAPE\).  The implementation cost) s
5 379 M
(        is reduced, and this is the scenario most likely to be) s
5 368 M
(        beneficial on traditional "big-iron" machines.) s
5 357 M
(        ) s
5 346 M
(        Model 2: The processor is free to do any of the following:) s
5 335 M
(          on output, create a buffer inside the I/O library, completely) s
5 324 M
(          formatted, and then start an async write of the buffer, and) s
5 313 M
(          immediately return to the next statement in the program.  The) s
5 302 M
(          processor is free wait for previously issued WRITEs,  or not.) s
5 291 M
(        OR) s
5 280 M
(          pass off the I/O list to another processor/process, that will) s
5 269 M
(          process the list items independently of the processor which) s
5 258 M
(          executes the users code.  There is still an ordering) s
5 247 M
(          requirement on list item processing, to handle things) s
5 236 M
(          like READ \(...\) N,\(a\(i\),i=1,N\).  But there are restrictions) s
5 225 M
(          on the user to ensure that function calls in the i/o list,) s
5 214 M
(          and implied-do- variables, are free to be called/defined) s
5 203 M
(          asynchronously.  Hence the requirement that an) s
5 192 M
(          implied-do-variable not be referenced or redefined by any) s
5 181 M
(          other statement, including  another I/O statement, until the) s
5 170 M
(          matching wait operation is executed, and that functions) s
5 159 M
(          called as part of evaluating the I/O list be PURE.) s
5 148 M
(        ) s
5 137 M
(        One source of confusion is the role of the ID= values and) s
5 126 M
(        wait operations.  The standard allows a user to issue an) s
5 115 M
(        large number of async I/O requests, without waiting for any of) s
5 104 M
(        them to complete, and to then wait for any or all of them.) s
5 93 M
(        It is impossible, and undesirable to keep track of each of) s
5 82 M
(        these I/O requests individually.) s
_R
S
%%Page: (16) 16
%%BeginPageSetup
_S
24 24 translate
/pagenum 16 def
/fname (97-102) def
/fdir () def
/ftail (97-102) def
%%EndPageSetup
5 720 M
(                                                        X3J3/97-102) s
5 709 M
(                                                      page 16 of 16) s
5 698 M
(        ) s
5 687 M
(        The proposed support does not require all requests to be) s
5 676 M
(        tracked by the runtime library.  When the user does NOT specify) s
5 665 M
(        an ID= specifier on a READ or WRITE, the runtime is free to) s
5 654 M
(        forget about this particular request once it has successfully) s
5 643 M
(        completed.  If it gets an ERR or END condition, the processor) s
5 632 M
(        is free to report this during any I/O operation to that unit.) s
5 621 M
(          ) s
5 610 M
(        When an ID=specifier is present, the runtime is required to keep) s
5 599 M
(        track of any END or ERR conditions for that specific I/O request.) s
5 588 M
(        However, if the I/O request succeeds without any exceptional) s
5 577 M
(        conditions occuring, then the runtime can forget about that) s
5 566 M
(        ID= value if it wishes.  Typically, I except a runtime to only) s
5 555 M
(        keep track of the last request made, or perhaps a very few.) s
5 544 M
(        Then, when a user WAITs for a particular request, either the) s
5 533 M
(        library knows about it \(and does the right thing w.r.t. error) s
5 522 M
(        handling, etc.\), or will assume it is one of those requests) s
5 511 M
(        that successfully completed and was forgotten about \(and will) s
5 500 M
(        just return without signaling any end/err conditions\).  It is) s
5 489 M
(        encumbent on the user to only pass in valid ID= values.  There) s
5 478 M
(        is no requirement on the processor to detetct invalid ID= values.) s
5 467 M
(          ) s
5 456 M
(        There is of course, a processor dependent limit on how many) s
5 445 M
(        outstanding I/O requests which generate an END or ERROR conditions) s
5 434 M
(        can be handled before the processor runs out of memory to keep) s
5 423 M
(        track of such stuff.) s
5 412 M
(          ) s
5 401 M
(        The restrictions on the SIZE= variables are designed to allow) s
5 390 M
(        the processor to update such variables at any time \(after the) s
5 379 M
(        request has been processed, but before the WAIT operation\),) s
5 368 M
(        and to then forget about them.  That's why there is no SIZE=) s
5 357 M
(        specifier allowed in the various WAIT operations.  Only) s
5 346 M
(        exceptional conditions \(errors or EOFs\) are expected to be) s
5 335 M
(        tracked by individual request by the runtime, and then) s
5 324 M
(        only if an ID= specifier was present.) s
5 313 M
(          ) s
5 302 M
(        The EOR= specifier has not been added to the WAIT operations.) s
5 291 M
(        Instead, the IOSTAT variable will have to be queried after) s
5 280 M
(        a WAIT operation to handle this situation.  This choice was) s
5 269 M
(        made because an EOR condition is not perceived to be an) s
5 258 M
(        exceptional condition, like those that trigger and END=) s
5 247 M
(        or ERR= branch.  This particular choice is philosophical,) s
5 236 M
(        and was not based on significant technical difficulties.) s
5 214 M
(        Note that the requirement to set the IOSTAT variable correctly) s
5 203 M
(        requires an implementation to remember which I/O requests got) s
5 192 M
(        an EOR condition, so that a subsequent wait operation will) s
5 181 M
(        return the correct IOSTAT value.  This means there is a) s
5 170 M
(        processor defined limit on the number of outstanding I/O) s
5 159 M
(        requests \(non-advancing\) which got an EOR condition) s
5 148 M
(        \(constrained by available memory to keep track of this info,) s
5 137 M
(        similar to END/ERR conditions\).) s
5 126 M
(          ) s
_R
S
%%Trailer
%%Pages: 16
%%DocumentNeededResources: font Courier-Bold Courier 
%%EOF

