GC21 7608 2_System3_15_SCP_macros_reference_manual_Mar80 2 System3 15 SCP Macros Reference Manual Mar80

GC21-7608-2_System3_15_SCP_macros_reference_manual_Mar80 manual pdf -FilePursuit

GC21-7608-2_System3_15_SCP_macros_reference_manual_Mar80 GC21-7608-2_System3_15_SCP_macros_reference_manual_Mar80

User Manual: GC21-7608-2_System3_15_SCP_macros_reference_manual_Mar80

Open the PDF directly: View PDF PDF.
Page Count: 144

DownloadGC21-7608-2_System3_15_SCP_macros_reference_manual_Mar80 GC21-7608-2 System3 15 SCP Macros Reference Manual Mar80
Open PDF In BrowserView PDF
aaaa
aaaa
aoaa
aaaa
aaaaaaaaaaaaaaaaaa
aaaaaaaaaaaoaaaaaa
aaaaaaaaoaaaaaaaaa
a a a a o a a a a a a a aaa a a a
aaaa
aaaa
aaaa
aaaa
aaaa
aaaa
aaaa
aaaa
aaaaaaaaaaoaa aa aaa
aaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaa
aaaa
aaaa
aaaa
aaaa
aaaa
aaao
aaao
aaaa
-aaa
aaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaa
aaaaaa
aaaaaa
aaaa
aaaa

IBM System./3 Model 15

System ControlProgrammingMacros
Reference
Manual

aaaa
aaaaa
aaaaa
aaaaaaa
aaaaaa
aaaaaaaaa
aaaaaaa aaaaaaaaaaa
aaaaaaa
aaaaaaaaaaa
aaaa
aaaa
aaaa
aaaa
aaaa
aaaa
aoaa
aaaa
aaaa
aaaaaaaaaaaa
aaaaaa
aaaaaaaaaaaa
aaaaaa
aaaaaaaaaa
aaaaa
aaaaaaaa
aaaa
aaaaaa

aaaa
aaaaa
aaaaa
aaaaaaa
aaaaaa
aaaaaaaaa
aaaaaaa
aaaaaaaaaaa
aaaaaaa aaaaaaaaaaa
aaaa
aaaa
aaaa
aaaa
aaaa
aaaa
aaaa
aaaa
aaaa
aaaaaaaaaaaa
aaaaaa
aaaaaaaaaaaa
aaaaaa
aaaaaaaaaa
aaaaa
aaaaaaaa
aaaa
aaaaaa

aaaa
aaaa
aaaaaaa
aaaaa
aaa aa
aaaaaaa
aaaa
aaaa

aaaa
aaaa
aaaa
aaaaaa
aaaaaa
aaaaaa
aaaaaa
aaaa
aaaa
aaaa
aaaa
aaaaaaaaaaaaaaaaaa
aaaaaaoaaaaaaaaaaa
aaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaa
aaaaaaaaaa
aaaaaaaaaaa
aaaaaaaaaaa
aaaaaaaaoaa
aaaaaaaaaaa
aaaaaaaaaaa
aaaa aa a aaa
aaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaa
aaooaaaaaaaaaaaaaa
aaaa
aaaa
aaaa
aaaa

GC21-7608-2
F i l eN o . 5 3 - 3 6

P a g eo f G C 2 1- 7 6 0 8 - 2
l s s u e d2 9 S e p t e m b e r 1 9 7 8
By TNL: GN21-5649

Preface

Thismanua|describesthemacrcrinstrttcttcrtts1rtrlvic1t,ci|lisl..saiiii,i..i]i()ql;ir,|.;l-1i,'.,;\ri|l!i
the IBM System/3 Moclel 15. The publrc,riirrr:;i ir,tcnue,,j

t;iiri-;

f o r p e r s o n s w h o a r e p r o g r a m r n i n g i n t h e i J a s i cA s s e m b l e r
L a n g u a g eo r i t s e q u i v a l e n t a r r d w h o a r e i a n i i i t d t w i i t , t i r c
concept of macro instructions and syslr:ii lrrograrn:'niitti

.r

, / t i e r ir ] i . i i ) , - - , ) t - o p eDnT F ( D e f i r r e
i l t : : . . 1 ' 1 , t ,. . , [ r ; - ,
l n r ; : , i , .1 i j i l r , t r . i l L j l u r . ; k sf 1 , 1, s r r r ar r j o o i r : .a1r r r {t l r s k d e v i c e s ,

f o r t h e I B M S v s t e m / 3N 4 o d e1l 5 .
T h e f o l l o w i n g t o p i c s a r e d i s c u s s e  e c i f i e c' tir i t
t h i s o J r e r a n rils o r n i t t e d , o p t i o l - l3 i s r r o t ; r i l o v ; t " i
l i s a l l o w e d .c ( ) ! l 1 r ( -v)vl i l l t t ' r t l t i l i ' l r t ll i t ) r l
l v ( l f r r . l f t i 1 : l i t t t3
y
o
u
l
p
r
o
q
r
a
l
l
r
l.
to

Macro Instructioll Slaterndllts

I 1

T L E N - n u m b e rs p e c i f i e st h e t e x t l e n g t h . T h i s e n t r y ( L ) ,
v v h i c hi s a d e c i m a l e n t r y f r . c r n1 t o 1 O 7 ,i s r e q u i r e c l
if
FORMAT C or D isspecified.

TADB-addressspecifies the leftmost byte of the rext
a d d r e s s . T h i s o p e r a n d ( A A ) i s r e q u i r e di f F O R M A T _ Co r D
isspecified.

Generate Displacements for System LoS 6L()GD)
"l-his
m a c r o i n s t r u c t i o r rg e n e r a t e st h e f i e r l r i.dl i r s i 5s 1 r 6o1f f s e t s
f o r t h e s y s t e m l o g p a r a r r e t e rl i s t s " T o i i v c i r lr l u p l i c a t el a b e l s ,
y o u s h o u l d u s e I h i s m a c r o i r t s t r r r c l i o rrt: n l y L , i l o er i l ; )
i ) lo g r a n t .
T h e f o r m a t o f t h e $ L O G m a c r o i n s t r u c l i o ni s :

Generate the Linkage to the System LoS $LOG)
T h i s m a c r o i n s t r u c t i o ng e n e r a t e st h e l i n k a g er e q u i r e dt o
use
t h e s y s t e m l o g f u r r c t i o n ,a n d c h e c k st h e r e s p o n s er e t u r n e d .
T h e $ L O G D m a c r o i n s t r u c t i o nm u s t b e u s e c w
l ith this
m a c r o i n s t r u c t i o n ,t o e s t a b l i s ho f f s e t si n t h e s y s t e m r o g
p a r a m e t e rl i s t .
l f y o u w i l l n e e d t o u s et h e d a t a i n r e g i s t e r2 a t a l a t e r t i m e ,
y o u s h o u l d s a v et h e c o n t e n t so f t h a t r e g i s t e rb e f o r e i s s u i n g
t h e $ L O G m a c r oi n s l r u c t i o n .

General SCP Support
T h e g e n e r a lS C P m a c r o i n s t r u c t i o n sa l l c w y o u r o
l)rovrcte
linltLJ

$$ISUC
$$ISUD

lfr(l{rx.rdRandom Add
lrrlured Random Add MVf

lrrdexed Randorn Update
inrlexed Random Update & Add

i rrrltrr:cj Serluential Add
ir;rlexedSequential Add MVF
l ; r r l r : x e dS r : q u en l r a l U p d a t e & A d d M V F

i i ' r l r : x t : cS
i cquerrtial Input MVF
i r , r l ' , x ( - , dS e q u e n t i a l U p d a t r :
lrrj.agli Sequentrai Update Within Limits

i r r r J e x e dS e q u e n t i a l U p d a t e & A d d
lrrcirxld Serluential Input Within Limits l\/VF

changeable Limits

l r r r J c x e dS e c l u e r n t i a Il n p u t W i t h i n C h a n g e a b l e L i m i t s M V F
i r ) i i e x e c ,S e q u e n t i a l U p d a t e W i t h i n C h a n g e a b l e L i m i t s
l r r d e x e d S e c l u e n t i a l L l p c l a t eW i t h i n C h a n q e a b l e L i m i t s M V F

Disk [)ata Management Modules yvithout Exterrral Bulferinq

P a g eo f G C 2 1- 7 6 0 8 - 2
l s s u e d2 9 S e p t e m b e r 19 7 8
Bv TNL: GN21-5649
Move/

$GETD

$PUTD

AC-code
5444

X
X
X
X

X
X

X
X
X
X

X
X
X
X

CAM
CG
CGM

I 5445

cA5
CAMS
C GM 5

Locate
Mode

M
M
M
I\4

co

LU5

COM
CU
CUM

COM5
CU5
CUM5

M
M
M
M

DGA
DGAIVI
DGM

DG5
DGA5
DGAM5
DG IVIs

M
M
M
M

System Module
5444
| 5445

Access Method

$$wsoP | $$wFoP
$$wsoM i $$vrFOM
$ $ w s r P i $ $ w rr e
$$\rJStr\,1
l$$wFtM
$$wsoP | $$wFoP
$$wsoM | $$wFoM
$ $ " ^ ' / S UIP
$$WFUP

C o n s e c u t i v eA d d
C o n s e c uitv e A d d M u l t i v o l u n r e
C o n s e c u t i v eG e t
C o r r s e c u t i v eG e t M V F

D i r e c tG e t
D i r e c t G e t ( B i n a r yK e y s )
D i r e c t G e t ( B i n a r y K e V s )M V F
DirectGet MVF

s$v\su\,1
isswruna

Consecutive
Output
C o n s e c u t t v eO u t p u t I M V F
C o n s e c u t i v eU p d a t e
C o n s e c u t i v eU p d a t e M V F

X
X
X
X

X
X
X
X

DO
DOA
DOAM
DOIVI

DO5
DOA5
DOAM5
DOM5

M
M
M
M

$$YArD | $$Yr,tD
$$YArB | $$YFtB
$ $ Y A r r | $ $ Y Ft r
s$YArM
$ $ Y Ft M
|
$$YAUD | $$YFUD
$$YAUB | $$YFUB
$$YAUr
| $$YFUr
$$YAUM I $$YFUM

X
X
X
X

X
X
X
X

DU
DUA
DUAM
DUM

DU5
DUAS
DUAM5
DUM5

M
M
M
M

$$YAUD
$SYAUB
$$YAi-JT
$$YAUM

$ $ Y FU M

Direct Update
D i r e c t U p d a t e{ B i n a r yK e y s )
D i r e c t U p c l a t e{ B i n a r y K e y s ) M V F
Drrect Update MVF

X
X
X
X

IA
IAM

to
roM

rA5
IAM5
to5
roM5

M
M
M
M

$$XOAD
S$XOAM
SSXOUT
$$xo{-JM

S$XFAD
$$XFAM
)sArut
$ $ X FU M

I n d e x e dA d d
i r t d e x e dA d d M V F
I n d e x e dO u t p u t
l n d e x e dO u t p u t M V F

X
X
X

IR
IRA
IRAM
IRBM

tR5
IRA5
IRAM5
IRBM5

M
M
M
M

$$XRIP
S$XRAD
$SXI] AM
$$XRBM

$$XGIP
$$XGAD
$$XGAIVI
$$XGBM

I n d e x e dR a n d o m l n p u t
I n d e x e dR a n d o m A d c i
I n d e x e dR a n d o m A d d M V F
Indexed Random Update & Add IVIVF

X
X

X
X
X

IBM
IRU
IRUA
IRUM

tR tvl5
IUR5
IRUA5
IRUM5

M
M
M
M

$ S X I ]I M
$ S X RU P
$$XRUA
$$XRUM

$ $ X GI M
$$XGUP
$ $ X GU A
$$XG U M

I n d e x e dR a n d o m i n p u t M V F
I n d e x e dR a n d o m U p d a t e
I n d e x e dR a n d o m U p d a t e& A d d
l n d e x e dR a n d o m U p c l a t eM V F

X
X
X
X

IS
ISA
ISAM
ISBM

ts5
ISA5
ISAM5
ISMB5

M
M
M
M

$sxsIP

X
X
X

$$XHIP
$$XHAD
$ S XH A M
$$XHBM

I n d e x e dS e q u e n t i a lI n p u t
I n d e x e dS e q u e n t i a A
l dd
I n d e x e dS e q u e n t i a A
l dd MVF
I n d e x e dS e q u e n t i a U
l p d a t e& A d d M V F

X
X

ISL
ISM
ISU
I S UL

ISL5
tsM5
ISU5
I S UL 5

M
M
M
M

$$XSI L
$ S X SI M
$SXSUP
$ S X S UL

$$XHIL
$ $ X S HI M
$$X H UP
$SXHUL

I n d e x e dS e q u e n t i a Il n p u t W i t h i n L i m i t s
I n d e x e dS e q u e n t i a lI n p u t M V F
I n d e x e dS e q u e n t i a U
i pdate
l n d e x e dS e q u e n t i a U
l p d a t eW i t h i n L i m i t s

ISUM5
ISUA5
ISLMS
ISUB5

M
M
M
M

$SXSUM
$SXSUA
$ S X SI B

X

ISUM
ISUA
ISLM
ISUB

$$XSIJB

$$X H UM
$$xl-JLiA
$$XHIB
$$XHUB

I r r d e x e dS e q u e n t i a U
l p d a t eM V F
I n d e x e dS e q u e n t i a U
l p d a t e& A d d
I n d e x e dS e q u e n t i a Il n p u t W i t h i n L i m i t s M V F
l n d e x r d S e q u e n t i aU
l p d a t r :W r t h i n L i m i t s M V F :

ISC5

X
X

ISC
ISCM
ISUC
ISUD

M
M
M
M

$SXSIC
$SXSID
$$XSUC
SSXSUD

$$X H IC
$$XHID
$$XHUC

l n d e x e cS
l e q u c n t i a lI n p u t W i t h i n C h a n g e a b l e
Limirs
I n d e x e dS e q u e n t i a Il n p u t W i t h i n C h a n g e a b l e
Limits filVF
lrrclexed
S e q u e n t i aU
l p d a t eW r t h t n C h a n g e a b l e
Lirnits
l r i c l e x e cSl e o u e n t i a l U p d a t e i ' \ i t h i n C h a n g e a b l eL i m i t s M V F

X
X
X
X
X

X
X
X
X
X
X
X
X
X
X
X
X

X
X

rscM5
ISUC5
ISUD5

$SXSAD
$SXSAM
$SXSBM

$$YFUD
$ $ Y FU B
olYFUl

$sxHr.rD

D i r e c tO u t p u t
D i r e c t O u t p u t ( B i n a r yK e y s )
D i r e c tO u t p u t ( B i n a r y K e y s ) M V F
DirectOutput MVF

F i g u r e 1 1 l P a r t 2 o f 2 ) . D i s k D a t a M a n a g e m e n tM o d u l e s W i t h E x t e r n a l B u f f e r i n g

( 5 7 0 4 - S C 2o n l y l

\1alo

Instructr0ri Slatements

4

Pageof GC21-7608-2
lssued29 September
1978
BvTNL: GN21-5649
The code generatedby this macro instruction givescontrol
t o t h e d a t a m a n a g e m e n tr o u t i n e ; t h e r o u t i n e c o m p l e t e s
execution and returns control to the generatedcode. Completion codes are tested and control is returned to Vour
program.
T h e f o r m a t o f t h e $ P U T D m a c r o i n s t r u c t i o ni s :
[ N a m e |l $ P U r D I l t A c { o d e ] t
|
| ileenccoael\
[ , D T F - a d d r e s s [] , E R R - a d d r e s s ]
[ . E O X- a d d r e s s ][ , D U P - a d d r e s s ]
[ , S E R R - a d d r e s s[], K E R R - a d d r e s s ]
t,UPD-Y/Nl [,LSTV-address]
[ , N O K Y - a d d r e s s ][ , H K E R - a d d r e s s ]

AC+ode or EBAC-code specifies the appropriate access
method for the file. The EBAC-code is for external buff e r i n g a n d i s v a l i d o n l y f o r P r o g r a mN u m b e r 5 7 0 4 . S C 2 .
O n e o f t h e s ep a r a m e t e r sm u s t b e s p e c i f i e d .

The codes that must be used for the AC-code and the
E B A C - c o d ep a r a m e t e r sa r e s h o w n i n F i q u r e 1 1 .

DTF-addressspecifies the addressof the DTF associated
w i t h t h i s f i l e . l f t h i s o p e r a n d i s n o t s p e c i f i e d ,t h e a d d r e s s
i s a s s u m e dt o b e i n r e g i s t e r2 .

ERR-addresssupplies the addressin your program where
c o n t r o l i s p a s s e di f t h e c o n t r o l l e d c a n c e lo p t i o n i s t a k e n i n
r e s p o n s et o a p e r m a n e n t l / O e r r o r . l f t h i s o p e r a n d i s o m i t t e d , n o c o d e i s g e n e r a t e dt o c h e c k f o r t h e c o n t r o l l e d c a n c e l
c o m p l e t i o nc o d e .

EOX-addresssuppliesthe addressin your program that is to
r e c e i v ec o n t r o l w h e n a n e n d o f e x t e n t i s r e a c h e dd u r i n g t h e
o p e r a t i o n . T h i s o p e r a n d i s e n t e r e do n l y w h e n c r e a t i n ga
c o n s e c u t i v eo r i n d e x e d f i l e o r w h e n r e c o r d sa r e t o b e a d d e d
to the file.

DUP-addressprovides the addressin your program that is to
r e c e i v ec o n t r o l w h e n a n a t t e m p t t o a d d a d u p l i c a t e r e c o r d
h a s o c c u r r e d . T h i s o p e r a n d i s u s e do n l y w i t h a n a d d a c c e s s
method.

44

P a s eo f G C 2 1- 7 6 0 8 , 2
l s s u e d2 8 M a r c h 1 9 8 0
By TNL: cN21-5700

SERRaddress is the addressin your program where control
i s p a s s e di n t h e e v e n t o f a s e q u e n c ee r r o r w h i l e l o a d i n ga n
i n d e x e df i l e .

KERR-addressspecifiesthe addressof Vour routine to be
c a l l e dw h e n a n a t t e m p t h a s b e e n m a d e t o u p d a t e a r e c o r o
i n a n i n d e x e df i l e a n d t h e a t t e m p t w o u l d d e s t r o y t h e
record keV.

UPD-Y/N indicateswhether an update is to be performed.
l f t h i s o p e r a n di s n o t e n t e r e d ,N ( n o ) i s a s s u m e d .

LSTV-addressspecifies the addressin your program that
receivescontrol when a requestedkey is too high for the
l a s t s p e c i f i e dv o l u m e . T h i s o p e r a n d i s u s e do n l v w h e n
processing
a n i n d e x e d ,r a n d o m , o f f l i n e , m u l t i v o l u m e f i l e .

NOKY-addresssuppliesthe addressin your program that is
t o r e c e i v ec o n t r o l u n d e r e i t h e r o f t h e f o l l o w i n q c o n d i t i o n s :
o T h e r e q u e s t e dk e y i s t o o l o w f o r t h e c u r r e n t v o l u m e
when processing
a n i n d e x e d ,r a n d o m , o f f l i n e . m u l t i v o l u m ef i l e .
.

T h e r e q u e s t e dk e y i s t o o h i g h f o r a n y v o l u m e w h e n
p r o c e s s i n ga n i n d e x e d r a n d o m o n l i n e m u l t i v o l u m e f i l e .

DISK 5444/5445/3340 specifieswhether the disk device
b e i n g u s e d i s t h e 5 4 4 4 D i s k S t o r a g eD r i v e M o d e l 1 , 5 4 4 5
D i s k S t o r a g e ,o r t h e 3 3 4 0 D i r e c t A c c e s sS t o r a g eF a c i l i t y . l f
a d e v i c ei s n o t s p e c i fi e d , 5 4 4 4 D i s k S t o r a g eD r i v e M o d e l 1
is assumed.

C Y C L - n u m b e r i n d i c a t e st h e b e g i n n i n gc y l i n d e r t o b e
accessedY
. o u c a n s p e c i f yt h e c y l i n d e r b y a d e c i m a ln u m b e r ( 0 - 1 9 9 )o r a h e x a d e c i m anl u m b e r ( X ' 0 0 ' X ' C 7 ' ) . l f t h i s
o p e r a n di s n o t e n t e r e d ,X ' F F ' i s a s s u m e d .Y o u m u s t t h e n
i n s e r tt h e c o r r e c t n u m b e r i n t o t h e I O B b e f o r e p e r f o r m i n g
the input/output operation. This can be done throuqhthe
m a c r o u s e dt o i n i t i a t et h e l l O o p e r a t i o n .

SCTR-number specifies the first sector to be accessed.The
n u m b e r s p e c i f i e dm u s t b e a d e c i m a lf r o m 1 t h r o u g h 4 8 f o r
t h e 5 4 4 4 d i s k d r i v e ,f r o m i t h r o u g h 2 0 f o r t h e 5 4 4 5 d i s k
s t o r a g e ,o r f r o m 1 t o 4 8 f o r t h e 3 3 4 0 d i s k d r i v e . l f t h i s
o p e r a n di s n o t e n t e r e d, X ' F F ' i s a s s u m e d .Y o u m u s t t h e n
i n s e r tt h e c o r r e c t n u m b e r b e f o r e p e r f o r m i n gt h e i n p u t /
o u t p u t o p e r a t i o n . Y o u c a n s p e c i f y t h e s e c t o rt h r o u g h t h e
$ R D D a n d $ W R T D m a c r oi n s t r u c t i o n s .

HEAD-number is specified only for the 5445 or 3340 disk
s t o r a g ed r i v e s . l t s p e c i fi e st h e h e a d t o b e u s e dw i t h t h e
c y l i n d e r a n d s e c t o rw h e n a n l / O o p e r a t i o n i s p e r f o r m e d .
T h e n u m b e r s p e c i f i e dm a y b e d e c i m a l ( 0 - ' l9 ) o r h e x a d e c i m a l( X ' 0 0 ' - X ' 1 3 ' ) l f t h i s o p e r a n di s o m i t t e d , X ' F F '
i s a s s u m e da n d t h e v a l u e m u s t b e u p d a t e dw h e n t h e l i O
o p e r a t i o ni s p e r f o r m e d .

This operand is not used with other accessmethoos.

HKER-addressspecifiesthe addressin your program that is
to receivecontrol when an indexed sequentialadd multivolume is attempted and the requestedkey is higher than
a n y k e y p r e s e n t l yi n t h e f i l e , b u t l o w e r t h a n t h e h i g h e s t
p e r m i s s i b l ek e y .

lnput/Output

Block for Disk ($IOBD)

This macro instruction generatesa disk input/output block
( l O B ) f o r u s e b y t h e d i s k i n p u t / o u t p u t s u p e r v i s o r .A 3 0 byte IOB is generatedtor 5444,5445, and 3340 disk
d e v i c e s . F o r a d e t a i l e dd e s c r i p t i o no f t h e d i s k l O B , s e e
Appendix C: Disk lnput/Output Block.
T h e f o r m a t o f t h e $ I O B D m a c r o i n s t r u c t i o ni s :
[Namel| $roBD I lDtsK-94441s445l334o]
[,cyL-number]
[ . S C T R - n u m b e r ][ , HE A D - n u m b e r ]
[ , N U M - n u m b e r ][ . B U F F ' a d d r e s s ]
[ , O - n u m b e r ][ , E R R E C - l O S / U S EIR
t.LOG-Y/N1[,VER Y/N] [,CHN'address]

NUM-number specifies the number of sectorsused. You
m a y s p e c i f yt h e n u m b e r i n e i t h e r d e c i m a lo r h e x a d e c i m a l
f o r m . l f t h i s o p e r a n d i s n o t e n t e r e d ,o n e s e c t o r i s a s s u m e d .

BUFF-addressis the addressof the leftmost byte of your
d a t a a r e a . l f t h i s o p e r a n di s o m i t t e d , X ' F F F F ' i s a s s u m e d ,
a n d y o u m u s t u p d a t e t h e I O B b e f o r e p e r f o r m i n gt h e i n p u t /
output operatton.

Q-number specifiesthe drive on which the record is located.
'You
m a y s p e c i f yt h e d i s k d r i v ea l o n e F 1 , R 1 , F 2 , R 2 , D 1 ,
D
D2, 3/D31, D32, D33, D34, D4/D41, D42, D43, andD44,
o r y o u m a y s p e c i f yt h e h e x a d e c i m a O
l - c o d ei n t h e f o r m
O - X ' n n ' , w h e r e n n i s a v a l i d h e x a d e c i m aO
l -code. The
v a l i d O - c o d e sa r e s h o w n i n F i g u r e 1 2 . l f y o u s p e c i f y
o n l y t h e d i s k d r i v e , y o u m u s t s e t t h e r e a c r / w r i t eb i t s ( t h e
l a s t f o u r b i t s o f t h e O c o d e ) b e f o r ey o u c a n p e r f o r m
the l/O operation. This can be done through the $RDD
or $WRTD macro instructions.
Note: D31. D32, D33, D34,D41,D42,D43, and D44
a r e f o r 5 7 0 4 - S C 2o n l y .
Macro InstructionStatements
D i s k D e v i c eS u p p o r t

a3

lnput/Output

vo

O-ByteSettinq(Hex)
O p e r a t i o n D r i v e 1 D r i v e 2 D r i v e3 D r i v e4
5 4 4 4 R e m o v a b l eD i s k
Control
Read

Write
Scan

AO
A1
A2
A3

Write
Scan

A8
Ag
AA
N D

T h i s m a c r o i n s t r u c t i o ng e n e r a r e e
s q u a t e st o e s t a b l i s hl a b e l s
f o r t h e d i s k l O B s . T h e s el a b e l sa r e o f f s e t sf r o m t h e b e g i n n i n g o f t h e I O B a n d a r e u s e da s d i s p l a c e m e n ft rso m t h e b e g i n n i n go f t h e I O B w h e n y o u w i s h t o i - e f e rt o o n e o f t h e

BO
B1
B2

f i e l d s . T h e l a b e l sg e n e r a t e db y t h i s m a c r o i n s t r u c t r o na r e
g i v e n w i t h t h e f i e l d so f t h e I O B i n A p p e n d i x C . D i s k

B3

l n p u t / O u t p u t B l o c k . f o a v o i d d u p l i c a t el a b e l s ,y o u s h o u l d
u s e t h i s m a c r o i n s t r u c t i o no n l y o n c e i n a p r o g r a m .

5 4 4 4 F i x e dD i s k
Control
Bead

Block Offsets ($ lO E D )

B8
B9
BA
BB

T h e f o r m a t o f t h e g I O E D m a c r o i n s t r u c t i o ni s :
$IOED

5 4 4 5D i s k
Control
Read

Write
Scan

CO
C1
C2
C3

CB
C9

CA
CB

DO
D1
D2
D3

DB
D9
DA
DB

Read from Disk (gRDD)
T h i s m a c r o i n s t r u c t i o ng e n e r a t e sa n i n t e r f a c et o t h e d i s k
i n p u t / o u t p u t s u p e r v i s o rt h a t i s t o r e a d f r o n r t l r e d i s k d e v i c e
W h e n u s i n gt h i s m a c r o i n s t r u c l i o n y, o u m u s t :

Figure12. O-ByteHexadecimal
Settingsr
o
E R R E C I O S / U S F F i n d i c a t e sw h e t h e r t h e i n p u t / o u t p u t
s u p e r v i s oi rs t o h a n d l ee r r o r r e c o v e r y .l f y o u s p e c iyf l O S ,
t h e s u p e r v i s o rh a n d l e se r r o r r e c o v e r ya n d r e t r i e st h e o p e r a t i o n w h e n e r r o r so c c u r . l f y o u s p e c i f yU S E R ,t h e s u p e r v l s o r
d o e s n o t r e t r y t h e o p e r a t i o na n d r e t u r n s c o n t r o l t o y o u . l f
t h i s o p e r a n di s n o t s p e c i f i e dI,O S i s a s s u m e d .

L O G Y / N i n d i c a t e sw h e t h e r t h e l / O s u p e r v i s o ri s t o l o g
e r r o r st h a t o c c u r d u r i n gt h e o p e r a t i o n . l f y o u s p e c i f yy
( y e s ) ,e r r o r c o n d i t i o n sa r e l o g g e do n t h e s V s t e mp a c k . T h i s
i n f o r m a t i o n i s u s e db y l B l V lc u s t o m e re r r g i n e e r sl.r l ( n o 1
i n d i c a t e sn o l o g g i n gi s t o b e d o n e f o r t h i s l O B . l f t h i s o p e r _
a n d i s n o t e n t e r e d ,Y i s a s s u m e d .

V E R - Y / N i s u s e df o r o u t p u t o p e r a t i o n s . Y ( y e s ) i r r d i c a t e s
t h e w r i t t e n d a t a s h o u l c bi e v e r i f i e d ; N ( n o ) i n d i c a t e si t
s h o u l dn o t . l f t h i s o p e r a n di s o m i t t e d ,Y i s a s s u m e d .

P r o v i d ea n I O B a n d u s et h e $ I O E D m a c r o i n s t r u c t r o r r
t o e s t a b l i s thh e o f f s e t si n t h e l O B .

o W a i t f o r t h e c o m p l e t i o no f t h e i n p u t o p e r a t i o n( u s i n g
$WAIT).
o

Checkfor end of extent when the recordis received
c o m p l e t i o nc o d e o f X ' 7 0 ' ( $ C p E O X )a t $ D F C M p i n t h e
DTF.

l f b o t h r e a d i n ga n d w r i t i n g f o r a p r o g r a ma r e t o D e p e r f o r m e d u s r n ga s i n g l el O B , t h e b i t s o f t h e O - b y t ea r e a t t e r e d
t o i n d i c a t ea r - irn v a l i d o p e r a t i o n . I n t h i s c a s e ,y o u m u s t s e t
o f f t h e b i t s o f t h e O - b y t e f o r a l l b u t t h e f i r s t r e a c l( o r w r i t e )
o p e r a t i o ni n t h e p r o q r a m .
l f y o u w i l l n e e dt o u s et h e d a t a i n r e g i s t e 1
r a t a l a t e rt i m e ,
y o u s h o u l ds a v et h e c o n t e n t so f t h a t r e g i s t e br e f o r ei s s u i n g
t l r eS R D D m a c r oi n s l r u c t i o n .
T h e f o r n r a t' - r it h e $ R D D m a c r o i n s t r u c t i o ni s :

CHN-addressspecifies the addressof thr: leftmost byte of
t h e n e x t I O B f o r t h e o p e r a t i o ni f m o r e t h a n o n e I O B i s
r e qu i r e d .

-

4b

F i g u r e1 2 a p p l i e so n l y t o 5 7 O 4 - 5 C 1 . F o r 5 7 0 4 - S C 2 y, o u c a n
s p e c i f yo n l y t h e d i s k d r i v e ( F 1 , R 1 , e t c . ) w i r h t h e O p a r a m e r e r .
a n d r e a d / w r i i eb i t s a r e s e t w i t h g F lD D o r g W R T D .

l N a m e lI $ t l D D I I O B - a d d r e s s , C S - a d d r e s s , N S E C T - n u m b e r

44513340]
[,Dls K-544415

P a g eo f G C 2 1 - 7 6 0 8 - 2
l s s u e2
d 8 M a r c h1 9 8 0
B yT N L : c N 2 1 - 5 7 0 0
IOB-addressprovides the addressof the leftmost byte of
t h e I O B w h i c h y o u c r e a t e dt h r o u g hy o u r g I O B D m a c r o
I n s t r u c t i o n . T h e l a b e l p r o v i d e d m u s t b e t h e s a m ea s t h e
n a m es p e c i f i e do n y o u r $ I O B D m a c r o i n s t r u c t i o r r .

CS-addressis the addressof the rightmost byte of the main
s t o r a g ea r e ac o n t a i n i n gt h e d i s k c y l i n d e r / s e c t o ra d d r e s so f
t h e a r e ay o u w a n t t o r e a d . T h e c y l i n d e r / s e c t o ra d d r e s sf o r
u s ew i t h r h e 5 4 4 4 i s a t w o - b y t e , h e x a d e c i m a n
l umber. The
f i r s t b y t e s p e c i f i e st h e c y l i n d e r ;t h e s e c o n ds p e c i f i e st h e
sector. For use with the 5445, or 3340, a three-byte hexa_
d e c i m a l d i s k a d d r e s si s p r o v i d e d t l r r o u g h t h i s e n t r y . T h e
f i r s t b y t e s p e c i f i e st h e c y l i n d e r ;t h e s e c o n d ,t h e h e a d
n u m b e r ;t h e t h i r d , t h e s e c t o r .

I O B - a d d r e s sp r o v i d e st h e a d d r e s so f t h e d i s k I O B f o r t h i s
o p e r a t i o n . T h e a d d r e s si s t h e n a m e s p e c i f i e do i r t h e r e l a t e d
$ I O B D m a c r oi n s t r u c t i o r r .

CS-addressis the addressof the rightmost bVte of the main
s t o r a g ea r e ac o n t a i n i n gt h e d i s k c y l i n d e r / s e c t o ra d d r e s so f
t h e a r e at o w h i c h y o u w a n t t o w r i t e . T h e c v l i n d e r / s e c t o r
a d d r e s sf o r u s e w i t h t h e 5 4 4 4 i s a t w o - b y t e h e x a d e c i m a l
n u m b e r . T h e f i r s t b y t e s p e c i fi e st h e c y l i n d e r ;t h e s e c o n d
specifiesthe sector. For use with the 5445 or the 3340,
a t h r e e - b y t eh e x a d e c i m a d
l i s k a d d r e s si s p r o v i d e dt h r o u g h
t h i s e n t r y . T h e f i r s t b y t e s p e c i fi e st h e c y l i n d e r ;t h e s e c o n d .
the headnumber;the third, the sector.
N S E C T - n u m b e rs p e c i f i e st h e h e x a d e c i m a n
l umber of disk
s e c t o r s ,m t n u s o n e , t o b e w f l t t e n .

N S E C T - n u n b e r i n d i c a t e st h e l r e x a d e c i m anl u m b e r o f s e c t o r s .
m r n u so n e , t o b e r e a di n t h i s o p e r a t i o n .

DISK-5444/5445/3340 specifies whether the operation is
o n a 5 4 4 4 , a 5 4 4 5 , o r a 3 3 4 0 d i s k d r i v e . l f t h i s o p e r a n di s
omitted, 5444 is assumeo.

Write to Disk ($WRTD)
T h i s m a c r o i n s t r u c t i o ng e n e r a t e sa n i n t e r f a c et o t h e d i s k
i n p u t / o u t p u t s u p e r v i s o rn e e d e dt o w r i t e r e c o r d st o d i s k .
W h e r ry o u u s et h i s m a c r o i n s t r . u c t i o ny ,o u m u s t :
.

P r o v i d ea n l O B , a n d u s et h e $ I O E D m a c r o i n s t r u c t r o nt o
e s t a b il s h t h e o f f s e t si n t h e l O B .

o W a i t f o r t h e c o m p l e t i o no f t h e o u t p u t o p e r a t i o n( u s i n g
$WAIT).

DISK-5444/5445/3340 specifies whether the operation is
o n a 5 4 4 4 , a 5 4 4 5 , o r a 3 3 4 0 d i s k d r i v e . l f t h i s o p e r a n di s
omitted, 5444 is assumed.

Wait for Disk IOS Completion ($WAtT)
T h i s m a c r o i n s t r u c t i o ni s u s e dw i t h t h e g R D D a n d $ W R T D
m a c r o i n s t r u c t i o n s . l t g e n e r a t e st h e c o d e t h a t a l l o w s y o u
t o w a r t f o r c o m p l e t i o no f t h e d i s k I O S o p e r a t i o n .Y o u p r o v i d e t h e l a b e l o f t h e a s s o c i a t e dI O B a n d a n a d d r e s sr o r e c e r v e
c o n t r o l i n t h e e v e n to f a n e r r o r .
l f y o u w i l l n e e dt o u s et h e d a t a i n r e g i s t e 1
r a t a l a t e rt i m e ,
y o u s h o u l d s a v et h e c o n t e n t so f t h a t r e g i s t e rb e f o r e i s s u i n g
t h e $ W A I T m a c r oi n s t r u c t i o n .
T h e f o r m a t o f t h e $ W A I T m a c r o i n s t r u c t i o ni s :
INarn"ll SWAII I

llOB-labell ,FRR-adrlrpss'

l f b o t h r e a d i n ga n d w r i t i n g f o r a p r o g r a ma r e t o b e
p e r f o r m e du s i n ga s i n g l el O B , t h e b i t s o f t h e O - b y t ea r e
a l t e r e dt o i n d i c a t ea n i n v a l i do p e r a t i o n . I n t h i s c a s e y, o u
must set off the bits of the O-bytefor all but the first read
( o r w r i t e ) o p e r a t i o ni n t h e p r o g r a m .
l f y o u w i l l n e e dt o u s et h e d a l a i n r e g i s t e 1
r a t a l a t e rt i m e ,
y o u s h o u l ds a v et h e c o n t e n t so f t h a t r e g i s t ebr e f o r ei s s u i n g
t h e m a c r oi n s t r u c t i o n .
T h e f o r m a t o f t h e $ W R T D m a c r o i n s t r u c r i o ni s :
I N a r n e lI S W R T D I I O B - a d d r e s s , C S - a d d r e s s , N S E C T - n u m b e r
[ , D l s K - 5 4 4 4 / 5 4 4 5I 3 3 4 0 ]

I O B - l a b e li s t h e n a m e a s s i g n e dt o t h e I O B i n t h e g I O B D
m a c r o i n s t r u c t i o n .T h i s s a m eI O B m u s t h a v ep r e v i o u s l y
b e e ns p e c i ife d i n e i t h e ra $ R D D o r $ W R T D m a c r o i n s t r u c t i o n . l f t h i s o p e r a n d i s n o t e n t e r e d ,t h e a d d r e s si s a s s u m e d
'l
to be in regist€r .

E R R - a d d r e s s p e c i fi e s t h e a d d r e s so f t h e r o u t i n e r n y o u r
p r o g r a mt h a t h a n d l e se r r o r sd e t e c t e di n t h e o p e r a t i o n . l f
t h i s o p e r a n di s n o t e n t e r e d n
, o e r r o r c h e c k i n gi s p e r f o r m e d ,
a n d y o u s h o u l d c h e c k t h e r e t u r n c o d e i n y o u r p r o g r a mt o
d e t e r m i n et h e o u t c o m e o f t h e o p e r a t i o n .

M a c r o In s t r u c t i o n S t a t e m e n t s
D i s k D e v i c eS u p p o r t

41

3741 Device Support
T h i s s e c t i o nd e s c r i b e st h e m a c r o i n s t r u c t i o n st h a r s u p p o r t
t h e d i r e c t l y a t t a c h e d3 7 4 1 D a t a S t a t i o n M o d e l 1 o r 2 o r
P r o g r a m m a b l eW o r k S t a t i o n M o d e l 3 o r 4 . T h e f o l l o w i n o
f u n c t i o n sa r e p r o v i d e d :
o

CHN-addressindicatesthe addressof the next DTF in the
c h a i n o f D T F s . l f t h e r e i s n o D T F c h a i n ,t h e o p e r a n di s
o m i t t e da n d X ' F F F F ' i s a s s u m e d .

B u i l d a p r e - o p e nD T F a n d a s s i g ni t s o f f s e t s .
B u i l d t h e i n t e r f a c er e q u i r e dt o r e a d i n p u t r e c o r d sf r o m
t h e 3 7 4 1 d e v i c ev i a a G E T .

a

BUFNO-l /2 allows you to specify either one or two buff e r s . l f t h i s o p e r a n di s o m i t t e d , o n e b u f f e r i s a s s u m e o .

B u i l d t h e i n t e r fa c e r e q u i r e dt o w r i t e o u t p u t r e c o r d st o
t h e 3 7 4 1 d e v i c ev i a a P U T .

T h e D T F s p r o v i d ei n f o r m a t i o n t o t h e d a t a m a n a g e m e n r
r o u t i n e st h a t p e r f o r m t h e i n p u t / o u t p u t o p e r a t i o n s . T h e
interfacesto these operations are provided through the
3741 macro instructions.

Define the File for 3741 ($DTFK)
T h e D T F p r o v i d e si n f o r m a t i o n n e e d e dt o a l l o c a t e ,o p e n ,
a n d a c c e s sa f i l e o n t h e 3 7 4 1 . T h i s m a c r o g e n e r a t e st h e
DTF for this purpose.

UP-maskspecifies the mask to test the eight external
i n d i c a t o r s . T h e c o d e f o r t h e U P - m a s km u s t b e s p e c i f i e d
a s 8 b i n a r y b i t s . F o r e x a m p l e ,t o t e s t b i t s 0 , 3 , 5 , a n d 7 ,
y o u w o u l d e n t e r U P - l 0 0 1 0 1 0 1 . T h e U P - m a s ki s c o m o a r e o
t o t h e e x t e r n a li n d i c a t o r ss e t o n b V t h e S W I T C H s t a t e m e n t
f o r c o n d i t i o n a l l yo p e n i n g f i l e s . l f t h e b i t s t h a t a r e o n i n t h e
U P - m a s ka r e a l s oo n i n t h e e x t e r n a l i n d i c a t o r ss e t o n b v t h e
S W I T C H s t a t e m e n t ,t h e f i l e w i l l b e o p e n e d . l f t h e U P - m a s k
i s a l l z e r o e so r n o t u s e d ,t h e f i l e w i l l b e u n c o n d i t i o n a l l v
ooeneo.
/ V o f e . l n f o r m a t i o n o n s e t t i n ge x t e r n a l i n d i c a t o r s( S W I T C H
statement) can be found in the IBM System/3 Model lS
System Control Programming Reference Manual (Ior
P r o g r a mN u m b e r 5 7 0 4 S C 1 ) . G C 2 1 - 5 0 1 7 . a n d t B M
System/3 Model l5 System Control programming Concepts
and ReferenceManual (for Program Number 5704-SC2).
G C 2 1- 5 16 2 .

T h e f o r m a t o f t h e $ D T F K m a c r o i n s t r u c t i o ni s :
INamei | $DTFK | ruAME-titename,RECL-number,lO-address
t , A C - - L / O [l , R C A D - a d d r e s s [] , B U F N O - i / 2 ]
[ , C H N - a d d r e s s ][ , U P - m a s k ]

Construct 3741 Get lnterface ($GETK)

NAME-filename specifies the name of the f ile. The name
m u s t b e e i g h t c h a r a c t e r so r l e s si n l e n g t h . T h i s o p e r a n d
m u s t b e s p e c i fi e d .

T h e $ G E T K m a c r o i n s t r u c t i o ng e n e r a t e st h e i n t e r f a c en e e d e d t o c o m m u n i c a t ew i t h t h e 3 7 4 1 d a t a m a n a g e m e n w
t hen a
r e c o r d i s b e i n g r e a d f r o m t h e 3 7 4 1. f o u s e t h i s m a c r o
i n s t r u c t i o n ,c o n s t r u c t a 3 7 4 1 D T F f o r t h e f i l e a n d u s et h e
$ D T F O m a c r o i n s t r u c t i o nt o e s t a b l i s ht h e o f f s e t sf o r t h e
D T F . Y o u m u s t a l s o p r o v i d e a n E X T R N s t a t e m e n tw i t h

R E C L - n u m b e rs p e c i f i e st h e d e c i m a l l e n g t h ( f r o m 1 t o 1 2 8 )
o f t h e l o g i c a lr e c o r d . T h i s o p e r a n d m u s t b e s p e c i f i e d .

t h e l a b e l $ $ C P I Pt o u s e t h i s m a c r o . l f y o u w i l l n e e d t o
u s e t h e d a t a i n r e g i s t e r2 a t a l a t e r t i m e , y o u s h o u l d s a v e
t h e c o n t e n t so f t h a t r e g i s t e rb e f o r e i s s u i n gt h e $ G E T K
macro instruction.

lO-addressprovides the addressof the leftmost byte of an
a r e ai n m a i n s t o r a g et h a t c o n t a i n st h e b u f f e r s a n d t h e l O B .
T h i s o p e r a n dm u s t b e s p e c i f i e d . T h e a m o u n t o f s r o r a g e
must be the record lengthplus 26 times the BUFNO.

T h e c o d e g e n e r a t e db y t h i s m a c r o i n s t r u c t i o ng i v e sc o n t r o l
t o t h e d a t a m a n a g e m e n tr o u t i n e . T h e d a t a m a n a g e m e n t
r o u t i n e c o m p l e t e se x e c u t i o n a n d r e t u r n sc o n t r o l t o t h e
generatedcode.

A C - l / O s p e c i fi e sw h e t h e r t h e D T F i s i n p u t o r o u t p u t . l f
t h i s o p e r a n di s n o t s p e c i f i e d ,i n p u t i s a s s u m e d .

RCAD-addressspecifiesthe addressof the leftmost byte
o f t h e l o g i c a lr e c o r d . l f t h i s o p e r a n d i s n o t e n t e r e d ,
X'FFFF'isassumed.

48

The format of the $GETK macroinstructionis:
tNamell $Cerrcl eOf-aOOress
[,DTF-address]
[,ERR-addressl

EOF-address
specifiesthe addressin your programthat
receives
controlwhen the end of file is detected.This
operandmust be specified.

DTF-addressindicatesthe addressof the leftmost byte of
the DTF for this file. lf this operandis not specified,the
addressis assumed
to be in register2.

ERR-address
suppliesthe addressin your progr.amwhere
control is passedif the controlledcanceloption is taken in
response
to a permanentl/O error. lf this operandis
omitted,no codeis generated
to checkfor the controlled
cancelcompletioncode.

Construct 3741 Put lnterface ($pUTK)
The $PUTK macroinstructiongenerates
the interfaceneeded
to put a recordon the 3741. You must providea DTF for
t h e f i l e a n d u s et h e $ D T F Om a c r oi n s t r u c t i o n
to establish
the offsetsin the DTF. You must alsoprovidean EXTRN
statementin your programwith the label$$CpOpto use
t h i s m a c r o . l f y o u w i l l n e e dt o u s et h e d a t ai n r e g i s t e2r
at a latertime, you shouldsavethe contentsof that register
beforeissuingthe $PUTK macroinstruction.
The codegenerated
by this macroinstructiongivescontrol
to the data management
routine. The data management
routinecompletesexecutionand returnscontrol to the
generated
code.
The format of the $PUTK macroinstructionis:
lNamell $PUTK| [D-Ir-aodress][,ERR-address]
DTF-address indicates the address of the leftmost byte of
t h e D T F f o r t h i s f i l e . l f t h i s o p e r a n d i s n o t s p e c i f i e d ,t h e
addressis assumedto be in register2.

ERB-addresssuppliesthe addressin your program where
control is passedif the controlled cancel option is taken in

Tape Device Support
T h i s s e c t i o nd e s c r i b e st h e m a c r o i n s t r u c t i o n st h a t s u p p o r t
t h e I B M 3 4 1 0 1 3 4 1 1M a g n e t i cT a p e S u b s y s t e m . T h e f o l l o w .
i n g f u n c t i o n sa r e p r o v i d e d :
o

B u i l d a p r e - o p e nD T F f o r t a p e a n d a s s i g nt t s o f f s e t s .

o

B u i l d t h e i n t e r f a c e sr e q u i r e dt o r e a d i n p u t r e c o r d sf r o m
a t a p e d e v i c ev i a a g e t o r a r e a d .

o

B u i l d t h e i n t e r f a c e sr e q u i r e dt o w r i t e o u t p u t r e c o r d st o
a t a p e d e v i c ev i a a p u t o r a w r i t e .

o

B u i l d t h e i n t e r f a c er e q u i r e dt o i s s u et a p e c o n t r o l
commands.

o W a i t f o r c o m p l e t i o n o f r e a d ,w r i t e , o r t a p e c o n t r o l
operations.
The tape DTFs provideinformationto the tape data mana g e m e n tr o u t i n e st h a t p e r f o r m t h e i n p u t / o u t p u t o p e r a t i o n s .
T h e s eo p e r a t i o n sa r e p r o v i d e d t h r o u g h t h e t a p e s u p p o r t
macro instructions.

Define the File for Tape ($DTFT)
T h e D T F p r o v i d e si n f o r m a t i o n n e e d e dt o a l l o c a t ea n d o p e n
a t a p e d e v i c e . T h i s m a c r o i n s t r u c t i o ng e n e r a t e st h e c o d e
that builds the tape DTF. SeeAppendix B: Def ine the
File Control Blocks for a description of the pre-open and
p o s t - o p e nD T F s .
T h e f o r m a t o f t h e $ D T F T m a c r o i n s t r u c t i o ni s :

INamel| $DTFT I NAME-filename,tO-address,BLKL-number,
R E C L - n u m b e r[ , U P - m a s k ][ . A C - t N / O U T ]
[ , C H N - a d d r e s sL]B A S I C - Y i NJ
I , R C A D - a d d r e s st l, M O D E - 6 C A T E / M O V E I
[,MBUFF-Y/N
] [.RECFM-code]
[ , L l O A - n u m b e r t] , S P A N - Y / N lt . C O D E - A / E l
[ , O S E T - B / n u m b e r[], E N D c o d e ] [ . M V F - Y / N ]

NAME-filename is a required operand specifying the name
o f t h e t a p e f i l e . T h e f i l e n a m ec a n b e u p t o e i g h t c h a r a c t e r s
i n l e n g t h a n d m u s t b e t h e s a m ea s t h e n a r n eo f t h e / / F I L E
statement.

responseto a permanent l/O error. lf this operand is
omitted, no code is generatedto check for the controlled
cancel completion code.

Macro Instruction Statements

49

lO-addressspecifies the addressof the leftmost byte of the
m a i n s t o r a g ea r e au s e dt o c o n t a i n a l l b u f f e r s a n d l O B s . T h i s
o p e r a n d i s r e q u i r e d . T h e l e n g t h o f t h e a r e as p e c i f i e db v

A C - l N / O U T s p e c i fi e s t h e t y p e o f f i l e . l N s p e c i fi e sa n i n p u t
f i l e ; O U T , a n o u t p u t f i l e . l f t h i s o p e r a n d i s n o t e n t e r e d ,l N
(input) is assumed.

t h i s a d d r e s si s s p e c i f i e di n t h e L I O A o p e r a n d .

Noti:: l{ basic data managententroutines are used to
p r o c e s st h e f i l e , t l r i s o p e r a r r ds h o u l d p o i r ) t t o a 4 0 _ b v t e
area
to containthe tape lOB.

BLKL-number is a required operand that specifiesthe decim a l b l o c k l e n g t hf o r t h e f i l e . T h e m i n i m u m b l o c k l e n g t h
a l l o w e d i s 1 8 b y t e s . i f a s h o r t e r l e n g t h i s s p e c i f i e d ,1 g i s
a s s u m e d . F o r f i l e sw i t h f i x e d - l e n g t hr e c o r d s ,t h e b l o c k
l e n g t h m u s t b e a m u l t i p l e o f t h e r e c o r d l e n g t h ;f o r f i l e s w i t h
v a r i a b l e - l e n g t rhe c o r d s ,t h e b l o c k l e n g t h m u s t e q u a l t h e
l e n g t h o f t h e l o n g e s tr e c o r d p l u s e i g h t .
N o t e : l f b a s i ct a p e d a t a m a n a g e m e n it s u s e d .t h e b l o c k
l e n g t h i n t h e D T F ( $ D F B K L ) m u s t b e u p d a t e da f t e r t h e f i l e
i s o p e n e da n d b e f o r e a n y r e a d o r w r i t e o p e r a t i o n i s p e r _
f o r m e d . T h e f i e l d m u s t a l s ob e u p d a t e db e f o r ea n y s u b s e q u e n t r e a do r w r i t e i f t h e l e n g t h u s e d i s d i f f e r e n t t h a n t h e
p r e v r o u sr e a d o r w r i t e .

R E C L - n u m b e r i s a d e c i m a l v a l u es p e c i f y i n gt h e l e n g t h o f a
l o g i c a lr e c o r d i n t h e f i l e . l f v a r i a b l e - l e n g t rhe c o r d sa r e u s e d
f o r t h e f i l e , t h e r e c o r d l e n g t h s p e c i f i e dm u s t b e e q u a l t o t h e
l o n g e s tr e c o r d p l u s f o u r . T h e m i n i m u m r e c o r d l e n g t h w h e n
v a r i a b l e - l e n g t rhe c o r d sa r e u s e d i s f o u r , w h i c h r e s u l t si n
z e r o - l e n g t hr e c o r d s . T h e m i n i m u m r e c o r d l e n g t h f o r f i l e s
u s i n gf i x e d - l e n g t hr e c o r d si s 1 8 . T h i s o p e r a n d i s r e q u i r e d .

UP-mask specifiesthe mask to test the eight external
indicators. The code for the UP-nraskmust be specified
a s 8 b i n a r y b i t s . F o r e x a m p l e ,t o t e s t b i t s 0 , 3 , 5 , a n d 7 ,
y o u w o u l d e n t e r U P - 1 0 0 1 0 1 0 1 . T h e U p - m a s ki s c o m p a r e d
to the external indicators set on by the SWITCH statement
f o r c o n d i t i o n a l l yo p e n i n gf i l e s . l f t h e b i t s t h a t a r e o n i n
t h e U P - m a s ka r e a l s oo n i n t h e e x t e r n a l i n d i c a t o r ss e t o n b y
t h e S W I T C H s t a t e m e n t ,t h e f i l e w i l l b e o p e n e d . l f t h e
U P - m a s ki s a l l z e r o e so r n o t u s e d ,t h e f i l e w i l l b e u n c o n d i tionally opened.
Note: lnformation orr setting external indicatr:rrs{SWITCH
statement) can be found int-he IBM Svstem/3 Modet lS
System Control Programming Reference Manual for prog r a m N u m b e r 5 7 0 4 - S C 1, G C 2 | - 5 O 7 7 , a n d I B M
System/3 Model l5 System Control Programming Concepts and Reference lVlanual for Program Number 5704-

sc2. GC21.5162.

N o t e : T h e o p e r a t i o nc o d e i n t h e T a p e D T F w i l l b e i n i t i a l i z e d a c c o r d i n gt o t h e e n t r i e ss p e c i f i e d( o r d e f a u l t s )o f t h e
A C a n d B A S I C o p e r a n d s ,a s f o l l o w s :

AC-IN

AC-OUT

BASIC-Y

R e a df o r w a r d

Write

BASIC.N

Get

Put

CHN-addressspecifiesthe addressof the next DTF in the
chainof DTFs. lf there is no DTF chainor if this DTF is
t h e l a s t D T F i n t h e c h a i n , t h i s o p e r a n ds h o u l d b e o m i t t e d
andX'FFFF'assumed.

E A S I C Y t ' N s p e c r f i e sw h e t l r e rr i r i s t ) ' f - Fu s e st h e b a s i ca c c e s s
m e t h o d . l f t l r i s o p e r a r r di s r r o t e n t e r e d ,N ( n o ) i s a s s u m e d .
lVotes'
1 " B A S I C Y n t u s r b e s p e c i f i e di { a n y o f t h e f o l l o w i n g m a c r o
r n s l . r L t { : t i oai lrse u s e d t o t . r r o c e sf sh q f i l e : $ R D - f , $ W n f f ,
$CfLl or $W'tT.
2 . l f y o u p r o c e s sA S C I I f i l e s u s ; i n qt f r e b a s i ca c c e s sm e t h o d ,
y o u m u s t t f a n s l a t et h e c h a r a c t e r si n y o u r p r o g r a m .
3 . M u l t i v o l u m e f i l e s a r e s u p p o r t e dw i t h t h e h a s i ca c c e s s
rnethoclb
, u t t h e E X T R N s t a t e m e n tt h a t i s p r o v i d e d
must be $$BTMM for multivolumesupport. $$Afnvl
and $$BTMM should not be r-rsedirr tfre same program.
$ $ S f M M s u p p o r t sb o t h s i n g l ea n c lm r r l t i v o l r - r mfei l e s .
4 " D e f e r r e dc p e r r i s r r o t a l l o w e < w
J i t h t h e b a s i ca c c e s s
method.
RCAD-addressspecifies the syrrrbolicrr:corclarea ;rdr:lress.
-Ihis
o p e r a n c il s r e q u i r e df o r a l l o p e r a t i o r r su s i n gt h e b a s i c
a c c e s sm e t h o d . l f s t a n d a r dd a t a r n a r r a g e f i r e ni st u s e r j ,t h i s
o p e r a n d i s r e q u i r e df o r a n o u t p u t o p e r a t i o n a n c lf o r a n
i n p u t o p e r a t i o nu s i n g m o v e m o c l e .

M O D E - L O C A T E i M O V F i r r d i r ; a t ew
s l r e t h e rt h e l o 6 6 1 sm 6 6 s
o r m o v e r n o d e i s u s e d . l { t h i s o p r e r a n ci sl r r o t s p e c i f i e d ,
f u l O V Ei s a s s u r n e d .W h e n l o c a t e r n o d e i s s p e r : i f i r : ctJl r,e r e c o r d
a d d r e s s( R C A D - a d d r e s si)s s e t t r . lt h r : a c i c i r e rosf t l r e r r : c o r d
i n t h e b u f f e r . W h e n m o v e m o c l r :i s L r s e dr.e < ; o r r lasr e r r l o v e o
fronr the lrr-rffertr-rthe locatiorr sltecifieclbv tht recorr:

M B U F F - Y / N i n d i c a t e sw h e t h e r r n o r e t l t a r r . r r r i:rrr r f r : r j , r
u s e d . l f t h i s o p e r a n d i s n o t s p e c i f i e d ,N ( r r o ) i s a s s u r r r e r l .
^fhe
n u m b e r o f b u f f e r s i s d e t e r r n i r r e rb_yl l l t r : l o r r q t l ro f t l r e
l / O a r e a ,s p e c i f i e db y t h e L I O A o p e r a n c l .. l i r i s o l r r : r a r r r r
s h o u l d n o t b e u s e di f B A S I C Y i s s p r : c i 1 i e r i .

L I O A - n u n t b e r i s t h e t o t a l r - l e c i r r r lael n g l h o f t l r e l / O a r e a i f
m o r e t h a n t w o b u f f e r s a r e r e q u i r e c (l t v l U L j F Fy ) . l f t t r e
n u m b e r s p e c i f i e di s z e r o o r i f t i r i s e n t r y i s r . r r r r i t r c rt iw, c r
b u f f e r sa r e a l l o c a t c di n t h e l / O a r e a l f t h i s e r r r r yi s r r r , , l
z e r o , a s m a n y b u f f e r s a s p o s s i b l ea r e a l l o c a t e di n t h e l , / O
area.
T h e f o l l o w i n g f o r m u l a c a n b e u s e ctl o r J e t e r n r i r rrei r e l e r r g t h
of the l/O area:
L e n g t h o f t h e l / O a r e a . = ( 4 0 r b l o c k l r : n c l t l rt)i r r r e s
(nrrmbeo
r f brrffprsi
T h i s o p e r a n ds h o u l d n o t b e u s e d i f B A S I ( ) Y i s s l r e c i f i e d .

S P A N - Y / N s p e c i f i e sw l r e t l r e rs p a n n e crl e c o r r l sa r n L r s t _ . r l1i .
s p a n n e dr e c o r d sa r e u s e d ,B A S I C Y r r r u s ta l s o l r r :s P r : r ; i f i l r t l .
l f t h i s o p e r a n d i s o m i t t e d , N ( n o ) i s a s s r . r r r r r :Sr ,p1, ., r c i f y i n g
S P A N Y c a u s e st h e s p a r r r r e rt le r : r i r db i t i r r t l r r rt i r 1 . ;le; r t r | lt o
b e s e t o n . W h e n y o u u s e S P A N . Y , y o u n ) l . r i ti | a r i I l r r :r B C ordsfrom block to block.

a d r l re s s "
L o c a t e m o c l ei s v a l i d o n l y f o r i r i p u t f i l r : s . l l r i c o t r a r a n r j
s h o u l t ln o t b e u s e d i f B A S I C Y i s s r : e r ; i e
f rJ

C O D E - A / E s p e c i fi e sw h e t h + : rt l r r : I i l r rr s a r r F U { ] i t l O f i l t : o r
A S C I I f i l e . l f t h e f i l e i s a n F B C D I C f i l e , s p r - - r - :Ci tO
y DE l:
l f t h e f i l e i s a n A S C I I f i l e o r c a r rh e r : i l l r e rA S O I I o r E B C D I C ,
s ; . r t r c iC
f yO D E - A . l f t l r i sr t p e r a r r it sl r r o t l r r t l r : r l _ F i s
assurne(l _

RE(.:FlVl-t:ttde
specifies the reccrcl fornr;11rrst:tlior tlrr_,
{i1e.
T l r , '' : o d c sa n d t h e i r n r e a r r i r r q
a sr r :
Code

Record Format

F
FB

F i x e c l ,E B C D I Co r A S C I t
Fixed blocl >

E

n

P

e

I'
*!
;

;;

6 . o
'

,

n

g E€
3 " >

d : Y

E
;:
m

Y

GC21-7608-2

L

7

€sfi
€ : ;
l

l

=

C

E E

A 3 F

=
F

v
c

-":ifs;
a
h

F

c
a

E fp

*;

> ;

o

E ; :

= o

i ? : 3

o E : " P

e E

t

= E E: E g €sF

,5.

i

l: 5*a:
9 . eE s t E I

9E !€i3

E : ; i r S i :s
i a
=

8
a
c

ttt
o

t : : 3

€ E: E
;ng
F
E i E i $
: G o =

"9^fr,
i F

o
o
.2

a

=
o

?
z

o
!

; !

LlJ

E

€ =
o :

so 9^
c

: -

;

v

>
=

E E
e l l

o
Z

*L .x

C

E ;

:Y

8 F

o
- =L

;
a

9 :
-

O

5 6

Ea

. 9 :
! F

: €

o..9
>;

.

:

H

i;

o

f
=

E
A

6
.9

F

X

o
,F

6

;€

3' ,i

: ; ;

, 9
E

I
\

.!
b

g
{

ET E
E €
6
f i

;E
3,;

b

e :

flg 'i
.{s
o . 6

,
J
!

Ea :€
' : 6E

{

U

=

o

.

:

-

a

E

}

-

6

F

O

I

::
o

\

€

:

I

I
I
I

GC21-7608-2

II
o

,
E
l

T
l
o

II
I
I

I
I

I
I
I

I
I

Fold

Fold

II

I
I

FIRSTCLASS

II

P E R M I TN O . 3 8 7

II

R O C H E S T EM
R ,I N N .

II

-

B U S I N E S SR E P L Y M A I L
NO POSTAGE STAMP NECESSARY IF MAILED IN THE UNITED STATES

POSIAGE WIIT 8E PAID BY

r 6

-I

--

r <
l u t

l ( D
t

r1

-I

IBM Corporation
GeneralSystemsDivision
DevelopmentLaboratory
Publications,Dept. 245
Rochester,Minnesota55901

\

l o )

-

t

o

, z
I 9
ct

i P

l' (c ,D

I
!

d
t Fold

Fold

I (t,F

I P
Ir 6 )
' O

t \

t r I
l 6 )
,
I
I
I

In'ternationalBusinessMachinesCorporation
SystemsDivision
Gelneral
5775D GlenridgeDrive N.E.
Atlanta, Georgia30301
( U S AO n l y )
Gelneral
Business
Group/ International
44 South Broadway
White Plains,New York 10601

u. s.A.
( | nternational
)

o

@
N

IBM System/3Modet15
SystemControl ProgrammingMacros
Reference

. E
tr
E

GC21-7608-2

9
J ca - X
6 > >
P $ - o

o

3 E €

F
Y

g

-

e
m

-

:

,

R u ;

L

*

:

:

= . Y
c E
3 0
-

o

Y

:

-

l

; 6 9
- : E
! : ;

t

=

c

E A A 3 F

:.; fs;
7

s

o

c O ! L

? c

ie1

.9:E'

:*

E
; :
E o e ;
'Pt':i

>
i
( D - n

=
5

F

2

o f

;

?

uJ
<

E

I

?

o
o
l

E
"

@

: E : f i € EF
i : 5 * a EI

l !
-

c

l - t r -

F h

oc
rrJ
o
ur
E

=

^

.

l l = > 6

:

,

P

9E

o-

-

.2

' oE .g EF ' : E
=

3

r
.

o

o

o

o
:

I

-

=

F

J
o
o

c

3 a t : 3 3 a

t s E i ;Esi g$
F E F
:]i6.,s

,;E
:X
; !
=€o ==

l

r-r

o

P

l

E

2

o :

j

s 9
F v
: *

d
o
z

t ;
- i
8 F

=.=

F1'
L

X

6
L

=

-

9.:
:

6

j

F

;

=

o

c

6 6

o

E

8 e ' E

o

J

Q

O

q,.9
>;

6
.9

= E
E O

=

O

X

6

}

.\

b:

.9

;;
; ;

.e i
\
E

P

q

@

E *
:F

3

o
.g

8 d

i

-

.

:

,

=

!

-

=

>

E

9

\

a

<
P.

g;. 6 {
eri ,i

o - 6

r
J

o
f

F'

E:E
>lt

c

E

4
H

'€: E
6

{

E

v

i

i
l

G

,

j

z
o

o

I
I

I
I

GC21-7608-2

I
l

T
o

I
I
I
I
I
I
II
FIRSTC!"ASS

II

P E R M I TN O . 3 8 7

I

ROCHESTEM
R ,I N N .

I

I
-

B U S I N E S SR E P L YM A I L
NO POSTAGE STAMP NECESSAFY IF MAILED IN THE UNITED STATES

P O S T A G EW I I . I . 8 E P A I D B Y

t @-

TI

r

r-

rt a3

I-I

t

4

rIII
II

IBM Corporation
G e n e r aS
l y s t e m sD i v i s i o n
Development Laboratory
Publications,Dept. 245
Rochester,Minnesota55901

I

\
| (.)
t

, 3

I-

t
t

rEI

, z
I 9

-

o

(t

i ?

,
'l (ct)

I
!

(D

Fold

l

=

t

-

?
t >
t

!

I

r o
, o
l N
r t r
o

EE-==-

-;:=:

,
I

=

InternationalBusiness
MachinesCorporation
GeneralSystemsDivision
5775D GlenridgeDriveN.E.
Atlanta,Georgia30301
( U S AO n l y )
GeneralBusiness
Group/ lnternational
44 South Broadway
White Plains,New York 10601

u. s .A .
( | nternational
I

I
I
I
I

@
N



Source Exif Data:
File Type                       : PDF
File Type Extension             : pdf
MIME Type                       : application/pdf
PDF Version                     : 1.4
Linearized                      : No
Page Count                      : 144
Producer                        : iText 2.0.3 (by lowagie.com)
Modify Date                     : 2010:07:04 14:32:21+02:00
Create Date                     : 2010:07:04 14:32:21+02:00
EXIF Metadata provided by EXIF.tools

Navigation menu