Trailing-Edge
-
PDP-10 Archives
-
CFS_TSU04_19910205_1of1
-
update/ftncsr/inpt.bli
There are 12 other files named inpt.bli in the archive. Click here to see a list.
!COPYRIGHT (c) DIGITAL EQUIPMENT CORPORATION 1972, 1987
!ALL RIGHTS RESERVED.
!
!THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE USED AND COPIED
!ONLY IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE AND WITH THE
!INCLUSION OF THE ABOVE COPYRIGHT NOTICE. THIS SOFTWARE OR ANY OTHER
!COPIES THEREOF MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY
!OTHER PERSON. NO TITLE TO AND OWNERSHIP OF THE SOFTWARE IS HEREBY
!TRANSFERRED.
!
!THE INFORMATION IN THIS SOFTWARE IS SUBJECT TO CHANGE WITHOUT NOTICE
!AND SHOULD NOT BE CONSTRUED AS A COMMITMENT BY DIGITAL EQUIPMENT
!CORPORATION.
!
!DIGITAL ASSUMES NO RESPONSIBILITY FOR THE USE OR RELIABILITY OF ITS
!SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPLIED BY DIGITAL.
!AUTHOR: S.MURPHY/HPW/TFV
MODULE INPT(RESERVE(0,1,2,3),DREGS=4,SREG=#17,FREG=#16,VREG=#15,GLOROUTINES)=
BEGIN
GLOBAL BIND INPTV = #11^24 + 0^18 + #1530; ! Version Date: 4-May-82
%(
***** Begin Revision History *****
83 ----- ----- INTERFACE TO SKOPTIO
***** Begin Version 7 *****
1530 TFV 4-May-82
Setup IOLSTATEMENT filed in IOLSCLS nodes.
***** End Revision History *****
)%
SWITCHES NOLIST;
REQUIRE FIRST.BLI;
REQUIRE TABLES.BLI;
SWITCHES LIST;
EXTERNAL
BASE CSTMNT,
DOWDP, ! Global used in determining whether a given loop can
! have its loop index live in a register.
FOLDIOLST,
NEGFLG,
NOTFLG,
P2SKL1DISP,
P2SKSTMNT,
%1530% TOPIO; ! Pointer to the I/O statement above an IOLSCLS node.
GLOBAL ROUTINE SKIOLIST=
BEGIN
!***************************************************************
! Perform phase 2 skeleton optimizations on an iolist. Makes 3
! passes over the list:
!
! 1. Perform phase 2 skeleton optimizations on the
! expressions under the iolist elements.
! 2. Detect DO loops that can be folded into elists and
! fold them (not implemented in release 1).
! 3. Detect groups of DATACALLs and SLISTCALLs that can be
! folded into a single IOLISTCALL and fold them.
!
! Called with the global CSTMNT pointing to a statement with a
! potential iolist.
!***************************************************************
REGISTER
PEXPRNODE ARGNODE,
BASE IOLELEM,
BASE SAVSTMNT;
MAP OBJECTCODE DOWDP;
! Return if this statement has no iolist
IF .CSTMNT[IOLIST] EQL 0 THEN RETURN;
! Save pointer to this statement (will recurse through SKSTMN
! routines if there are any statements on this iolist
SAVSTMNT = .CSTMNT;
! Walk down the iolist performing phase 2 skeleton optimizations
! on each element
IOLELEM = .CSTMNT[IOLIST];
UNTIL .IOLELEM EQL 0
DO
BEGIN ! Walk down the iolist
IF .IOLELEM[OPRCLS] EQL STATEMENT
THEN
BEGIN
CSTMNT = .IOLELEM;
P2SKSTMNT(); ! Do skeleton optimizations
END
ELSE IF .IOLELEM[OPRCLS] EQL IOLSCLS
THEN
BEGIN
%1530% ! Setup pointer to the I/O statement above the IOLSCLS
%1530% IOLELEM[IOLSTATEMENT] = .TOPIO;
! For a DATACALL node, perform phase 2 skeleton
! optimizations on expressions under this node
IF .IOLELEM[OPERSP] EQL DATACALL
THEN
BEGIN
NEGFLG = FALSE;
NOTFLG = FALSE;
ARGNODE = .IOLELEM[DCALLELEM];
IOLELEM[DCALLELEM] = (.P2SKL1DISP[.ARGNODE[OPRCLS]])(.ARGNODE);
! Check whether the argument to FOROTS is the
! index of the current DO loop. If so, don't
! make it an AOBJN loop (problems with using
! right-half of register.
ARGNODE = .IOLELEM[DCALLELEM];
IF .ARGNODE EQL .DOWDP[DOINDUC]
THEN DOWDP[DONOAOBJN] = 1;
END;
END;
! Go on to next element
IOLELEM = .IOLELEM[CLINK];
END; ! Walk down iolist
CSTMNT = .SAVSTMNT; ! Restore CSTMNT
! Walk down the iolist performing folding of DO loops into ELISTs is
! not implemented in release 1 (Aug 17,1972 - SRM).
! Walk down the iolist, folding groups of elements that can form a
! single IOLISTCALL
FOLDIOLST();
END; ! of SKIOLIST
END
ELUDOM