GC28 6698 3_TSO_Option_Guide_Rel_20.1_Jun71 3 TSO Option Guide Rel 20.1 Jun71

GC28-6698-3_TSO_Option_Guide_Rel_20.1_Jun71 GC28-6698-3_TSO_Option_Guide_Rel_20.1_Jun71

User Manual: GC28-6698-3_TSO_Option_Guide_Rel_20.1_Jun71

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

DownloadGC28-6698-3_TSO_Option_Guide_Rel_20.1_Jun71 GC28-6698-3 TSO Option Guide Rel 20.1 Jun71
Open PDF In BrowserView PDF
File No. S360- 20
Order No. GC28-6698-3

.Systems Reference Library

IBM System/360 Operating System:
Time Sharing Option Guide
This publication describes the concepts, features
and implementation of TSO, a general purpose
time-sharing facility operating under the MVT
configuration of the control program. This manual
is intended for those who design, generate, and
maintain a TSO installation. Topics discussed
are:
• The capabilities and advantages of time
sharing in general and TSO in particular.
• The programming languages and system
facilities available to a TSO terminal user.
• The system configurations TSO requires.
• How to generate and maintain a TSO system.
• The Program Products available with TSO.
The prerequisite publication is:
IBM· System/36 0 Operating system:
GC28-6720.

MVT Guide,

OS

I FoUrth

Edition (June, 1971)

This is a major revision of, and obsoletes, GC28-6698-2.
Changes to text and illustrations are indicated by a
vertical line to the left of the change.

This edition applies to release 20.1, of IBM System/360
operating system, and to all subsequent releases until
otherwise indicated in new editions or Technical Newsletters.
Changes are continually made to the information herein;
before using this publication in connection with the
operation of IBM systems, refer to the latest IBM Systern/360
SRL Newsletter, Order No. GN20-0360, for the editions that
are applicable and current.
Requests for copies of IBM publications should be made to
your IBM representative or to the IBM branch office serving
your locality.
A form for reader's comments is provided at the back of
this publication.
If the form has been removed, comments may
be addressed to IBM Corporation, Programming Systems
Publications, Department D58, PO Box 390, Poughkeepsie, N. Y.
12602

© Copyright International Business Machines Corporation 1969,1970,1971

Preface

The Time Sharing Option 1s a general
plrpose time-sharing facility for the MVT
configuration of the operating system~
This manual is an introducti on to TSO for
the system manager, system analyst, and
system programmer. It helps those with
system responsibilities to evaluate the
capabilities of TSO, and to design and
implement a TSO configuration.
The first part of this publication is a
functional description of TSO" covering:

Planning for the Telecommunications
Access Method (TeAM), GC3O-2020.
storage Estimates" GC28-6551.
TCAM Programmers Guide and Reference
Manual.
For more detail on specific components or
subjects discussed in this publication, the
following publications may be of interest.
For system operation and management:

• The advantages of a time-sharing
system, the system environment required
for TSO" the relationship of TSO to:the
operating.system, and the capabilities
of the command language,.

IBM System/360 Operating System:

• The facilities available through the
command langUage .•

For I/O devices and control units:

• The facilities available through IBM
Program Products for TSO.
The last three chapters of the manual givk
implementation planning infor.mation:
• A discussion of
have been added
program.
• A discussion of
techniques •
• A discussion of
requirements,.

the TSO routines that
to the MVTcontrol

operator' s Reference., .GC2 8-66 91.
System Management Facilities, GC28-6712.

IBM 2701 Data Adapter Unit" Component
Description, GA22~6864.
IBM Component Description, 2702
Transmission COntrol" GA22-6846.
IBM 2703 Transmission Control" Component
Description, GA27-2703.

implementation

IBM 2741 communications Terminal,
GA24-3415.

TSO storage

IBM 1050 system Summary,. GA24-3471,.

There are four appendixes,.
• A list of the TSO commands by function.
• A list of the IBM Program Products
available for TSO users" and references
to further documentation for them.
• A list of the Time Sharing Driver Entry
Codes.
• A list of terminal messages requiring
installation action.
• A glossary of terms.

IBM Component Description, 2260 Display
Station -- 2848 Display Control,
GA27-2700.
Program Product references are included in
Appendix B,.
Note: For planning purposes" this manual
includes information for components and
capabilities that have been announced for
availability after the delivery date for
the Time Sharing Option. See your local
IBM representative for the availability
dates for:
• TSO with Model 65 Mul tiprocessing'!I

Readers interested in the implementation of
the system should be familiar with the
information in:

• PL/I Optimizing Compiler Program
Product,.

IBM· System/360 operating System:

• ASCII capability for the TSO Data
utili ties Program Product,.

MVT Guidg, GC28-6720.

• OS PL/I Checkout Compiler,.

Preface

3

Contents

SUMMARY OF MAJOR CHANGES '. '. •
Release 20.1
GC28-6698-2
Release 20.1
GC28-6698-3

7
7
7

INTRODUCTION •
'. '. • '.
Advantages of a Time Sharing system
Using a Terminal • • • • • • • • • •
starting and Stopping a Terminal
Session • • • • • • • •
Working at the Terminal
• •
System Configuration • • • •
Terminals • • '. • • • •
Transmission Control Unit
Swap Data set Devices
The Relationship of TSO to the
Operating system • • • • '. • • •
•
Execution of Background Jobs from
the Termina 1 • • '. • • • • •
•
Foreground-Background Compatibility
Restrictions and Limitations •
system Control • • • '. '. • • • • • •
Job Definition and Scheduling
Tuning the Time Sharing System • • •
Monitoring System Use and Performance •
System Security
• •
User Verification • • • •
Program Protection
Data Set Security
••
Authorizations • •
Capabilities of the TSO Command
Language • • • • • • •
IBM Program Products • • • •
Problem-solving • • • •
'• •
Programming • • '. • '. •
Text and Data Handling •

9
9

COMMAND LANGUAGE FACILITIES
Conventions at the Terminal • • ' . .
Logging On • • • •
Input Editing • • • •
Entry Modes
The Attention Key
Data Set Naming Conventions
Data Entry • • • • • • • • •
Creating Data Sets • •
Entry Modes for EDIT • •
Input Mode • • • • • •
Edit Mode • • • • •
Modifying Data sets • • • •
Data Set Management Commands
TSO Data Utilities • • • • •
Text-Handling • • • • •
Data set Manipulation • • •
Compiling and Executing Programs
Remote Job Entry • • • •
System Control,. • • •
User Authorization • •
System Operation •
Command Procedures
Other Commands
PROGRAMMING AT THE TERMINAL

•
• •
•

• •
• •
• •

11
11
11
12
12
12
13
13
14
14
14
15
15
15
15
16
16
17
17
17
17
18
18
19
19
20
20
20
21
21
21
21
22
22
23
23
23
23
23
24
24
24
25
25
26
26
26
26
27
28

COBOL • • • • • '. '. • • • • • •
Entering the Source Program
Compiling a COBOL Program
Program Execution
Interactive Programs • • • •
A COBOL Example • • • • • '.
FORTRAN • • • • • • • • • '. • •
Entering the Source Program
Compiling a FORTRAN Program
Testing FORTRAN Programs • •
PL/I • • • • • • • • • • '. '.
Entering a PL/I Program • •
Compiling a PL/I Program • •
Program Execution • • • • •
Assembler Language • • • •
Assembling the Program
Test Mode • • • •
Other Compilers
A Compiler Command Procedure
Nested Procedures
PROBLEM SOLVING
ITF: BASIC • '. • •
ITF: PL/I
Code and Go FORTRAN

'.
• •
• •
• • • •
•
• •
' . . • '.
••
•
• •
• •
• •
•
'• • • •
• •
•
•
•
•

28
29
29
30
30
31
34
34
34
35
35
36
36
36
36
36
36
37
37
38

•
•
•
•

40
40
41
42

SYSTEM SUMMARY,.
• • • '. •
• •
The Time Sharing Driver
• • •
Control Routines • • • • • •
• •
The Time Sharing Control Task • • •
The Region Control Task
•
LOGON/LOGOFF • • • ,.
•
The Terminal Monitor ~rogram • • • •
TEST • • • • • • •
•
Service Routines •
• •
Command Processors and User
Progr ams '. '. • • •
• •
Terminal I/O '. ,.. • •
•
The Message Control Program
Mixed Environment MCP's
••
Message Control Program Interfaces •
Multi-Terminal Message Processors •
overview and Storage Map •
• •
Time Sharing Algorithms • • • '.
• •
Time Slices
Major Time Slices • • • • •
Minor Time Slices
'.

45
46
46
47
47
48
49
50
50

SYSTEM IMPLEMENTATION
• • • •
Tailoring a Message Control Program
Mixed Environment MCPs • • •
• •
TSO-Only MCP '. • • • • '. ,. '.
• •
LINEGRP Macro Instruction • • • • •
LISTTA Macro • • '. • • •
• •
TSOMCP Macro • • '. • • •
•
Writing Cataloged Procedures for TSO • •
Message Control Program
Time Sharing Control Task
•••
Background Reader (BRDR) ,. •
• •
TSO Trace writer • • • • • •
Logon cataloged Procedure
• •
TSO System Parameters • • • • •
• •

62
62
62
62
63
66
66
70
70
70
72
73
73
74

Contents

5

52
52
52
52
52
53
55
57
57
58
60

The Time Sharing Control Ta~k
Parameters .. • .. '. • ,.. '.
74
Driver Parameters ,. • • • '.
75
Buffer Control Parameters
• 75
System Parameter Format ...
• 76
Tuning the Time Shar ing Driver '.
80
Using. TSO Trace • • ,.
• ,... '. '. 80
Writing Installation Exits for the
82
SUBMIT Command • ,' . . '. • •
writing Installation Exits for the
OUTPUT status" and Cancel Commands •
83
Writing a LOGON Pre-Prompt Exit
83

Foreground Region Requirement,., • • •
Auxiliary Storage Requirements •
•
swap Data sets • • • • '. ' '. ' . . '.
system Libraries and Data Sets
•

STORAGE ESTIMATES '. '. . . .
Main Storage Requirements
•
MVT Basic Fixed Requirement
••
Nucleus • • • '. • • • •
Master Scheduler Region. '.
• •
Link Pack Area '. ,. • '. '...
System Queue Area ' . . • • • '. ..
Message Control Program Requirement •
Time Sharing Control Region
Requirement • '. • • • .. •
• • • '.
Dynamic Area Requirements

APPENDIX B:

PROGRAM PRODUCTS

APPENDIX C:

DRIVER ENTRY CODES

'e.'.,...

87
87
87
87
87
87
87
88
88
88

APPENDIX A: TSO COMMANDS
Data Management
Language Processors
Program Control
Remote Job Entry •
System, Control. '.
Session Control • • • • • •

88
88
88
89

• '90
• 90
90

• 91
• • • 91
91
• • 91
92
. . . . '. 93

APPENDIX 0: TERMINAL MESSAGE REQUIRING
INSTALLATION ACTION ... '. '. '. • ,.. • • 97
APPENDIX E: MESSAGE CONTROL PROGRAM
ASSEMBLY DIAGNOSTIC ERROR MESSAGES • • .108
APPENDIX F:

GLOSSARY

INDEX

• • • 111
• .118

Illustrations
'Figures
Figure 1. Simple Identification
Scheme
'........'.......
•
Figure 2,. User Identification
Hierarchy,. • • • .. '. • • • '. • •
•
Figure 3,. Example of Data Set Naming
Conventions • • • • • • • • • ,'. • .. '. •
Figure 4.. Program Control Commands
•
Figure 5. A Command Procedure
Figure 6,. Entering a COBOL Program
•
Figure 7. Compiling a COBOL program •
Figure 8. Defining the Terminal as a
File •
• ~ .. • • • .. • • • • • .. • •
Figure 9,. A Terminal Session
creating a COBOL Program (Part 1 of 2) •
Figure 10,. FORTRAN Syntax Checker
Diagnostic
.....................
Figure 11. Sample of FORTRAN compiler
output
' . . '. ,. '. • ,. • '. • • • • • • •
Figure 12. A Command Procedure to
Invoke the PL/I (F) Compiler
.. '. .. .. •
Figure 14. Implicit use of Procedure '.
Figure 13,. Use of a Command Procedure
FigUre 15,. A Command Procedure' to
Invoke a User Program • • • • • '. • ' . .
Figure 16. A Command Procedure for a
Compile-Load-Go Sequence • • • • • • • •
Figure 17. Using a compile-Load-Go
Command Procedure • • '. • • • '. '. '. • •
Figure 18. ITF: BASIC Sample Session
Figure 19,. ITF: PL/I Sample Session
Figure 20,. Code and Go FORTRAN Sample
Session
• '. '. • '.'. • • • • • •
Figure 21. TSO Control Flow Diagram
•
Figure 22,. The Time Sharing Driver • •
Figure 23. The Time Sharing Control
Task
• ,. '. • • '.
• • ,. • ,. '.
6

20

21
22
25
27
29
30
31
32
34
35
38
38
38
39
39
39
41
42
44
45
46
47

Time Sharing Option Guide (Release 20.1)

Figure 24. The Region Control Task • •
Figure 25. The LOGON/LOGOFF Scheduler
Figure 26. LOGON Linkage '. • • • .' • •
Figure 27. Terminal Monitor Program
•
Figure 28,. Service and TEST Routine
•
Figure 29,. TCAM Message Control
PrOCJram
•
Figure 30. system Overview
• •
Figure 31. Typical Main storage Map
'.
Figure 32,. Queue Service Time
•
Figure 33,. Minor Time Slice
Figure 34. Job Stream to Tailor MCP
•
Figure 35. Sample MCP '. • • .. •
Figure 36,. sample MCP
• •
Figure 37. sample MCP start
Procedures
'. .. • • • •
Figure 38. sample Cataloged Procedure
to Start Time Sharing Control Task
••
FigUre 39. Sample Background' Reader
(BRDR) Procedure
• • ' . . • • • '. •
FigUre 40.. Sample TSO Trace Start
Procedure ... • '. '. '. • .. • .. .. .. '. '. •
Figure 41. Sample LOGON Catalogued
Procedure '. • • '. '. ,. • '. • • •
• •
FigUre 42. TSO System Parameter
Syntax (Part 1 of 2) • • • • '.
•
Figure 43. Sample TSO System
Parameters
• • •• •
Figure 44. sample Job System, to Run
TSO Trace Data set Processor
......
Figure 45.
Format of the TS Trace
Data set
. . . . . . . . . . . . . . . . ..
FigUre 46. Portion of Sample PL/I
Log on Pre - Prompt Exit,.. '. .. • • • • •
Figure 47,. Swap Allocation Unit Sizes

I. '. • '., • '. I. • '. '. I. •

48
48
49
50

51
54
55
56

57

58
63
69
69
70
72
72
73
74
77
79

80
81
86
89

Summary of Major Changes

Release 20.1 GC28-6698-2

r---------------------T--------------------------------------------------r--------------,
I
Item
I
Description
I
I
r---------------------+--------------------------------------------------+--------------~
system ImplementationlA section has been added describing the techniques
lused in implementing a TSO system. This section
Iconsists of discussions of:

I

IGenerating a Message Control Program
I Writing Cataloged Procedures Used With TSO
, Ispecifying TSO system Parameters
ITuning the Time Sharing Driver
IWriting Installation Exits for:
IThe SUBMIT Command
IThe OUTPUT, STATUS, ~nd CANCEL Conunands
IThe LOGON Command
r---------------------+--------------------------------------------------+--------------~
Istorage Estimates
IMost of the information in the storage Estimates I
I
I
Isection, including the sample TSO configuration,
I
I
I
I has been delet ed and moved to the publ ica tion IBM I
I
I
I
I
I System/360 Operating system storage Estimates
I
I GC28-6551.
I
I
~---------------------+-----------------------------------------------~--t-------------_i
IDriver Entry Codes
IAn appendix has been added containing the format I
I
I
I and meaning of the TSEVENr macro instructions used 1
I
I
Ito notify the Time Sharing Driver of system
I
I
1
I
I
I events.
~---------------------+--------------------------------------------------t--------------i
ITerminal Messages
IAn appendix has been added containing messages
I
I
I Requiring
Iwhich when received at a terminal requires the
1
I
IInstallation Action I installation to take certain actions.
1
I
r---------------------t--------------------------------------------~-----t--------------~
IMessage Control
IAn appendix has been added containing the text of 1
1
IProgram Assembly
I error messages generated by the macro instructions I
I
IError
Messages
lused
to generate the Message Control Program.
1______________ JI
L
_____________________
__________________________________________________
~

Release 20.1

~

GC28-6698-3

r---------------------T--------------------------------------------------7--------------,

I
Item
I
Description
IAreas Affected I
~---------------------+--------------------------------------------------t-------------_i
IT~~ step Library
IA discussion of the advantages of concatenating
120,74
I
I
I Command Library to SYS1 .. LINKLm" the Linkage
I
I
I
I Library.
1
I
r---------------------+--------------------------------------------------t--------------~
lOS PL/I Checkout
1A discussion of the uses and facilities of the
135-36
1
I Compiler
I Checkout Compiler.
1
I
r---------------------+--------------------------------------------------t--------------~
12260,2265
IThe macro instructions for generating the MCP have163-69
I
I
I additional operands for 2260 and 2265 support.
I
I
L________________

~----~--------------------------------

__________________ ______________ J
~

summary of Major Changes -- Release 20 .• 1

7

Introduction

The IBM System/360 operating System Time
Sharing Option (TSO) adds general purpose
time sharing to the facilities already
available through the MVT configuration of
the control program. As a result, the
system provides a number of new
capabilities:

• The way in which a terminal user
defines his work is uncomplicated. He
enters commands which resemble English
language words to describe the general
function he wants to accomplish. If
the user chooses, he can create his own
commands and command system.

• It gives users access to the system
through a commandlanguaqe which is
entered at remote terminals -typewriter-like,keyboard-printer or
keyboard-screen devices connected
through telephone or other
communication lines to the computer.

• If a user doesn't know how to define
his work to the system, he can type
HELP and receive information pertinent
to the type of operation he is trying
to perform. In most cases, he doesn't
need to enter detailed parameters
describing every aspect of the work he
is doing; the system uses default
values that are appropriate for most
jobs. If he fails to provide
parameters the system needs to do the
work he requested, the system will ask
him for the missing information, item
by item, by npromptingn him for it in a
conversational way.

• It gives those who may not be
programmers the' use of data entry"
editing, and retrieval facilities.
• It makes the facilities of the
operating system available to
programmers at remote terminals to
develop, test, and execute programs
conveniently, without the job
turnaround delays typical of batch
processing. Both terminal-oriented and
batch programs can be developed at
terminals.
• It allows the management of an
installation to dynamically control the
use of the system's resources from a
'terminal.
• It creates a time-sharing environment
for terminal-oriented applications.
Some applications, such as
problem-solving languages,
terminal-oriented compilers, and
text-editing facilities, are available
as IBM Program Products. Installations
can add others suited to their
particular needs~
A major consideration in the design of
TSO,is ease of use. The way in which a
user communicates with the system can be
kept simple to encourage people who may not
be programmers to take advantage of the
speed and versatility of a computing system
to solve their problems. There are four
ways in which TSO achieves this goal:
• The physical medium is easy to use.
Most users are already familiar with
the conventional typewriter keyboard.
Information is easy to enter through
the terminal's typewriter-like
keyboard, and no complex procedures are
required to obtain output from the
computer.

• The system keeps the terminal user
aware of what is happening, so he knows
what to do next. He n converses n with
the system on a step-by-step basis.
The system lets him know when it is
ready to accept input from him, and it
tells him immediately when there has
been a change in the status of his
program or when an error has occurred.
He may interrupt the processing of his
program at any time. If the user
receives a message he doesn't
understand, he can request more
information about the situation simply
by typing a question mark. The
messages he receives use uncomplicated
language to describe the situation.
When the messages become familiar to
him, he may request the system to use
the abbreviated messages that are
available with some of the programming
lan:Juages.

Advantages of a Time Sharing System
In a simple batch processing system, one
job at a time has access to the resources
of the system (main storage, the central
processing unit, and I/O equipment). A
programmer's job is loaded into the
computer and its operation is controlled by
the system operator. The job acquires the
resources it needs as it runs to
completion; resources the job doesn't need
are unused., When the job is finished,
Introduction

9

results are produced, a new job is loaded
and executed" and the output for the
completed job (for example" a printout) is
s'ent 'to the programmer. An inherent
problem with this type of processing is
turnaround time, the elapsed time between
the submission of a job to the comp.lter
cent er for process ing and the return of
results to the programmer. Another problem
is the inefficient use of resources.

In a multiprogramming system (e.g., a
system that operates under the control of
the MVT configuration of the System/360
Operating system)" several jobs share the
resources of the system concurrently" so
the use of resources is much more
efficient. ·Although jobs are processed
faster, the operator at the system console
still controls the system, and the
programmer still must wait for results to
be returned to him.
A time sharing system reduces delays in
receiving results,. A larger number of jobs
share the resources of the system
concurrently" and the execution of each job
is controlled primarily by a remote
terminal user. Thus" time sharing can be
defined as the shared, conversational, and
concurrent use of a computing system by a
number of users at remote terminals.
The system resources shared by the time
sharing jobs (foreground jobs) entered from
the terminals are also shared by batch jobs
(background jobs) that are being processed
at the same time. Each foreground main
storage region handles many active
foreground jobs" although only one job is
actually in the region at any moment in
time. A foreground job is assigned to a
main storage region and has access to the
system's resources for a short period of
time called a time slice. The other
foreground jobs assigned,to that region are
saved on auxiliary storage while the job
being executed in main storage receives a
time slice.
At the end of the job's time slice, or
if the job enters the wait state for
terminal I/O, the main storage image of the
job (that is, programs, work areas" and
associated control blocks) is stored on a
direct access device and another job is
brought into the same region of main
storage and given a time slice. TSO
schedules a similar time slice for each
ready foreground job. The apportionment
and duration of time slices is discussed in
detail in the "system Summary" section of
this manual.
10

Time Sharing Option Guide

(Release 20,.1)

The process of copying job images back
and forth between main and auxiliary
storage is called swapping~ Writing an
image to auxiliary storage is a swap out;
reading one into main storage is a swap in.
All foreground jobs are assigned the
same priority,. The order in which
foreground and background jobs are
processed is determined ~ the operating
system task dispatcher. Job priorities,
job classes, and the dispatching of tasks
are discussed in IBM System/360 Operating
System: Concepts and Facilities,
GC28-6535.
The apportionment of slices of
processing time to foreground jobs is not
apparent to a terminal user. At the
terminal" the response of the system to
requests for action is fast enough so that
he has the impression that he is the sole
user. As far as the user is concerned the
distinctive feature of a time-sharing
system is the way in which it "converses"
or interacts on a step-by-step basis with
him as he does his work. He is prompted
for information the system needs to execute
his job. he receives immediate responses to
his requests for action" and he is notified
immediately of errors the system detects,
so that he can take corrective action at
once.
In general then" a time-sharing system
differs from a batch processing system in
three ways:
1.

A terminal user concurrently shares
the resources of a computing system
with other terminal users.

2.

A terminal user can enter his problem
statements and other input into the
system as he develops them, and he
receives immediate results. Thus the
problem of turnaround time (the amount
of time between when he submits his
job for processing and when he
receives results) inherent with batch
·job operations is greatly reduced.

3.

A terminal user is constantly aware of
the progress of his job. He requests
results from the system one step at a
time" he is prompted for any
addi tional information the system
requires, he receives immediate
notification of the status of his
work" and he is apprised of errors as
soon as the system detects them. The
terminal user can change his problem
statements or correct errors
immediately after entering each
statement or at any time during the
current terminal session,. Thus, he
minimizes the need for reruns.

Using a Terminal
A terminal session is designed to be an
uncomplicated process for a terminal user:
he identifies himself to the system and
then issues commands to request work from
the system. As the session progresses, the
user has a variety of aids available at the
terminal which he can use if he encounters
any difficulties.
Commands specifically tailored to an
installation's needs can be written and
added to the command language or used to
replace IBM-supplied commands.
starting and stopping a Terminal session

I

When the user has some work to perform with
the system, he dials the system number if
he has a terminal on a switched line, or he
turns the power on if he has a terminal on
a non-switched line. A Switched line is
one in which the connection between the
computer and a terminal is established by
dialing the system's number from the
terminal. A non-switched line is one with
a connection between the computer and the
terminal. With an IBM 2741 terminal or an
IBM 1050 terminal, the system responds by
unlocking the keyboard. In any case, the
user identifies himself by entering "LOGON"
and one or more of the following fields:
• A user identification, for example, the
user's name or initials, which the
system will use to identify his
programs and data sets.
• A password assigned by his
installation, usually known only to the
user and the system manager.
• An account number, which defines the
account in which his system usage
totals are to be accumulated.
• A LOGON procedure name, which
identifies a cataloged procedure that
specifies what system resources he will
be using.
The user may omit the last three fields if
the system manager has defined only one
account number and LOGON procedure for him
and no password is used.
The LOGON processor verifies that the
user is an authorized TSO user, then checks
the password, if it is required, and
account number in a record it keeps of user
attributes, called the User Attribute Data
Set (UADS). From the attributes, the LOGON
command operands, and a LOGON cataloged
procedure, the system builds a user
profile, which is used to control the

processing of his job. The system assigns
the user's job to a time-sharing
(foreground) region of main storage and
allocates other resources, such as
auxiliary storage space and user data sets
according to the LOGON procedure.
LOGON marks the start of a terminal
session. When the user completes his work,
he enters "LOGOFF" to end the session. The
system then updates his job's system use
totals, releases resources allocated to it,
and releases the terminal from TSO. A
session is also terminated any time the
terminal user enters LOGON to start a new
session. In this case, the old session is
terminated and a new one is begun; the
terminal is not released in the process.

Working at the Terminal
The user enters comnands to define am
execute his work at the terminal.
He
enters a command by typing a command name,
such as EDIT and possibly some additional
operands.
The system finds the appropriate
command processor--a load module in a
comnand library--and brings it into the
foreground region assigned to the user for
execution.
For example, in response to
entering the EDIT command, the system
brings in the EDIT command processor, the
data handling routine used to create and
update data sets.
If a user does not enter all the
operands associated with a particular
command name, default values are assumed
where possible. If necessary operands are
missing, the system prompts the user for
them with a message such as "ENTER DATA SET
NAME." The user can reply with the missing
value, or enter a question mark for a
further explanation of what the system
needs. If the user chooses, he can specify
that prompting messages be suppressed.
A terminal .user can also receive
assistance through the HELP facility.
He
can request information regarding the
syntax" operands, or function of any
command, subcommand, or operand.
If he
enters HELP followed by a command name, he
receives an explanation of the command and
the operands required with it.
HELP
followed by a subcommand name furnishes an
explanation of the subcommand if you are
working with the command at that time.
Entering HELP by itself returns a
description of the command language, a list
of the commands, and an explanation of how
to use HELP to obtain further information.

Introduction

11

During a typica 1 session,; the user
enters a series of commands to define and
perform his work. If the sequence is one
that is used often., he can store the
sequence in a data set and then execute the
sequence whenever he needs it by entering
the EXEC command.
The commands provided with the system
handle data and program entry., program
invocation in either the foreground or the
background" program testing, data
management, and session and system control.
IBM Program Products are available to
support problem solving, data manipulation,
and text formatting, to provide
terminal-oriented language processors., and
to make these processors more convenient to
use from the terminal.

System Configurations
TSO is an extension of the MVT
configuration of the control program on
System/360 Models 50 through 195, or
System/370 Models 155 and 165. TSO also
operates with the Model 65 Multiprocessing
(M65MP) configuration. The minimum machine
configuration for System/360 models must
include 384K of main storage, the required
I/O devices for MVT., plus at least one each
of the following:
• A terminal (IBM 1050, 2741" 2260 Local
or Remote, 2265" or Teletype 1 Model 33
or 35 KSR and ASR).
• A transmission control unit (IBM 2701,
2702, or 2703), unless all terminals
are locally attached 2260 Display
stations.
• sufficient direct access storage space
(IBM 2301, 2311, 2303, 2305~ 2314~ or
3330) for command libraries and system
data sets.
• Sufficient direct access storage space
to swap data sets.
In a System/360 with 384K of main storage,
TSO is, in effect. a "dedicated" time
sharing system. In other words; with 384K
the system can run as a time sharing system
or as a batch job processing system, but
not both at the same time. To run both
time sharing and batch jobs concurrently or
to execute on M65MP or systeml370 models"
at least 512K of main storage is required.
At least 128K of main storage is required
for system generation,.
1Trademark of Teletype Corporation., Skokie,
Illinois.
12

Time Sharing option Guide

(Release 20.1)

Terminals
Some remote terminals suitable for
interactive applications have keyboards for
entering input data and either
typewriter-like printers or display
screens. A remote terminal incorporates or
is attached to a control unit. The control
unit is in turn connected to the system by
either of two ways:
• Through a device such as a data set to
a dialed (switched) line to the system.
• Through either a direct or a leased
I ine to the system,.
At the computer site the communication
line connects to a Transmission Control
Unit~ which in turn is attached to one of
the computer system's multiplexor channels.
The IBM 2260 Display Station can be an
exception to this general configuration.
Its control unit., the IBM 2848 Display
Control" can be attached directly to a
multiplexor or selector channel. This mode
of operation is called local attachment.
TSO uses the Telecommunications Access
Method (TCAM) for terminal access. TSO
provides terminal handling programs for the
following terminals:
•
•
•
•

IBM 2741 Communication Terminal.
IBM 1050 Printer-Keyboard.
TeletypeS- Model 33 and 35 KSR.
IBM 2260 and 2265 Display stations.

The IBM 2741 Receive Interruption
Feature and the Transmit Interruption
Feature are recommended for use with the
2741. These features are described in the
publicati on IBM 2741 Communications
Terminal. '!he Transmit Interrupt, Receive
Interrupt, and Text-Timeout suppression
features are recommended for use with the
IBM 1050. 1050 multidrop is not supported.
These features are described in the
publication IBM 1050 System Summary. Note
that some of these features are not
available through the IBM 2701 Data Adapter
Unit. 2
Transmission Control Unit
TSO requires at least one of the following
transmission control units to handle
terminal communications:
2Terminals which are equivalent to those
explicitly supported may also function
satisfactorily.. The customer is
responsible for establishing equivalency.
IBM assumes no responsibility for the
impact that any changes to the
IBM-supplied products or programs may have
on such terminals.

• IBM 2701 Data Adapter Unit.
• IBM 2702 Transmission Control.
• IBM 2703 Transmission Control.
The Terminal Interruption Features are
recommended for use with the 2702 and 2703
transmission control units and must be
present if the terminals are to use the
features. These units are described in the
following publications:

I

• IBM 2701 Data Adapter Unit, Component
Description.
• IBM System/360 Component Description,
IBM 2702 Transmission Control.
• IBM 2703 Transmission Control.,
Component Description.
Swap Data Set Devices
The process of copying images back and
forth between main and auxiliary storage is
called swapping.. Writing an image to
auxiliary storage is a swap out; reading
one into main storage is a swap in. The
pre-formatted data sets into which jobs are
written are called swap data sets. A swap
data set is divided into swap allocation
units, each of which consists of a
device-dependent number of 2048-byte
records. An integral number of swap
allocation units, not necessarily
contiguous" are assigned to each job to
contain the swapped out image of the job.
If there is more than one foreground
region, they share the available swap data
sets, but the cycle of swapping for each
region is essentially independent of other
regions. However, the system avoids
queuing on swap data sets if possible.
TSO requires sufficient storage capacity
on one or more of the following for swap
data sets:
• IBM 2301 Drum Storage.
• IBM 2303 Drum storage.
• IBM 2305 Fixed Head Storage,
Modell or 2.
• IBM 2314 Direct Access storage
Facility.
• IBM 3330 Disk storage Facility.
See the Storage Estimates section of
this publication for information on swap
data set siz es.
The record overflow feature is required
for the devices used to store the swap data
sets. One or more data sets on any of the
above devices can be used for swap data
sets.
The direct access storage space required
for the swapped data may be divided among
the devices listed above in either of two
ways. The user may specify that swapped

data be distributed serially among a
hierarchy of data sets, or he may specify
parallel distribution of data onto two
devices. With serial distribution, the
first data set in the hierarchy is filled
with swapped data, and then the next data
set in the hierarchy is used. For example,
a drum., because of its higher access speed,
could be assigned as the first unit in the
hierarchy, with a 2314 assigned to receive
any overflow of swapped data.
With the parallel distribution scheme, two
devices are used concurrent1:y to receive
swap data sets. The exact order in which
data sets are written on either of the
devices is determined by the system, based
on the I/O activity taking place in the
channel at the time of a swap out.
For
example, if the two data sets are on
devices on separate channels, swap
performance improves substantially.
Before a terminal jcb can be swapped out
of main storage, activity associated with
the job must be brought to an orderly halt.
The halt must be performed in such a way
that the job is not aware of it, and
information must be saved to restart the
job when its next time slice is scheduled.
The orderly suspension of a job's activity
before a swap out is called guiescing the
job. Quiescing includes the removal of the
majority of the control blocks associated
with the job from the system queues so they
can be written to the swap data set along
with the contents of the main storage
region assigned to the job.

The Relationship of TSO to the
Operating System
For the data processing center, TSO is
compatible with operating system standard
formats and services, while providing the
flexibility needed for various time sharing
and terminal-based applications.
TSO is not necessarily intended to be
used as a dedicated time-sharing system,
that is, a system on which only
time-sharing operations take place. TSO
augments the facilities already available
with the operating system: batch
processing, teleprocessing, and other data
processing activities can take place
concurrently on the same system.
Once an installation has generated a
system that includes TSO r time sharing
operations can be started and stopped at
any time by the system console operator.
The operator can specify how many regions
Introduction

13

of main storage are to be assigned to time
sharing users. Each region can serve many
users, whose programs are swapped back and
forth between main and auxiliary storage.
Time sharing, or foreground operations, can
take place concurrently with batch or
background operations.
(Background jobs
are not swapped.) If the user chooses, he
can dedicate his system to time sharing and
run only foreground jobs. If there are
periods when TSO is not needed in the
system, time sharing operations can be
stopped, and the system will then process
background jobs in the usual way with MVT
and TCAM.

executed in either the background or the
foreground without revision or
rec ompi la ti on.
Restrictions and Limitations
Certain facilities are unavailable to
foreground jobs" although they remain
available to background jobs. These
include:
• The BTAM and QTAM telecommunications
access methods.
• The Graphics Access Method (GAM).

Terminal communications are handled by
the Telecommunications Access Method (TCAM)
through an interface that allows the use of
standard sequential access method I/O
statements and macro instructions.

• The EXCP equivalents of the BTAM, QTAM,
and GAM access methods.
• Main storage requests for hierarchy 1
(all foreground requests for main
storage are allocated to hierarchy 0).

All of the MVT facilities are available
to a background job. Foreground jobs can
use most of the operating system access
methods for data set access (e.g., BSAM,
QSAM, BDAM etc.). All devices available to
these access methods are usable by
foreground jobs. A detailed list of
restrictions is in the "Restrictions and
Limitations" section of this manual.

• Use of Job Control Language in the
foreground for other than single-step
jobs (the TSO command language is used
to provide the equivalent of multi-step
jobs).
• Checkpoint/Restart Facility (foreground
requests for checkpoint are ignored).

Execution of Background Jobs from the
Terminal

• Rollout/Rollin Option.
In addition to the foreground execution of
programs, TSO allows jobs to be submitted
for execution in the background, or batch,
portion of the system. If his installation
author i ze s i t , a user can submit a
background job at his terminal, be notified
of the job's status, and then receive
results of the job at the terminal. If he
chooses" he can specify that the output of
his job be produced at the computing
center, rather than at the terminal.

• TESTRAN Facility.
• Tape volumes are not supported.
• Multivolume data sets are not supported
by Dynamic Allocation.
SVC numbers 92 through 102 (decimal) are
added to the system for TSO. The following
SVCS can be issued by problem programs in
the foreground region:

Fbreground-Background Compatibility
• SVC 93--TGET/TPUT (execute terminal
I/O).

Because time sharing is carried out within
the framework of MVT job and task
management, the foreground and background
environments are compatibl e. TSO use s the
same data formats, programming conventions"
and access methods as the rest of the
operating system. The programming
languages and service programs available
with TSO are compatible with their
background counterparts.
The TSO command language is also
generally compatible with the
Conversational Remote Job Entry (CRJE)
command language. Programs can be
developed in the foreground and stored in
background libraries. These programs are
compatible with other operating system
programs. Most problem programs can be
14

Time Sharing Option Guide

• SVC 94--STCC (specify terminal control
characteristics>.
• SVC 95--TSEVENT (notify the supervisor
of an event).
• SVC 96--STAX (specify a terminal
attention exit) '.
• SVC 97--Breakpoint (used by TEST
command) •
• SVC 98--PROTECT (protect a data set
with a password).
'//

(Release 20.1)

• SVC 99--Dynamic Allocation (of a data
set> •

• SVC 100--suhmit a job to the
background.
• SVC 102--AQCTL -- used by TCAM to
communicate with problem programs.
Of these, only SVC 98--PROTECT--can be
issued by programs executing in the
background. SVCs 92 (TCB EXCP) and 101
(TCAM-TSO Communication) are used only by
supervisor programs.

allows data sets to be created, deleted,
concatenated, or separated without previous
allocation at the beginning of the job
step.

Tuning the Time Shar ing system

In a time sharing system, execution time is
divided among the active foreground jobs
and background jobs in brief time slices.
Including TSO in a system adds no
A time slice must be long enough to perform
a meaningful amount of processing, but not
restrictions to programs executed in the
so long that the time between successive
background. For example. other
teleprocessing applications can be run
slices prevents quick response to
simultaneously.
conversational users. At the same time,
time slices cannot be so short and frequent
system Control
that system overhead for swapping and task
switching becomes excessive,. Balancing
these factors depends on the number and
The management of an installation can shift
type of jobs the system is processing. A
most of the responsibility for controlling
solution for one job mix is not necessarily
the time sharing system from the operator
at the system console to users at remote
suitable for another job mix. The TSO time
terminals, called control terminals. A
sharing algorithms -- the formulas used to
control terminal user can alter the system
calculate the division of time among jobs
configuration to meet changing work loads~
-- are based on several variables, most of
FOr instance, he can assign an extra region
which can be specified by the installation
of main storage to time sharing operations
to tune the system for their particular
during peak periods, and then release it to
workload. Some of the tuning variables
be used for batch operations during slack
such as the number of foreground regions
periods. Such changes require no shutdown
I and the maximum number of users, can be set
of TSO and are not noticed by the users of
by the system operator or a user at a
other regions. Even the starting and
control terminal whenever the system is
stopping of TSO operations is accomplished
running. others are specified as
without shutting down the system or
pararoeters in SYS1.PARMLIB. These
affecting background operations.
parameters are used when the operator
starts the time sharing operations.
Job Definition and scheduling
To the operating system, each terminal
session from LOGON to LOGOFF is one
terminal job" corresponding to a single
step batch job. The job control statements
that define a terminal job are stored in
the LOGON procedure used to begin the
session,. The" EXEC" JCL statement in the
LOGON procedure identifies the program the
user wants loaded into his region for
execution. The program may be the
TSO-provided command language handler or an
installation provided application program.
An important feature of TSO is the
dynamic allocation of data sets for time
sharing users. A user may defer definition
of his data sets until he requires them.
During LOGON processing, any data sets
named on Data Definition (DD) statements in
the procedure are allocated to the terminal
job. Any data sets requiring volwne
mounting by the operator, must be defined
here. The procedure also includes dynamic
DD statements (similar to a DD DUMMY),
which reserve control block space for data
sets the user may allocate during the
session. The dynamic allocation facility

I

The time sharing algorithms are
described in detail in the "System Summary"
sect ion of this manual. They are
implemented bya subroutine called Time
Sharing Driver. The Driver makes decisions
about system functions such as swapping and
task switching. An installation may
experiment with other time sharing
algorithms by modifying or replacing the
driver., and specifying use of the new
Driver in the SYS1.PARMLIB parameters used
when the operator starts time sharing
operations.

Monitoring System Use and
Performance
By extending the services of the system to
many concurrent users, TSO makes the
operating system more useful to more
people. However, installation management' s
job of monitoring system use and
performance becomes more complex. Three
tools are provided to help management
maintain a clear picture of what the system
is doing.
Introduction

15

system Management Facilities (SMF): The
SMF Option can be used with TSO. Both the
data collection and dynamic control
facilities are extended to the foreground
environment.

with the data collection facility,
records describing both the system
environment and individual user activity
are written to the SMF data sets in a
format similar to that used for background
records. The system environment data
includes:
• Machine configuration.
• Resource status.
• Library management information.
This information is recorded whenever
time-sharing operations are started,
modified, or stopped by an operator. The
user data includes:
•
•
•
•
•

I/O device use.
Data set use.
Main storage used.
Time resident in main storage.
Time actually spent executing.

The user data is recorded at LOGON and
LOGOFF and during a terminal session
whenever a user changes the status of his
data sets with the dynamic allocation
facility. The information on the use of
data sets is particularly useful to the
installation for controlling the use of
secondary storage in the time-sharing
environment.
The SMF dynamic control exits give the
installation access control program
information at key points during the
processing of jobs, including foreground
jobs. The step initiation and termination
exits are taken" if present, when a user
begins or ends a terminal session. These
routines can record information and control
processing for foreground jobs just as they
do for background jobs. SMF is discussed
in detail in the publication IBM System/360
Operating System: system Management
Facilities, GC28-6712.
An additional installation exit,
separate from the SMF dynamic control
exits, is provided from the routine
handling user LOGON. This exit allows the
installation to establish its own user
verification and control procedures,
independent of those supplied with the
system. The section of this publication
Writing a Logon Pre-prompt Installation
Exits describes the parameters passed and
what actions the exit may take.
16

Time Sharing option Guide

(Release 20.1)

M)NITOR Command: The MONITOR command
allows the operator to watch the changing
workload on the system over a period of
time. In addition to the job initiation,
data set, and volume information formerly
available with the DISPLAY command, he can
request notification of time-sharing users
logging on and off the system. The DISPLAY
command now gives the system workload at a
particular point in time, and has been
extended to include information relative to
the time-sharing environment, such as the
number of foreground regions and the number
of active terminals.
Both MONITOR and
DISPLAY, like other operator commands
concerned with the time-sharing operation,
are available to a control user at a remote
terminal as well as the system operator at
the console.
TSO Trace Program: The TSO Trace Writer
Program provides a detailed history of what
the system does over a period of time. The
Trace Program records a stream of
information that all components of the
system are continuously passing to the Time
Sharing Driver. The Driver uses this
information in its calculations of resource
allocation. When the operator starts the
Trace Program, it intercepts these event
signals and records them with a time stamp
in a data set. Typical events recorded are
"job requesting terminal input" and "swap
completed." The TSO Trace Data set
Processor can be used at a later time to
format and print out the information
recorded by the Trace Program. The Trace
Data set Processor can be requested to list
only those events associated with a
particular component of the system, such as
the dispatcher, or to list only those
events associated with a particular
terminal or set of terminals. Using this
information, system management can
determine how well the system is responding
to the workload and make adjustments to the
tuning variables if necessary.

System Security
The need f or adequate data and program
protection is increased in the time-sharing
environment, where many persons are
simultaneously using the system. The
system itself must be protected against
unauthorized users. Each user's programs
and data must be protected against
accidental destruction by other users.
Confidential data must be safeguarded
against unauthorized access.
User Verification
Any user starting a terminal s ess ion is
required to supply a user identification
recognized by the system; that is, one that

has been defined by the system
administrator. The installation may also
require the user to supply a unique and
confidential password with the LOGON
command.
Further verification of a user's
identity can be performed by the optional
installation routine called when a user
logs on. This routine can request further
information from the applicant and deny him
access to the system if he fails to provide
it.
Program Protection
Although a number of users may have jobs
assigned to the same foreground main
storage region, only one user's job is
present in the region at a particular time
-- the other jobs are temporarily stored in
the swap data sets. No user can
accidentally destroy or tamper with another
user's job. Like the background regions
under MVT, the foreground regions have
unique storage keys, preventing a job from
modifying any area of main storage outside
its assigned r~gion.

all other users. There is no
performance degradation in opening the
data sets for reading.
• Read Protection. The password must be
supplied to open the data set for
reading.

Authorizations
.special authorizations in the User
Attribute Data Set are required for the use
of some TSO facilities. Specific·
authorization is required for:
• Submission of jobs for execution in the
background.
• Use of system operator commands from
the terminal.
• Use of commands to modify the User
Attribute Data Set itself.
The User Attribute Data Set should be
password-protected, to prevent assignment
of these authorizations by anyone other
than the system administrator or his
designate.

Data Set Security
Because any user can refer to any data set
in the system catalog, the data set
security facility of the operating system
is extended to allow individual users to
protect their own data sets from
unauthorized reference. A user can assign
one or more passwords to a data set.
If
anyone subsequently attempts to open the
data set, he is prompted for the
password(s). If he fails to supply the
correct password in two attempts, his
program is terminated.
The password assigned to a data set can
be the one associated with the user for
LOGON. In this case, the user will not be
prompted for the password when opening his
own data set. Any other user, however,
must supply the correct password to refer
to that data set.
.
Passwords can be assigned for two levels
of protection:
• Modification protection. No password
is required to open the dataset for
reading, but a password must be
supplied to write into the data set, or
to delete it. This type of protection
is required for system libraries and
data sets, to prevent accidental
modification or to prevent a user from
assigning a password and locking out

Capabilities of the TSO
Command Language
The TSO command language serves two
separate, but related, purposes:
• It gives the terminal user a simple
means to request the system to perform
work.
• It gives system personnel a framework
for applications.
Functions available through the commands
supplied with the system include:
•
•
•
•

Data set management.
Program development.
Program execution.
System control.

The following sections describe these
capabilities and are followed by a
description of the applications available
as IBM Program Products. Installation
management has complete control over which
functions are available to each terminal
user.
Data Set Management: The TSO command
language includes commands to enter, store,
edit, and retrieve data sets consisting of
text, data, or source programs.
Essentially, the commands give the terminal
Introduction

17

user the data set management functions of
the operating system. Through the use of
default values and data set naming
conventions, the commands can be simple
enough for the non-sophisticated user.
Data from the terminal goes into
standard operating system sequential or
partitioned data sets. Conventions for
immediate correction of keying errors are
available for each terminal device type.
At a 2741 Communications Terminal, for
instance, the user can just backspace over
an error and type in the correct
characters.
At the user's option, the system will
assign a number to each line of data as it
is entered. Later, the user can retrieve
and edit the line by referring to this line
number. The user can also retrieve a line
by specifying a string of characters
contained in the line, and having the
system scan the data set for it.
Program Development: TSO offers convenient
facilities for program development. The
programmer can use the data-handling
facilities to create source programs and to
have them syntax-checked line-by-line as he
enters them. Any operating system language
processor can be inVOked from the terminal.
Some language facilities and translators
designed especially for the terminal
environment are discussed under "IBM
Program Products."
Compiler diagnostic messages and
listings can be directed to the terminal,
allowing the programmer to correct errors
immediately and recompile the program.
Once the program compiles successfully, it
can be tested conversationally. The
programmer can start and stop execution
from the terminal, inspect and modify main
storage and register contents., trace and
control the program flow.
Because of baGkground-foreground
compatibility, programs produced at the
terminal can be executed in either
environment. Programs in the foreground
can use the sequential access methods (BSAM
and QSAM) to direct I/O to the terminal.
In the background, the same unmodified
programs can address a data set or unit
record device.
Program Execution: Programs can be invoked
at the terminal in several ways. Any load
module can be established as a command and
executed simply by keying in the program
name at the terminal. Load modules not
defined as commands can be invoked in the
foreground with the CALL command. If a
program uses data sets, a command procedure
18

Time Sharing Option Guide

(Release 20.1)

can be used to allocate them. Entering the
one-word procedure name can allocate the
data sets, invoke and start the program.
and free the data sets again on program
termination. Whenever a program in the
foreground terminates with an error
condition, the testing facilities can be
used to determine the nature of the error.
The terminal user can also submit jobs
to the background job stream. Commands
similar to those used for the
Conversational Remote Job Entry (CRJE)
facility are used to create job control
language describing the job, and to submit
it to the batch job stream. The user can
request notification of job completion at
his terminal., and can have job output
directed either to his terminal or to a
device at the computer site.
system Control: Certain users can be
authorized to use commands for controlling
system operation. With the proper
authorization; a user at a remote terminal
can use standard operator commands such as
DISPLAY and MODIFY to control the
time-sharing portion of the system.
A separate control facility (ACCOUNT)
allows an authorized terminal user to
establish and maintain the profile of each
system user. Using special commands from
his terminal, he can define or modify user
passwords, account numbers. and procedure
names, and control authorizations and
restrictions for each user.

IBM Program Products
The command language is designed so that
new commands and applications can be easily
integrated into it. Applications available
from IBM as Program Products look the same
as other commands to terminal users.
The IBM Program Products available for
TSO systems are introduced briefly in the
following paragraphs. Each is discussed
more fully in later chapters of this
manual.

Problem-Sol ving
Three language processors specially
designed for matherratical problem solving
by users who are not necessarily
professional programmers are available.
Two are part of the Interactive Terminal
Facility (ITF). The third is Code and Go
FORTRAN, which is discussed with the other
FORTRAN Program Products in the next
section.

ITF: BASIC is a simple, algebra-like
language easily learned by anyone familiar
with mathematical notation.
ITF: PL/I is a subset of full PL/I that
provides a powerful conversational language
that is easy to learn and use. Because of
its relationship to full PL/I, i t is an
excellent vehicle for teaching.
ITF: PL/I
can be executed line-by-line as it is
entered, or collected into procedures and
subroutines for later execution. Errors in
either ITF: BASIC or ITF: PLII can be
detected as soon as the statement is
entered and can be corrected immediately.

Programming
Program Products to aid the users of
several programming languages are available
with TSO. There are three types of
products:
• Compilers.
• Libraries to support the compilers and
object programs~
• Prompters.
The compilers can be used in either the
background or the foreground environments.
In the foreground, they provide diagnostics
and listings formatted for the terminal.
For instance, diagnostic messages can
optionally refer to source errors by the
line number assigned by the EDIT command.
With the line number, the user can retrieve
and correct the statement without having a
complete listing displayed at the terminal.
Prompters are initialization routines
that allow the user to invoke a compiler
with a single command, such as FORT or RUN.
The prompter handles all data set
allocations and sets processor options. If
the user omits necessary information, such
as the name of the SOU1"Ce program to be
processed, the prompter requests the
information with a terminal message.
The following paragraphs introduce the
Program Products available for each
programming language. The chapter
"Programming at the Terminal" discusses
these products in greater detail and shows
how other operating system processors can
be us ed from the terminal.

FORTRAN: There are four Program Products
for FORTRAN programmers: two language
processors, a library for use with either
processor, and a prompter.
Code and Go FORTRAN is a quick-response,
high-performance processor to meet the
needs of both the problem-solver, who
writes, debugs, and executes relatively
short conversational programs, and the
production programmer, who debugs
components of a large program online tefore
running the program through a batch
compiler. The Code and Go FORTRAN
processor incorporates a prompter routine.
FORTRAN IV (Gl) is an extended version
of FORTRAN IV (G).
It provides the ability
to store permanent object programs, and
produces source and object listings and
storage maps. The TSO FORTRAN Prompter
Program Product is available to invoke this
processor.
The FORTRAN IV Library (Mod 1) is an
extension of the FORTRAN IV library for use
with either FORTRAN IV (Gl) or Code and Go
FORTRAN. It supports new features of these
processors, such as a list-directed
input/output facility, ASCII data set
conversion, and PAUSE and STOP statements
for the terminal.
COBOL: A language processor and a prompter
are available for COBOL programmers: the
American National Standard Full COBOL
Version 3 compiler, and the TSO COBOL
Prompter.
PL/I: Two language processors and two
supporting libraries are available for PL/I
programmers: the PL/I Optimizing Compiler,
the OS PL/I Checkout Compiler, and the PL/I
Resident Library and the PL/I Transient
Library.
The compilers incorporate a
prompting routine.
Assembler Language: The TSO Assembler
Prompter is available to invoke the
Assembler (F). The Assembler (F) is not a
Program Product.
Text and Data Handling
The TSO Data utilities: COPY, LIST, MERGE,
FORMAT Program Product provides four
commands to manipulate data sets, and to
format text for output either at the
terminal or on a high-speed printer.

Introduction

19

Command Language Facilities

TSO terminal users define their work in the
TSO command language. A command can be
thought of as a request from the terminal
user for the system to perform a particular
function. This chapter describes and gives
examples of the facilities available
through the command language. There are
commands for elementary functions such as
entering, editing, and retrieving data;
remote job entry; mathematical calculation;
and program development and testing in
several programming languages. These
important functions are the base on which
the installation's own terminal-oriented
applications and systems are developed.
To make the examples more meaningful,
some TSO conventions for command syntax,
entry format, data management, and terminal
operation are presented first. Many of
these conventions can be redefined at the
option of the installation, or in some
cases" at the convenience of the individual
user.

Conventions at the Terminal
The command is the means by which work is
defined at the terminal. The first word of
a command is always the command name. It
is used h¥ the system to select a command
processor (a problem program) from the
system command library or a user command
library. Any further information in the
input line, the command operands, is passed
to the command processor in a parameter
list. Operands are separated, or
delimited, by either blank spaces or
commas. A few commands require that groups
of related operands be enclosed in
parentheses.
Most operands are optional. If an
optional operand is not entered with the
command, the system assumes the default
value and proceeds as if the user had
entered that value. If the missing operand
is not one that can be defaulted., for
instance, a data set name, the system
prompts the user for it with a message such
as "ENTER DATA SET NAME". When all the
operands have been either entered or
defaulted, the command processor proceeds
to perform the desired function. Some of
the command processors., such as EDIT,
accept" interpret" and perform
sub-commands, which follOW the same
syntactic rules as the general commands.
20

Time Sharing Option Guide

(Release 20.1)

wqginq

On

To establish a connection with the system,
the user activates his terminal, dials the
computer, if necessary, and enters the
LOGON command. He must always supply his
user identification as an operand of the
LOGON command; if he does not supply it., a
prompting message is issued. Up to three
additional levels of identification may be
needed, depending on the accounting methods
and security procedures used by his
insta lla ti on.
The installation may require users to
enter a password with the LOGON command.
Each user can have one or more passwords
associated with his identification. At
terminals equipped with the print inhibit
I feature, the system is able to suppress
printing of the password as it is keyed in.
Associated with each password are one or
more account numbers, and with each account
number, one or more LOGON Procedure names.
The LOGON Procedure contains the Job
Control Language statements defining the
user's terminal job, just as cataloged
procedures define background jobs. For
instance, the LOGON Procedure may have a
STEPLIB data definition (DD) statement for
a private command library. This library
will be searched before LINKLIB or the Link
Pack Area and may degrade performance.
Whenever there is only one account number
or procedure name, the system selects it by
default, and the user is not required to
enter it. Figure 1 shows a simple
identification scheme, with just one value
for each of the possible levels of
identification.

r-----------------------------------------,
ICONRAD
User Identification
I
I ~

IJAYCEE

Password

ID76B

Account Number

I ~

I ~

I
I
I
I
I

IB100K
Logon Procedure Name
L-________________________________________
JI

Figure

1.

Simple Identification Scheme

log on, the user defined in Figure 1
would enter:

To

LOGON CONRAD/JAYCEE
The system will assume "D76B" as the
account number and "B100K" as the LOGON
Procedure name, since no others have been
defined for this user.

A user who has several account numbers
and LOGON Procedures can have a hierarchy
of identification values, like that shown
in Figure 2. This user could still log on
with the command shown above, since "D76B"
and "B100K" are the only account number and
LOGON Procedure name associated with the
password "JAYCEE". However, to use the
nX100K" LOGON Procedure, this user's LOGON
command would be:
LOGON CONRAD/JOEl1 ACCT(D58B) PROC(X100K)
Both the account number and the procedure
name must be included, since a choice
exists for both. The identification scheme
for each user is defined and maintained in
the User Attribute Data Set with the
ACCOUNT command, by the system manager or a
user authorized to do so.

r-----------------------------------------,
CONRAD
User Identification I

I

IIJAYCEE/JOEl1
. "JOEl 2
I 1
~,,~

II
I
ID7~B
D58B
SYSTEM Account Numbers
I
I' ~
~, . J
I
L
IB100K
________________________________________
X100K SYS200K Logon Procedures
JI
Figure

2.

Passwords

User Identification Hierarchy

The system acknowledges that the LOGON
has been accepted when it has checked the
identification supplied and has determined
that the resources requested in the LOGON
Procedure are available, and the user can
begin his work.
Input Editing

I

Some system editing is provided for every
line of input from the terminal. Lowercase
alphabetic characters (from terminals that
have them) are translated to uppercase,
except for certain text-handling
applications. Each user can define his own
character-delete and line-delete characters
for correcting any keying errors in input
lines. There are default character-delete
and line-delete characters for the
typewriter-like terminals (the cursor
controls can be used on the 2260 and 2265
Display Stations). If a user defines the
quotation mark as his character-delete
character, and the percent sign as his
line-delete character, then enters the
line:
etoain%aBCc"deee"n
it is received by the system as
ABCDE
Users whose terminals have backspace and
attention keys may define those keys as

their character-delete and line-delete
characters.
Entry Modes
Immediately after LOGON, the system is
ready to accept any command in the command
libraries. The terminal is said to be in
command mode. Some commands place the
terminal in other entry modes: EDIT, for
instance, has an input mode, that accepts
successive lines of input for a data set;
and an edit mode, that accepts EDIT
subcommands. other commands, such as TEST,
ACCOUNl', OUTPUT, and OPERATOR also define
special purpose modes.
The Attention Key
The attention key can be used to transfer
from one mode to another, or to interrupt a
program or command processor during
execut ion. Any command in process can be
cancelled by hitting the attention key and
entering a new command. A user program can
be interrupted with the attention key to
transfer to the test mode for debugging
acti vi ty, then the program can be
restarted.
Assembler language user programs can
define attention exit routines with the
STAX macro instruction. Control will be
passed to such a routine when an attention
is entered.
An important function of the attention
feature is to prevent the user from being
"locked out" of the system while a
long-running program executes, or while
voluminous output is displayed at the
terminal. For terminals without attention
keys, the attention feature can be
simulated. The user can specify a string
of characters, such as "STP",·that is to be
interpreted as an attention. The system
can be instructed to interrupt any
long-running program or terminal output
periodically to accept either the. simulated
attention character string, or a digit to
specify the level of attention exit or a
null line to continue processing.
Data set Naming Conventions
Unless requested not to, the system appends
two qualifiers to a simple data set name
specified by a user: a descriptive
qualifier and a user identification
qualifier. The user identification
qualifier is the same as the user
identification specified with the LOGON
command and is appended as the left-most
qualifier of data set names that follow the
TSO naming conventions.
The descriptive qualifier is placed at
the right of the user entered data set
Command Language Facilities

21

name. It tells the system what kind of
data is recorded in the data set and for
what purposes it can be used. For
instance, the qualifier for a data set
containing COBOL source statements is
COBOL; for a load module, LOAD. Whenever
possible, the system determines the
appropriate descriptive qualifier from the
command referring to the data set, and the
user need not enter it as part of the name.
In some cases, the user must supply it, as
part of the data set name entered with the
command, or in response to a prompting
message.
The user never needs to enter his
identification qualifier; it is always
known to the system. Figure 3 is an
example of a series of commands to enter
and compile a source program (using the TSO
FORTRAN Prompter and FORTRAN IV (G1)
Program Products); linkage edit the object
program; to display the compiler listing at
the terminal; and finally, to delete all
the data sets involved.
In the EDIT, FORT, and LINK commands,
the user supplied only the simple data set
name, "PRG1". The system assigns the
descriptive qualifiers implied by the
commands and their oper ands. Wi th the LI ST
command, the user supplies the descriptive
qualifier, since he might want to display
either CONRAD.PRG1.FORT or
CONRAD.PRG1.LIST. In the DELETE command,
the user enters an asterisk in the
descriptive qualifier field, telling the
system to delete any data sets with the
identification qualifier CONRAD and the
simple name PRG1.
To refer to a data set that does not
folIo\ Under weighted dispatching, the
system keeps an estimated wait time
percentage for terminal job, based on
averages of time spent waiting by each job
during previous major time slices. Jobs
with a high estimated wait time percentage
tend to be I/O-bound, and will donate much
of their time slices to jobs with TCBs on
the queue below them. Jobs with low
estimated wait time percentages tend to be
compute-bound, and will use most' of their
minor time slice themselves. It is often
desirable to assign the I/O-bound job a
weighted, or longer, minor time slice to
conpensate for its "donation" of execution
time to other jobs.
'
To weight the minor time slices, the
system forms a sum of the estimated wait
time percentages of the jobs to be assigned
minor slices in the current cycle. Each
job is then given a fraction of the
available execution time equal to its
fraction of the total estimated wait time
percentages.
The algorithm is:
This job's EWT%

where MS is the minor slice to be assigned
to a terminal job., EWT% is the estimated
wait time percentage, and AT is the
available execution time for this minor
slice cycle, again adjusted for any
guaranteed background percentage.

As an example, consider a minor time
slice calculation for two foreground
regions, one containing Job A, which is
expected to wait 40 percent of its minor
time slice; the other containing Job B,
which is expected to wait only 10 percent.
The sum of the estimated wait time
percentages is 50 percent. Job A gets
40/50, or 4/5, of the available execution
time as its minor t'ime slice. Job B is ,
assigned 10/50, or 1/5, of the available
execution time. However, Job B will
probably be able to execute for about 40
percent of Job A's minor time slice too .
(while Job A is waiting for I/O), and so
will end up with just under half the
available execution time -- about what i t
would have been assigned on an equal
division.. Job A, however, will be able 'to
get its I/O started, wait for it to
complete, and still have some processing
time left to handle the data or issue
another I/O request. On an equal division
of available time, its minor time slice
might have expired before its first I/O
request completed.

The estimation of wait time percentage
is made by updating a running average of a
job's wait time percentages at the end of
every major time slice. In making the
average, a weighting factor is used to
emphasize recent usage over earlier usage.
The weighting factor is called the wait
time decay constant.
Its purpose and
function is similar to the region activity
decay constant, and i t can also be
specified by the installation. Values
appropriate for general job mixes are
included in SYS1.PARMLIB.

x (AT).

MS

Sum of EWT%s

System Summary

61

System Implementation

This chapter is intended for the
programmers and system analysts responsible
for generating and maintaining a system
with TSO.
(The discussions assume that the
reader is familiar with the system summary
chapter of this publication.) The
discussions contains specific
implementation information. For example,
the discussion "Tailoring a Message Control
Program" does not discuss the role a
message control program plays in a TSO
configuration, but rather provides the
syntax and meaning of the macro instruction
used to generate a message control program.
Included are discussions of how to:

generating macro instructions.
You use the
TCAM macro instructions to generate an MCP
containing the TSO Message Handler and any
other message handlers for your particular
terminal applications, and the necessary .
terminal I/O control blocks. The
communications lines which are to be used
with TSO must be dedicated to the TSO
message Handler through the terminal' I/O
control blocks and the communications lines
for TCAM applications dedicated to their
message handlers. For further information,
see IBMSystem/360 Operating system: TCAM
Programmer's Guide and Reference Manual.
In addition to the standard TCAM macro
instructions, there is a specialized macro
instruction, the TSOMH macro instruction
which expands to form a TSO Message
Handler.

• Generate (or tailor) a Message Control
Program.
• Write the cataloged procedures used by
TSO.

The TSOMH macro instruction has two
operands; NOLOG which specifies a
destination for non-TSO messages and CUTOFF
which specifies a maximum message length.
The syntax of the TSOMH macro instruction
is:

• Specify TSO starting parameters.
• Tune the Time Sharing Driver and use
TSO 'I'race.
• Write an installation exit from the
SUBMIT command processor.

TSOMH
• Write an installation exit from the
STATUS, OUTPUT, and CANCEL command
processors.

CUTOFF=
specifies the maximum number of bytes
before the remainder of the message is
lost to the system. The value must be
an integer between 150 and 65,535, the
default is 300.

• Write a LOGON Pre-prompt exit.

Tailoring a Message Control Program

I

TSO includes a standard Message Control
Program (MCP) to handle terminal I/O for
those installations that use TSO for all
their TCAM applications. The installation
must tailor the MCP to match its needs, in
three steps. First, i t assembles three
macro instructions: LINEGRP, LISTTA, and
TSOMCP. The ·output of this assembly is a
series of TCAM (Telecommunications Access
Method) macro instructions which must, in
turn be assembled. The output 'of this
second assembly forms on MCP that must then
be link edited into SYS1.LINKLIB.

I TSO-only

Mixed Environment MCPs
If your .installation requires a mixed
environment Message Control Program,
because you have TCAM applications
programs, (message processing programs),
'you must generate your MCP using TCAM macro
instructions instead of the special TSO MCP
62

Time Sharing Option Guide

[CUTOFF=integer]
300'

(Release 20.1)

MCP

The following is an explanation of each
step of the generation of the MCP supplied
with TSO:
Step 1 - Assemble the one or more LINEGRP
macro instructions each followed
optionally by one or more LISTTA
macro instructions, all followed
by the TSOMCP macro instruction.
Place the resultant output in a
temporary data set that will be
used as input to Step 2. The
output of this assembly language
source statements -- TCAM macro
instructions which constitute a
Message Control Program.
step 2 - Assemble the TCAM MCP macro
instructions that are generated
wi thin step 1'. The output of step

2 is the MCP object module and is
placed into a temporary data set.
step 3 - Linkage Edit the object modules
from Step 2 into SYS1.LINKLIB to
create an executable MCP load
module.
Figure 34 shows the Job Control Language
necessary to run these steps.
LINEGRP Macro Instruction
The LINEGRP macro is used to define a. line
group, a group of terminals with similar-characteristics, for example, a group of
IBM 2741 terminals. The operands specify:
• The types of terminals in the line
group.
(TERM)
• The ddname of the DD statements that
define the communications lines as data
sets.
(DDNAME)
• The numper of lines, that is, physical
device addresses in the line group.

(LINENO)
• The number of TCAM basic units, per
terminal buffer.
(UNITNO)
• What translation tables are to be used
to translate from the terminal code to
EBCDIC.
(TRANTAB)
• What character string will identify the
transmission code being used when
dynamic translation is required.
(CODE)
• Whether the terminals in this line
group are on switched or nonswitched
lines.
(DIAL)
• How often polled terminals are to be
polled for input.
(INTVL)
• What special features the terminals in
this line group have -- that is,
transmit or receive interruption; and
for 1050, Text Timeout suppression.
(FEATURE)
• The polling and addressing character of
terminals in this line group, for 1050
and 2260/2265.
(ADDR)
• For IBM 2260 and 2265 Display Stations
the screen si,zes.

r---------------------------------------------------------------------------------------,
//MCPGEN
JOB
Job card parameters
'
//STEP1

EXEC

ASMFC

//ASM.SYSPUNCH

DD

DSN=&&TCM,DISP=(,PASS),
UNIT=SYSDA.SPACE=(CYL.(l,l»

DD
LINEGRP
LISTTA
LINEGRP
TSOMCP
END

*

//STEP2

EXEC

AS,MFC, COND= (4 , LT , STEP 1. ASM)

//ASM.SYSPUNCH

DD

DSN=&&OBJ,DISP=(,PASS),
UNIT=SYSDA,SPACE=(CYL,(l,l»

DD

DSN=*.STEP1.ASM.SYSPUNCH,
DISP=(OLD,PASS)

//STEP3

EXEC

PGM=LINKEDIT,COND=(4,LT,STEP2.ASM)

//SYSLMOD

DD

DSN=SYS1.LINKLIB(IEDQTCAM),DISP=SHR

//SYSPRINT

DD

SYSOUT=A

//SYSUTl

DD

UNIT=SYSDA,SPACE=(1024,(50,20»

//SYSLIB

DD

DSN=SYS1.TELCMLIB,DISP=SHR

/ /SYSLIN

DD

DSN=*.STEP2.ASM. SYSPUNCH,

//

//ASM.SYSIN

/*

//

//ASM.SYSIN
//

//
DISP=(OLD,PASS)
L ________________________________________________________________________
Figure 34.

~--------------

Job stream to Tailor MCP

System Implementation

63

LINEGRP MACRO INSTRUCTION FORMAT

r---------------------------------------------------------------------------------------,
Operation
Operand
I

I Name

~---------------------------------------------------------------------------------------~
(name)LINEGRP
TERM=type
DDNAME=ddname
LINENO=number
[UNITNO=number]
[TRANTAB=(table ,table ••• )]
[CODE=(string ,string ••• )]

DIAL={~~S}

[ INTVL= number]

rFEATURE=~REAK' ) (;ATTN, ) (TOSUPPR)]
L
NOBREAK, NOATTN,
[ADDR=cha acter string]
[SCRSIZE=(integer, integer)]
[TERMNO=(integer, integer)]

TERM=
Specifies the type' of terminal making
up this line group. Select only one
of the following:
1050 -- defines a line group
consisting of IBM 1050
Printer-Keyboards on either
switched (dial) ·or
non-switched (direct) lines.
2741 -- defines a line group.'
consistin~ of IBM 2741
Commun'icat10ns-Terminal ~ on
either switched or
non-switched lines.
5041 -- defines a line group
consisting of both IBM 2741s
and IBM 1050s. The terminals
in this line group must be on
switched (dial) lines.
3335 -~ defines a line group
consisting of Teletype Model
33 or Model 35 or both. The
terminals in this line group
must be on switched (dial)
lines.
226L -- defines a line group
consisting of IBM 2260 Display
Stations connected on a local
line.
226R -- defines a line group
consisting of IBM 2260 Display
Stations, connected on a
remote line, and optionally
IBM 2265 Display Stations.
2265
defines a line group
consisting of IBM 2265 Display
Stations.
DDNAME=
Specifies the ddnames of the DD
statement that define the terminal
lines in the line group as a data set.
These DD statements are found in the
cataloged procedure that is used to
start the MCP.
64

Time Sharing Option Guide

(Release 20.1)

LINENO=
Specifies the number of lines in this
line group. The value is an integer
between 1 and 51.
UNITNO=
Specifies the number of basic units
per buffer for terminals in this line
group. A basic unit is used by TCAM
to construct I/O buffers. The default
value is 1.
TRANTAB=
Specifies the translation tables to be
used for this line group. If this
parameter is omitted, all of the
supplied translation tables that are
valid for the terminal type specified
by TERM= will be included except those
marked with an asterisk.
TERM=

TRANTAB=

Comments

1050

1050

2741

CR41
EB41
BC41*

Correspondence
EBCDIC
BCD

5041

1050
BC41*
EB41
CR41

BCD
BCD
EBCDIC
Correspondence

3335

TTYB
TTYC*

TTY parity
TTY non-parity

226L

EBCD

226R

2260

2265

2265'

*Not used as a default translation
table.

Note: If more than one .table is
specified explicitly or implied by
default, the MCP will determine the'
proper translation table dynamically
using the CODE parameter.

NOATTN

TOSUPPR

CODE=
Specifies the character string used to
determine the terminal character set.
Each time a terminal is connected, the
MCP translates the input line from
that terminal, using each of the
translation tables specified in the
TRANTAB operand. The MCP compares the
translated result with the character
string specified in the CODE= operand.
When the MCP finds a match, it uses
the appropriate translation table with
that terminal from then on.

D = Default.
A = Assumed.
I = Invalid.
o
Optional.
Feature

An installation can specify a maximum
of four character strings other than
LOGON, but they must be eight or less
characters.

BREAK
NOBREAK
ATTN
NOATTN
TOSUPPR

DIAL=
Specifies whether the line group is a
dial (switched) line group.
If this
parameter is omitted, YES is assumed.
DIAL=NO is required for TERM=226L,
226R, 2265 and TERM=3335.

FEATURE=
Specifies the special features that
define this line group:
BREAK

NOBREAK

ATTN

Specifies that terminals in
this line group have the
Transmit Interruption
feature.
Specifies that terminals in
this line group do not have
the Transmit Interruption
feature. This operand should
be specified when any of the
terminals in the line group
do not have the feature.
Specifies that terminals in
this line group have the
Attention feature (Receive
Interruption. )

For 1050 terminals, this
operand specifies that the
optional Text Time-out
Suppression feature is
present. This operand
applies only to 1050
terminals and should be
specified only if all 1050
terminals in a 1050 or 5041
group have the feature.
When
specified read inhibit rather
than read commands will be
used.

The following table describes the
features which may be specified for
the 1050, 2741, 5041, 2260 and the
3335 (TWX): where

The default is CODE=LOGON unless the
TRANTAB operand specified both BC41
and EB41 (2741 BCD and 2741 EBCDIC).
If both EBCDIC and BCD character sets
are present in the line group, ,the
default is CODE="LOGON.

INTVL=
Specifies the poll delay intervals in
seconds for polled lines. The value
is an integer between 1 and 255. If
, this parameter is omitted, a value of
two is assumed for polled lines.

specifies that terminals in
this line group do not have
the Attention Feature.

1050

o

2741
D

5041 3335 2260

o

A

D

I
A
I
I

D
D

o
D

D

o
o

o

o

I

0*

I
A
I
A
I

*TOSUPPR is optional for the 1050
terminals in a 5041 line group.
It is
assumed for the 2741 terminals in the
same 5041 line group.
ADDR=
Specifies the station identification
character (1050) or the two byte
control unit, device address
(226R,2265) of the terminals in the
line group. The character string
should be the hexadecimal equivalent
of the appropriate transmission code.
Hexadecimal characters should be
specified without framing characters.
For example if the station
identification character is "A", the
correct specification is ADDR=E2. the
hexadecimal equivalent of the 1050
transmission code for the character
"A", not ADDR=C1, the hexadecimal
equivalent of the EBCDIC character
"An. To find the hexadecimal
equivalent of a given character in a
specific transmission code, consult
the component description
publications. For the 1050, only the
station identification character value
need be specified: the component
selection character values will
default to the common polling and
addressing values for input and
System Implementation

65

output. respectively.
is not supported.

1050 multidrop

order in which polling is to take
place. Each character string should
be the hexadecimal equivalent of the
appropriate transmission code
representation for the terminal
involved. Hexadecimal characters
should be specified without framing
characters.

This parameter is not valid for
TERM=2741 or TERM=3335. This
parameter is required for TERM=1050 or
5041. For configurations in which the
addressing characters vary among the
different terminals in the line group
as in 2265. the addressing characters
should be specified using LISTTA macro
instructions (see below) rather than
in the LINEGRP macro instruction.
SCRSIZE=
Specifies the screen dimensions of the
display station(s) on the line. The
first integer specifies the number of
rows on the screen. The second
integer specifies the number of
characters per row. Standard IBM
screen size are 12x80, 12x40. 6x49.
and 15x64 non-standard, sizes will be
accepted but a' warning will be given.
The default for this parameter is
(12x80) •

Example:

ADDR=(COA1.COA2).

For a 1050, only the station
identification character value need ,by
specified.
SCRSIZE
Specifies the screen dimensions of the
display station(s) on the line. The
first integer specifies the number of
rows on the screen. The second
integer specifies the number of
characters per row. Standard IBM
screen size are 12x80. 12x40, 6x49,
and 15x64 non standard sizes will be
accepted but a warning will be given.
The default f~ this parameter is
(12x80) _

TERMNO= _
specifies the number of terminals
attached to each non-switched line,
used with TERM=226R, and 2265.

TSOMCP Macro

LISTTA Macro

The TSOMCP macro instruction:

TSOMCP MACRO INSTRUCTION FORMAT

The LISTTA macro instruction specifies
variations in device address (ADDR) within
a line group. One or more LISTTA macro
instructions can appear after each LINEGRP
macro instruction.
Each LISTTA macro
instruction modifies one line (RLN) within
a line group.

• Names the MCP, (provides the CSECT
name).
• Defines the size of the TCAM basic
units used to construct terminal I/O
buffers~
• Specifies which TCAM trace tables will
be provided.
• Specifies whether a cross-reference
table will be included in the MCP.
• Specifies whether the operator can
specify parameters when he starts the
MCP.

LISTTA MACRO INSTRUCTION FORMAT

r---T----------T-------------------------,

, I Name I operation I Operand
I
r----+----------+--~----------------------~
I name I LISTTA
IRLN=integer
I
I
I
I [.ADDR= (chars ,chars. - -) ] I
" , ' IL____ I __________
'
I _________________________
[, SCRSI ZE]
JI

I

~

~

r----T----------T-------------------------,I
r----+----------+-------------------------i
I
I
I
I

I Name I OperationlOperand

I I name I

RLN
specifies the relative line number
within a line group to which the
attributes specified in this macro
instruction call apply_ For example,
RLN=l refers to the first line in the
line group.
'

I

TSOMCP

I
I
I
I
I

UNITSIZ=number]
I
TRACE=number]
I
I
I
DTRACE:::numbe,rJ
I
I
I
LNUITs=number]
I
I
I
UNITSIz=number]
I
I
I
I OLTEST=number.J
I
I
I
I[OPTIONS=(XREF,PROMPT)]
I
~----~----------~-------------------------~
L ________________
________________________
JI
INote:
All operands
are optional.
I

~

ADDR=
Specifies the alphabetic station
identification character (1050) of the
terminal(s) on this line. One
character string must be specified for
each terminal on the line.
Subparameters must be specified in the

66

Time Sharing Option Guide

(Release 20.1)

name
Names the start of the MCP and
provides the CSECT label for the
generated program. This field is
required.

UNITSIZ=
Specifies the size of a TCAM basic
unit and must be a value between 33
and 255 inclusive. If omitted, the
MCP uses a default size selected to.
yield the best system performance
UNITSIZ should be a multiple of 8 plus
4 for efficient core usage.
TRACE=
Specifies the number of TCAM I/O trace
table entries in the Message Control
Program. The default value is zero.
Maximum value is 65535. See IBM
System/360 TCAM Programmers GUIde and
Reference.
DTRACE=
Specifies the number of TCAM subtask
trace table entries in the Message
Control Program. The default value is
zero. Maximum value is 65535. See
IBM System/360 TCAM Programmers Guide
and Reference.
LNUNITS=
specifies the number of TCAM basic
units (See IBM System/360 TCAM
Programmers Guide and Reference) to be
provided in the buffer pool for
creating line buffers for this MCP. A
maximum of 65,,535 may be specified •.
If this operand is omitted, the system
will calculate a default value using
the following algorithm:
LNUNITS=
2 x (number of terminals) x (UNITNO .
value) or
2.5 x (number of terminals) x UNITNO
for 2265/65
where,
UNITNO (as specified in each LINEGRP
macro) represents the number of units
per buffer for terminals defined in
the associated line group. If UNITNO
is omitted in the LINEGRP macro, the
default value (1) is used. This means
that each buffer will consist of one
basic unit.
If both the LNUNITS and UNITNO
keywords are defaulted, the buffer
pool created will consist of 2 buffers
per terminal with each buffer being
one basic unit in length using PCI
buffering for both input and output.
OLTEST=
Specifies the number of On-line Test
procedures which can execute
simultaneously. The value must be
between 0 and 255. The default is 0,
meaning On-line Test not supported.

OPTIONS
XREF
A cross-reference table
including control blocks
for each line will be
included in the MCP. If
this option is omitted. the
cross-reference table will
be excluded.
PROMPT
If PROMPT is specified, the
system operator will be
asked to enter parameters
when TCAM is started. At
that time he may enter and
override some of the
parameters specified when
the MCP was assembled. The
following TCAM parameters
are ones which an
installation may want to
specify when it starts TCAM
for TSO. The last
parameter entered must be a
"U" to end the prompting
process. See IBM
'
System/360 TCAM
Programmer's Guide and
Reference for a description
of the INTRO macro
instruction and the
parameters which can be
overridden.
KEYLEN = integer
K = integer
Specifies the size of the
basic units, with which the
terminal I/O buffers are
constructed. This
corresponds to UNITSIZ=
parameter.
LNUNITS = integer
B = integer
Specifies the number of
basic units which are used
to build buffers,
corresponds to LNUNITS.
The value must be between 0
and 65,535
STARTUP
= C
S

Specifies that a "cold"
start is to be performed
following a shutdown of the
Message Control Program or
. a system failure. It is
required if OPTIONS=PROMPT
'was specified on the TSOMCP
macro instruction.
System Implementation

67

CROSSRF=integer
F,= integer

Specifies the maximum
number of Command Input
Blocks (CIB's) that can be
used at ~ny one time in the
TCAM subsystem, CIS's are
the buffers used to contain
operator control messages
entered at the system
console. Maximum that can
be specified is 255; if the
operand is omitted, nCIB=2 n
is assumed. At least two
CIB's should be specified,
since START uses one. If
an attempt is made to enter
an operator control message
from the system console,
and the number of CIS's
specified is already in
use, the message is
rejected by TCAM.

Specifies the number of
entries in the cross
reference table, a
debugging aid. If
OPTIONS=XREF is specified
in the TSO MCP, one entry
will be generated for each
line. If the operator
specifies fewer entries
than there are
simultaneously open lines,
lines opened after the
table is full will have no
entries
TRACE = integer
T = integer
Specifies the number of
TCAM I/O trace entries to
be allocated" corresponds
to TRACE= in the TSOMCP
macro instruction,.
DTRACE = integer
A = integer
Specifies the number of
entries in the TCAM
Dispatcher Trace Table,
corresponds to DTRACE= in
the TSOMCP macro. The
Dispatcher Trace Table is a
debugging aid that keeps a
sequential record of TCAM
subtasks activated by the
TCAM dispatcher. One four
word entry is created for
each subtask activated;
when the end of the table
is reached" the table is
wrapped around; new entries
overlay the oldest entries.
Maximum to be specified is
65,535: If 0 is specified,
the table is not generated.
OLTEST=number
O=number
Specifies the number of
On-line Test procedures
that can execute
simultaneously. This
parameter corresponds to
the OLTEST parameter of the
TSOMCPmacro instruction.
The default is 0" which
indicates that On-line Test
is not supported.
CIB = integer
C = integer
68

Time Sharing Option Guid-e

(Release 20.1)

Figure 35 and 36 show the MCP macro
specifications for two sample systems.
The first system has:
1.

2.
3.

10 lines for leased, (non-switched),
2741's; all are BCD terminals and use
EBCDIC character set only. All
terminals in this line group have both
Receive and Transmit Interrupt
features.
5 lines of teletype (which could be
either 33 or 35).
The system operator will be prompted
to enter TCAM parameters when he
starts TCAM. At that time he can
override any of the parameters
specified on the TSOMCP macro, as well"
as other TCAM parameters. See the
description of the TSOMCP macro
instruction, for parameters pertinent
to TSO. (The operator will always
have to reply ns=cu n ; STARTUP=COLD and
a nun to terminate prompting.) A
Dispatcher Subtask Trace Table, useful
for debugging purposes, is to be
included in the MCP. It ,'will contain
100 4 byte entries. (DTRACE=100)

The sample system shown in Figure 36 has 10
dial lines, to be used by both 1050's and
2741's. The station identification
character for the 1050's is nAn. Notice
that it is specified in terminal
transmission code, (E2) not EBCDIC (C1).
'Assume there are four, types of terminals in
the line group.
A.

Three 1050's" with Text Timeout
Suppression feature, Receive and
Transmit Interrupt features.

B.

One 1050, with Text Timeout
SUppression feature.

C.

Five 2741's, Correspondence Code,
Receive and Transmit Interrupt
features.

D.

Two· 2741's, EBCDIC code.

I The

default is ATTN and NOBREAK.

Users at terminals in groups A and C would
use the TERMINAL command to request
Transmit Interrupt handling, (BREAK), the
instaillation could provide a special LOGON

cataloged procedure for these users
containing a suitable TERMINAL command as
the PARM value. Users at terminals in
groups Band D would not be able to cause
an attention interruption during output, or
while the keyboard is locked. They would
use the TERMINAL command to set up
simulated attention breaks by time interval
when the keyboard is locked. or after a
number of consecutive lines of output. when
output is being sent. This also could be
specified in a LOGON procedure.

r---------------------------------------------------------------------------------------,

ILINEGRP
TERM=2741,DDNAME=LNGP2741,LINENO=10.
X
I
I
TRANTAB=EB41,DIAL=NO
I
ILINEGRP
TERM=3335.DDNAME=LNGPTWX.LINENO=5
I
IL_______________________________________________________________________________________
TSOMCP
OPTIONS=PROMPT.DTRACE=100
JI
Figure 35.

Sample MCP

r--------------------------------------~-----------~------------------------------------,

ILINEGRP
TERM=5041.DDNAME=DIAL5041.LINENO=10,ADDR=E2. X
I
FEATURE=TOSUPPR
I
I
_______________________________________________________________________________________ JI
ILTSOMCP
Figure 36.

sample MCP

system Implementation

69

Writing Cataloged Procedures for TSO
Two categories of cataloged procedures are
used by TSO. The first includes procedures
invoked by the system operator when he
starts any of these four TSO tasks:
1.
2.
3.
4.

The Message Control Program (MCP)~
The Time Sharing Control Task (TSC).
The Background Reader for the SUBMIT
command (BRDR).
The TSO Trace Writer.

The second category 'consists of those
procedures invoked each time a LOGON
command is entered at a terminal. The PROC
operand of the LOGON command specifies the
name of the cataloged procedure which:
1.

Contains the JCL statements that
define the data sets available to the
terminal user.

2.

Specifies the name of the Terminal
Monitor Program (TMP) supplied with
TSO or the user-written substitute for
the TMP.

Both categories of cataloged procedures
must be members of SYS1.PROCLIB or members
of partitioned data sets concatenated to
SYS1.PROCLIB.

Message Control Program
The cataloged procedure used to start the
Message Control Program specifies through
the PGM= operand of the EXEC statement the
MCP to be started. The MCP should be named
IEDQTCAM. This name allows the MCP to run
in a region smaller than MINPART and ensure
that the MCP can not be canceled, that is
the operator must halt it.' Specify
TIME=1440 to eliminate timing. Specify
ROLL=(NO,NO) to preclude an attempt to
Rollout the MCP. Specify DPRTY=(15,15) to
insure high priority. The MCP must run at .
a higher priority than the TSC.
The cataloged procedure used to start
the MCP also must define any terminals
attached to the system as data sets. This
is done through the ddnames specified in
the LINEGRP macro instructions used in
generating the MCP. Figure 37 shows two
procedures that can be used to start the
two sample MCPs generated in Figure 34.
Time Sharing Control Task
The cataloged procedure used to start the
Time Sharing Control Task contains the Job
Control statements defining all the system
resources the TSC requires. The procedure
consists of an EXEC statement and several
Data Definition statements.

r--------------------------------------------------------------------------------------,
//MCPl
EXEC PGM=IEDQTCAM,ROLL=(NO,NO) ,TIME=,1440,DPRTY=(15,15) ,REGION=70K
I
//LNGP2741
//
//
//

//
//
//
//
//
//

//LNGPTWX
//
//
//
//

OD u'NIT=021
OD UNIT=022
DD UNIT=023
00 UNIT=024
DD UNIT=025
OD UNIT=026
OD UNIT=027
DD UNIT=028
DD UNIT=029
00 UNIT=02A
DD UNIT=02B
OD UNIT=02C
OD UNIT=02D
DD UNIT=02E
OD UNIT=02F

FIRST LINE GROUP DATA SET 2741

SECOND LINE GROUP DATA SET TWX

/ /MCP2
EXEC PGM= IEDQTCAM, ROLL= (NO, NO) .,TIME=1440, DPRTY= (15,15) ,REGION=66K
//OIAL5041
OD UNIT=021 LINE GROUP DATA SET
//
DO UNIT=022
//
DO UNIT=023
//
OD UNIT=024
//
DO UNIT=025
//
OD UNIT=026
//
DD UNIT=027
//
OD UNIT=028
//
DD UNIT=029
//
OD UNIT=02A
L~-----------------------------------------------------

Figure 37.
70

I
I
I
I
I
I
I
I
I

Sample MCP Start Procedures

Time Sharing Option Quide

(Release 20.1)

_________________________________

The EXEC statement of the cataloged
procedure that starts the Time Sharing
Control Task .• specifies:
• The TSC program name. which is
IKJEATOO.
• The TSC region size. If the TSC needs
a different sized region. it will
obtain one.
• ROLL= (NO, NO) to preclude an attempt to
Rollout the TSC region, if
OPTIONS=ROLLOUT has been specified
during system generation.
• DPRTY=to set a priority for the TSO.
It must be lower than the MCP.
Six data sets must be defined .•
• SYSPARM -initiation
parameters
TSO System

The library containing TSC
parameters,. These
are ,discussed under ·Writing
Parameters".

• SYSUADS -- The User Attributes Data
Set. this data set cannot be
concatenated.
• SYSLBC -- The broadcast data set which
contains messages from the SEND
command.

swapping it would use'SYSWAPOO and SYSWAP01
as the ddnames .•
'If an installation wanted to use a IBM
2301 drum for a prime swap data set and a
IBM 2314 as overflow, the ddnames would be
SYSWAPOO for the 2301-the prime data set.
and SYSWAP10 for the 2314., the first
overflow data set. If a system or TSO
failure causes TSO to be restarted, you can
use IMDPRDMP program to save the swap data
sets before attempting to restart TSO.
When invoking IMDPRDMP, the DD statements
for the swap data sets should be the same
as those in the TSO cataloged procedure;
the //PRINTER DD statement writes to tape
with chained scheduling and a large
blocking factor so that the data sets are
dumped quickly. The publication IBM
System/360 Operating system: Service Aids,
GC28-6719 shows the procedures for
analyzing system failures and how to use
the IMDPRDMP program to save the swap data
sets.
STARTING AND STOPPING TSO
When the
he must:

Issue a .START command to start the
Message Control Program. The operand
of the START' command is the name of
the cataloged procedure that provides
the, Job Control statements necessary
to execute the MCP. For example if
the cataloged procedure used to start
the MCP is named TCAM, the operator
will issue a START TCAM command.

2.

Issue'a START command to start the
Time Sharing Control Task (TSC). The
operand of this command names a
cataloged procedure used to start the
TSC.. For example if the cataloged
procedure used to start the TSC is
named. TS., the operator would issue a
START TS command.

• SYSTSDP the TSO dump usually a tape
volume.
FOr each of these data set definitions.
DIS.P=SHR should be specified.
Figure 38 shows a sample cataloged
proced ure to start the TSC.
The data definition ddname on the DD
statement defining the SWAP data set
specifies whether serial or parallel
swapping is to be used. The ddname is of
the form
SYSWAPln
Where 1. indicates the. level of the data
set, i.e., 0 for prime, 1 for first
overflow; and n is the data set number at
this level.

I

For example, if an installation has two
data sets and wants to use parallel

starts TSO for the day.

1,.

• SYSWAPOO -- The swap data sets.
• IEFPDSI -- The partitioned data set
containing LOGON cataloged procedures.
This data set may be either
SYS1.PROCLIB or a partitioned data set
dedicated to LOGON procedures. A
dedicated data set will speed up LOGON
processing.

oper~tor

When the operator stops TSO for the day,
he must:
1..

Issue a STOP command to stop the Time
Sharing Control Task. The operand of
the STOP command must be the same as
the operand that was used to start the
TSC.

2.

Issue a HALT command to stop the
Message Control Program. If the PGM=
operand of the EXEC statement in the
cataloged procedure used to start the
MCP is IEDQTCAM, then the MCP cannot
be cancelled with a CANCEL command.
If the operator cancels the MCP. the
TSO must be stopped before the MCP is
restarted. The MCP cannot be halted
System Implementation

71

r---------------------------------------------------------------------------------------,I

I//IEFPROC
EXEC PGM=IKJEATOO,ROLL=(NO,NO),DPRTY=(13,13)
I//SYSPARM - DD DSN=SYS1.PARMLIB,DISP=SHR
I//SYSUADS
DD DSN=SYS1.UADS,DISP=SHR
I//SYSLBC
DD DSN=SYS1.BRODCAST DISP=SHR
I//SYSWAPOO DD DSN=SYS1.SWAP1,DISP=SHR
1//SYSWAPOl DD DSN=SYS1.SWAP2,DISP=SHR
1/
/IEFPDSI
DD DSN=SYSl. PROCLIB"DISP=SHR
.
L______________________________________________________________________
Figure 3S.

~

______________

I
I
I
I
I
I

~J

sample Cataloged Procedure to Start Time Sharing Control Task

with a HALT command unless the TSO is
stopped.

• Pass the Background Reader standard
Reader-Interpreter parameters.
• Define required data sets.

DEFINING A UADS USING THE TSC PROCEDURE
When a TSO system is first started after
system generation, it is necessary to
construct a UADS using the ACCOUNT command.
The distributed UADS contains one valid
user:IBMUSER and this user is authorized to
use one procedure: IKJACCNT. He should
use the ALLOCATE command to define a new
UADS, specifying its volume serial number,
and define his DADS structure with a series
, of ACCOUNT command ADD subcommands. He
should then log off " stop the system:, and
change the SYSUADS DD statement in the TSC
start procedure, to point to the new UADS .•
If the cataloged procedure defines SYSUADS
though a DSN= operand, then he need only
recatalog the data set name in his system
catalog.

The Background Reader, (BRDR), runs as a
system task. It is started by the
operator. It interprets Job Control
Language passed by a terminal user with the
SUBMIT command. If there is no input for
the BRDR, it will relinquish its region and
wait for input. OUtput from the BRDR is
placed on SyS1.JOBQE and is queued for
execution by a standard initiator. The
cataloged procedure that provides the Job
Control Language to start the Background
Reader is similar to other reader
procedures. The BRDR program name is
IKJEFF40. Figure 39 shows an example of a .
BRDR procedure. For further information on
writing system reader/interpreter cataloged
procedures, see IBM System/360 Operating
System: System Programmers Guide,
GC2S- 6550.

Background Reader (BRDR)
The cataloged procedure used to start the
Background Reader (BRDR) contains Job
Control statements that
• Specify the program name of the
Background Reader.

An installation exit can gain access to and

modify or delete any JCL passed by the
SUBMIT command processor. The section,
"Writing Installation Exits for the SUBMIT
Command" describes how to write this exit.

r--------------------------------------~------------------------------------------------,

I//BRDR
EXEC
1//
1//
1//IEFPDSI DD

PGM=IKJEFF40"
I
REGION=70K"
I
PARM= • READERPARM'
1
DSN=SYS1. PROCLIB,
1
1//
DISP=SHR
I
I//IEFDATA DD
UNIT=SYSDA
I
1//
SPACE= (SO, (500,50) ,RLSE,CONTIG) "
1
1//
DCB= (BUFN0=2"LRECL=SO"BLKSIZE=SO,DSORG=PS,
1
1/ /
RECFM=F" BUFL=SO)
1
L_______________________________________________________________________________________
J1
I//IEFRDER
DD
DUMMY

Fi~ure

72

39.

Sample Background Reader (BRDR) Procedure

Time Sharing Option Guide

(Release 20.1)

r------------------------------------------------------------~--------------------------,

//TSTRACE PROC
//
//
//

TRREGN=20K,
TRPARM=100,
VOLCNT=20,
BLKSIZh=2048

DEFAULTS:

REGION SIZE=20K
.
ENTRY RATE=100 ENTRIES/SEC
VOLUME COUNT=20
BUFFER SIZE=2048

//*
//*

//*
//*
//*

//*
//*

//*
//*
//*

DESCRIPTION OF SYMBOLIC PARAMETERS
TRREGN - TRACE WRITER REGION SIZE
AN ESTIMATE OF THE RATE AT WHICH ENTRIES WILL BE MADE
TRPARM
INTO TRACE BUFFERS IN NUMBER OF ENTRIES PER SECONDS
MAXIMUM NO. OF VOLUMES AVAILABLE FOR TRACE DATA SF!'
VOLCNT
PER RUN. MAXIMUM VALUE ALLOWED IS 255.
BLKSIZE- SIZE OF TRACE BUFFERS. MINIMUM SIZE ALLOWED BY TRACE
WRITER IS 128iMAXIMUM ALLOWED BY SYSTEM IS 32,,760

//IEFPROC EXEC PGM=IKJFATRC,
DPRTY=14,
REGION=&TRREGN.
PARM=&TRPARM

l//
1//
1//

1//*

I//IEFRDER DD

DSNAME=TSTRACE,

INVOKES INITIALIZATION MODULE
PRIORITY SHOULD AT LEAST BE HIGHER
THAN CPU-BOUND JOBS IN THE qYSTEM
NAME OF TRACE DATA SET

DATA SET CREATED ON 9-TRK TAPE(S)
1//
DNIT=2400,
1//
DISP=(NEW,KEEP),
1//
DCB=(BLKSIZE=&BLKSIZE),
L______________________________________________________________________________________
_
1//
VOLUME=(",&VOLCNT)
Figure 40.

Sample TSO Trace Start Procedure

TSO Trace Writer

Logon Cataloged Procedure

The TSO Trace Writer collects Time Sharing
Driver Entry Codes and writes them out to a
data set. The Trace Writer operates in its
own partition and is started by the
operator. A cataloged procedure
distributed with TSO defines the resources
needed to run TSO Trace.

The LOGON cataloged procedure defines the
system resources that the terminal user can
use. The LOGON cataloged procedure can be
named in the PROC operand of the LOGON
command, supplied through a user exit from
the LOGON processor. This procedure:
• Defines or allows for dynamic
allocation of all data sets used by the
terminal user.

The cataloged procedure used to start
the TSO Trace Writer:

• Specifies which program is to be
invoked after LOGON, the TMP
distributed with TSO or a user written
program.

• Specifies the program name of the TSO
Trace facility.
• Passes to the Trace Writer a parameter
which controls sampling rate.
• Defines the TSO Trace output data set.

The data sets defined can include the
common system utility data sets, and data
sets used by the compilers such as SYSUT1,
SYSUT2 or even the specialized data sets
used by the Assembler or the Linkage

Figure 40 shows the procedure. The
sample procedure specifies that the Trace
Writer output data set is to be written to
a 2400 tape unit. The output data set can
also reside on disk. The user may specify
that chained scheduling be used if trace
data set is on tape. If an installation
specifies in the DCB operand of the DD
statement an NCP value, it must be at least
three, that is,
.
DCB=(BLKSIZE=&BLKSIZE,NCP=3).
An installation should not include a
SYSABEND or SYSUDUMP statement in the TSO
TRACE cataloged procedure.

Edito~.

I

In addition any data sets that will be
allocated through the ALLOCATE command must
have a corresponding DD DYNAM statement.
Any data sets needed by a processing
program such as a compiler or a system
utility can be def,ined dynamically through
the ALLOCATE command or through Dynamic
Allocation.
The Terminal Monitor Program
with TSO is named IKJEFT01. If
written TMP is to be used for a
procedure, then its module name

distributed
a user
particular
should be

system Implementation

73

substituted for IKJEFTOl in the PGM=operand
on the EXEC statement.

statement 4 defines the EDIT utility data
set., statements 5" 6, and 7 define utility
data sets used by the COBOL compiler.
statement 8 defines the COBOL subroutine
library. statements 11 through 17 define
data sets which can be allocated during the
terminal session by the user or a program
he inVOkes, using the ALLOCATE command.
statement 18 defines SYSPROC, an
installation defined partitioned data set
containing command procedures,.

The PARM operand on the EXEC statement
is interpreted by the Terminal Monitor
Program (TMP) as the first line of input
from the terminal.
'
ROLL=(NO,NO) should be specified to
preclude rolling out the Time Sharing
Region.
REGION= is ignored
The command library, SYS1.CMDLIB,
contains the command processor load
modules. An installation can also load
many of these modules into the TSO Link
Pack Area. The command library can be
concatenated to SYS1.LINKLIB or defined in
the LOGON procedure as a step library.
Note: If the command library is defined
in the LOGON procedure as a step library,
the modules in the TSO Link Pack Area will
not be used. This will degrade
performance.
To concatenate SYS1.CMDLIB to
SYS1.LINKLIB, use the LNKLSTOO member of
SYS1.PARMLIB. See IBM system/360 Operating
system: system Programmer's Guide,
GC28-6550 for further information about
using LNKLSTOO.

TSO System Parameters
When 'the Time Sharing Control Task
initializes the TSO system, it reads a
series of parameters from a member of the
partitioned data set named on the SYSPARM
DD statement. The SYSPARM DO statement
, appears in the cataloged procequre used to
start the TSC. The member name is IKJPRMOO
or a name supplied by the operator on the
START' command. There are three types of
parameters.
• TSC parameters.
• Time Sharing Driver parameters.
• Parameters dealing with the allocation
of terminal buffers.

Figure 41 'shows an example of a LOGON
procedure.
The sample LOGON procedure can be useful
to a programmer using COBOL. statement 1
specifies the TSO standard TMP for
execution. statement 2 defines the data
set containing the HELP command messages.
statement 3 defines a utility data set used
by several command processors while

All of these parameters have an effect on
the size of the, TSC region. The
publication IBM system/360 Operating
System: Storage Estimates gives formulas
for assessing the effects of these
parameters on region size.
The Time Sharing Control Task Parameters
The TSC pa'rameters:
• Define the number and size of the Time
Sharing regions.

r---------------------------------------------------------------------------------------,

I//COPROC EXEC PGM=IKJEFT01,ROLL=(NO,NO)
001
I//SYSHELP DD DSN=SYS1.HELP,OISP=SHR
002
1//SYSUTl
00 DSN=&SYSUT1,UNIT=SYSDA, SPACE= (CYL, (10,10»
003
I//SYSEDIT 00 DSN=&EOIT, UNIT=SYSDA, SPACE= (1688., (50,20»
004
1/ /SYSUT2
DO OSN= &SYSUT2, UNIT=SYSDA, SPACE= (TRK, (10,,5»
005·
1//SYSUT3
00 OSN=&SYSUT3,UNIT=SYSOA,SPACE=(TRK,(10,5»
006
1/ /SYSUT4
DO OSN= &SYSUT4, UNIT=SYSDA, SPACE= (TRK, (10,,5»
007
I//SYSLIB
OD DSN=SYS1.COBLIB,OISP=SHR
'
008
I//SYSIN
00 TERM=TS
009
I//SYSPRINT DO TERM=TS
010
1//001
00 OYNAM
011'
1//002
DO OYNAM
012
1//003
DO OYNAM
013
1//004
DO OYNAM
014
1//005
DO OYNAM
015
1//006
DD OYNAM
016
1//007
00 OYNAM
017
L_______________________________________________________________________________________
J
1/
/SYSPROC DO DSN=CMDPROC.DISP=SHR
018
Figure 41.
74

Sample LOGON Catalogued Procedure

Time Sharing Option Guide

(Release 20.1)

• specify the number of users.
• specify whether SMF is to be used.
• Specify which DRIVER to use.
• Limit the number of tracks the SUBMIT
command can use to queue jobs.
• Defines the module contents of the Time
Sharing Link Pack Extension.
The contents of the Time Sharing Link
Pack Area, that part of the TSC region
containing reenterable modules common to
different TSO applications has a direct
effect on system response and overhead.
The following routines are used by
different users many times during an
average session and should reduce loading
time if included.

determining which queue a user will be put
in. If SWAPLOAD has been specified, the
~XSWAP parameter defines the maximum swap
load for .each queue.
.
In a single region system, NOWAIT and
NOACTIVITY should be specified.
The decay constant for the wait estimate
(DECAYWAITl and the activity estimate
(DECAYACT) if set to lOa, (that is, a decay
constant of one since the value is in
hundredths >.. will mean tha t the current
value has a weight equal to the total prior
value. This will "smooth" out the effects
of excessive variations.
MINSLICE, the minimum amount of time
given to a terminal user, should be set to
allow a useful amount of execution time.

• The I/O Service routines -- that is
GETLINE, PUTLINE, PUTGET, and STACK .•

If PREEMPT is specified, CYCLES should be
set to zero. since a· higher priority queue
will preempt a lower priority queue.

• The TMP mainline routines.

Buffer Control Parameters

• Command S~an
a service routine used
to check the syntax of commands.
• TIME -- a routine used to get the time
of day.

TSO controls the allocation of terminal
buffers in the TSC region. Buffers
allocations are based on initial parameters
specified in SYS1.PARMLIB.

• PARSE -- a routine that analyzes the
syntax of commands.

The BUFSIZE= parameter specifies the
size in bytes of each TSO. terminal buffer.

In addition ~f EDIT is being used
extensively, portions of the EDIT command
processor should be included.
-.The Edit Mainline routines.
• INPUT subcommand processor.
• LIST subcommand processor.
- CHANGE subcommand processor.
• Implicit change processor, that is, the
update function for portions of
individual lines.
Driver Parameters
The DRIVER parameters specify:
1..
2.

What type of queueing service to use
in a region~
What the cutoff points for each queue
are.

For example, the SWAPLOAD/NOSWAPLOAD
parameter specifies whether or not swap
load will be used as a criterion for

The BUFFERS= parameter specifies the
total number of TSO buffers. The remaining
parameters deal with allocating the number
of buffers per user when a given number of
users is logged on.
TSO maintains a count of the number of
allocated buffers per user, both for input
and output. When the number of buffers
either for input or output rises to a given
level, the user is prevented from
continuing until more buffers are
available~
If the specified maximum number
of input buffers are allocated, the
keyboard is locked up. If the maximum
number of output buffers are allocated. the
user's program is put into a wait. This
level is determined by the OWAITHI value
for output and the INLOCKHI value for
input.
When the number of logged on users
changes by the percentage specified in the
USERCHGE parameter. and when the number of
users falls below SLACK value, the number of
buffers per user is readjusted. . The number
of buffers for input and output are
distributed in the same ratio as specified
by INLOCKHI and OWAITHI.

System Implementation

75

system Parameter Format

• TIOC -- parameters controlling terminal
buffer allocation.

The format of the parameter records is:
parameter-owner keyword=value •• '.
The possible parameter-owners are:
• TS -- parameters for the Time Sharing
Control Task.
• DRIVER -- parameters for the Time
Sharing Driver.

76

Time Sharing Option Guide

(Release-20.1)

Keywords cannot be continued but may be
repeated. This has the effect of
continuation, as repeated keyword values
are added on to those already specified.When two parameters conflict, the last
value is used. Figure 42 shows an example
of system parameters for a single region
model 50 and for a double region model 65.
Figure 43 shows the syntax and meaning of
the start parameters.

PARAMETER
OWNER

KEYWORD

MEANING

TS

TERMAX=nnnn

Specifies maximum number of users.

USERS=nnnn

specifies initial maximum number of users, defaults to
TERMAX, can be changed by MODIFY command.

REGNMAX=nn

Specifies number of TSO user regions.

MAP=nn

specifies the number of MAP entries, used to reduce
swapping of unused storage.

Standard SMF parameters, see MVT Job Management.

DRIVER

Figure 42.

DSPCH=cccccc

specifies first six characters of Time Sharing Driver.
Defaults to IKJEAD, driver supplied with TSO. This
parameter defines the names of all four Driver
modules. That is the driver supplied with TSO has
four modules, IKJEADOO to IKJEAD03.

LPA=(module list)

List of modules to be included in Time Sharing Link
Pack Extension.

REGSIZE(nn)=(mmK,
iiik)

specifies region size (mmk) and LSQS size (iiik)
for region nne Defaults to zero.

SUBMIT=nnnn

specifies the maximum number of tracks in the SUBMIT
command job queue. Defaults to limit set at System
Generation.

WAIT
NOWAIT

Specifies use of wait estimate option.

ACTIVITY
NOACTIVITY

specifies whether Region activity estimate is to be
used in assigning a user to a region. NOACTIVITY
required for single region system.

OCCUPANCY
NOOCCUPANCY

Specifies whether core occupancy estimates are to be
used in queue selection.

SWAPLOAD
NOSWAPLOAD

Specifies whether swapload is to be used in queue
placement.

AVGSERVICE
NOAVGSERVICE

Specifies average queue service time to be used.

PRIORITY
NOPRIORITY

specifies whether priority scheduling is to be used.

PREEMPT/
NOPREEMPT

Specifies whether preemptive scheduling is to be used.

BACKGROUND=nn/
NOBACKGROUND

Specifies a percentage of CPU time guaranteed to
the background or no guaranteed time.

DECAYWAIT=nnnn

Specifies in lOOths the decay constant for the wait
estimate. Assumes WAIT specified.

DECAYACT=nnnn

specifies in lOOths the decay'constant for the
activity estimate. Assumes ACTIVITY specified.

SUBQUEUES(n)=mmm

Specifies the number of queues for region n.,

TSO System Parameter Syntax (Part 1 of 2)
System Implementation

77

PARAMETER
OWNER

TIOC

Figure 42.

78

KEYWORD

MEANING

CYCLES (n,m)=iii

Specifies the number of service cycles to be given to
the mth queue of the nth region.

MAXSWAP=(n,m)=iii

specifies the maximum number of 1024 byte blocks which
may be allowed to a user on queue m, in region n.
Assumes SWAPLOAD specified.

MAXOCCUPANCY (n,
m)=iii

Specifies the maximum amount of time in 100th of a
second a user on queue m in region n can reside in
core.

SERVICE (n,m)=iii

specifies the average service time in 100ths of a
second for a user on queue m in region n.

MINSLICE(n,m)=iiii

specifies the minimum time slice in 100th of a second
to be given to a user on queue m in region n.

BUFSIZE=nn

specifies size of terminal buffer.

BUFFERS=nn

Total number of buffers.

OWAITHI=nn

Specifies maximum number of allocated output terminal
buffers per user in.order to put a user program into
output wait.

INLOCKHI=nn

specifies the maximum number of allocated input
terminal buffers per user in order to lock a users
keyboard.

OWAITLO=nn

Specifies the number of allocated output buffers to
bring a user out of output wait state. In other words
if OWAITLO=4, when 4 or less buffers remain allocated,
the user is brought out of output wait.

INLOCKLO=nn

Specifies the number of currently allocated input
buffers to unlock the terminal keyboard for input.
other words, when the number of allocated input
buffers falls to or below the INLOCKLO value, the
user's keyboard is unlocked.

Default 44.

In

US ERCHG=nn

Specifies percentage of change -in logged on users
needed to redistribute buffers and recalculate the
OWAITHI- and INLOCKHI numbers during slack time.

RESVBUF=nn

Specifies the total number of terminal buffers that
must be free to avoid locking all terminals to prevent
input.

SLACK=nn

Specifies number of logged on users that constitute
slack time.

TSO System Parameter Syntax (Part 2 of 2)

Time Sharing Option Guide

(Release 20.1)

r--------------------------------~------------------------------------------------------,

ITS
TERMAX=10 REGNMAX=l REGSIZE(1)=(100K.8K)
ITS
LPA= ( IKJPTGT, IKJSCAN., IKJEF 02, IKJEFT25')
TS
LPA=(IKJPARS)
DRIVER
AVGSERVICE PREEMPT SUBQUEUES(1)=3
DRIVER
CYCLES (1,1)=0
DRIVER
CYCLES (1.2)=0
DRIVER
CYCLES (1., 3)=0
DRIVER
MAXOCCU PAN CY (1"1)=750 MINSLICE(1,1)=150
DRIVER
MAXOCCUPANCY (1,,2) =1500 MINSLICE (1,,2 )=750
DRIVER
MAXOCCUPANCY(1,3)=4500 MINSLICE(l,3)=4500
DRIVER
SERVICE (1, 1) =150
DRIVER
SERVICE (1,2)=1500
DRIVER
. SERVICE (1., 3) =6000
TIOC BUFSIZE=44
ITIOCBUFFERS=80
I TIOC OWAITHI=8
ITIOC OWAI TLO = 4
I TIOC INLOCKHI=4
ITIOC INLOCKLO=2
I TIOC SLACK=Ol
ITIOC RESVBUF=10
ITIOC USERCHG=99

I

ITS
TERMAX=60 REGNMAX=2 REGSIZE (1)= (lOOK. 8K) REGSIZE (2) =( lOOK, 8K)
TS
LPA= (IKJPTGT.,IKJSCAN., IKJEFT02 .• IKJEFT25)
TS
LPA=(IKJEBEM4, IKJEBELP" IKJEBELT" IKJEBECH, IKJEBELI)
TS
LPA=(IKJPARS)
DRIVER
WAIT
DRIVER
ACTIVITY
DRIVER
OCCUPANCY
DRIVER
AVGSERVICE
DRIVER
PREEMPT
DRIVER
DECAYWAIT=100
DRIVER
DECAYACT=100
DRIVER
SUBQUEUES(1)=3 SUBQUEUES(2)=3
DRIVER
CYCLES (1,1 )=0 CYCLES (1.2)=0 CYCLES ( 1" 3) =0
DRIVER
CYCLES(2,1)=0 CYCLES(2,2)=0 CYCLES(2,3)=0
DRIVER
MAXOCCUPANCY(1,1)=500 MINSLICE(1,1)=100
DRIVER
MAXOCCUPANCY(1,2)=1000 MINSLICE(1,2)=500
DRIVER
MAXOCCUPANCY(1,3)=3000 MINSLICE(1,3)=3000
DRIVER
MAXOCCUPANCY(2,1)=500 MINSLICE(2,l)=100
DRIVER
MAXOCCUPANCY(2,2)=1000 MINSLICE(2,2)=5000
DRIVER
MAXOCCUPANCY(2,3)=3000 MINSLICE(2,3)=3000
DRIVER
SERVICE (1.,1)=1000
DRIVER
SERVICE(1,2)=1000
DRIVER
SERVICE(1,3)=6000
DRIVER
SERVICE(2,1)~100
DRIVER
SERVICE(2,2)=1000
DRIVER
SERVICE(2,3)=6000
TIOCBUFSIZE=44
TIOC BUFFERS=300
TIOC OWAITHI=8
TIOC QWAITLO=4
ITIOC INLOCKHI=4
ITIOC INLOCKLO=2
ITIOC SLACK=12
ITIOC RESVBUF=60
L
_________________________________________________________________________________
_____
ITIOC
USERCHG=Ol
.
~

Figure 43.

sample TSO system Parameters

system Implementation

79

Tuning the Time Sharing Driver
Tuning a TSO Time Sharing Driver is the
process of specifying those values and
algorithms that give a specific
installation the best performance.
The time sharing algorithms discussed in
the System Summary section of this
publication are specified by an
installation through the Driver Parameters.
The syntax and meaning of these parameters
are discussed under "starting the System"."
This section discusses how to decide what
values to specify.
Depending on the complexity of an
installation, various measurements will be
of value in tuning the Driver. These are:
• Think time -- the amount of time the
terminal user takes to type in data,
specifically., the interval between .the
time a READ is issued for a terminal
and the time that READ is concluded.
• Swap time -- the sum of the amount of
time a given user's program is being
swapped in and the amount of time the
user's program is being swapped out.
• Execution time -- the amount of time a
given user is ready to rpn, i.e. " the
interval between when a user is
restored and is quiesced.
• Response time -- the interval between
a terminal user entering a command or
data and the time when the system
responds with output. If a user is
compiling a program, response time is
influenced by the particular program.
You determine such measurements through the
Driver Entry Codes. The TSEVENT macro
instruction is issued by system tasks to
request services of the Driver or to notify
the Driver of specific events·. The TSEVENT
macro instruction specifies an event name
that is translated into a Driver Entry
Code. Based on parameters specified to the
Driver and on the sequence of these codes,
the Driver initiates various actions.

Appendix C lists all the possible event
names, the codes they generate, their
meanings" and which task" issues these
codes. Associated with most TSEVENT macro
calls is a TJID, which identifies the user
to the Driver. The TJID is assigned when
the user "logs on.
In order to measure system performance,
it is necessary to examine the sequence of
these Driver Entry Codes during a Time
Sharing operation. The TSO TRACE facility
records all driver Entry Codes and places
them on a data set for later
interpretation .•
Using TSO Trace
The TSO Trace Data Set Processor is a
problem program that dumps the output data
set from TSO Trace and produces a formatted
listing. Figure 44 shows the job control
language required to run the TSO Trace Data
Set Processor. The example assumes that
the TSO Trace Data set has been written to
a tape volume with a volume serial number
of TTRACE. The listing shows the
parameters specified, and provides an
explanation of each entry record as well as
the contents of the record in hexadecimal
and EBCDIC. The contents of register 1 is
listed in the third column of the Trace
Data Set Processor.
TSO TRACE is a started task which
operates in its own region. All Driver
Entry Codes are recorded in buffers which
are then written to a data set. This data
set can be listed by the TSO Trace Data Set
Processor or can be analyzed by a user
wri tten program. The section of this
publication Writing Cataloged Procedures
for TSO, discusses how to define the TS
Trace data set and specify parameters
required by TSO Trace. Figure 45 shows the
format of the TSO Trace data set.
The PARM value on the EXEC statement
specifies what entries will be listed. All
"G" type records will be listed regardless
of the parameters. The individual keyword
parameters should be enclosed in
apostrophes and separated by commas. The
keyword parameters and their syntax are:

-r---------------------------------------------------------------------------------------,
I / /TTRDUMP JOB
" MSGLEVEL=l
I
I//STEP
EXEC PGM=IKJFATRP,PARM='CODES=STD'
I
SYSOUT=AI
I//SYSPRINT DD
L _______________________________________________________________________________________
JI
I//TRACEDD
DD
DSN=TSTRACE,VOL=SCR=TTRACE,UNIT=2400
Figure 44.

80

Sample Job system to Run TSO Trace Data Set Processor

Time Sharing Option Guide

(Release 20.1)

r-----T---------------------------------T-----------------------------------------------,

I Entry I
When Produced
I
Description of Contents
I
IType I
I
I
~-----+---------------------------------+-----------------------------------------------~
I 'A' IWhen the trace writer is started. I Word 1 X'FFFFFFFD'
I
I
I
I
I Word 2 # of 3-word entries per record
I
I
I Word 3 Time of Day in timer units
I
r-----+---------------------------------t-------~---------------------------------------~
I 'B' IWhen the trace writer is stopped. I Word 1 X 'FFFFFFFE ,
I
I
I
IWord 2 Date in packed decimal OOYYDDDS
I
I
I
I
I Word 3 Time of Day in timer units
~-----+---------------------------------t-----------------------------------------------~
I ·C· IWhen information was lost (volumelWord 1 X'FFFFFFFF'
I
Iswitching, low sampling rate,
IWord 2 NUmber of entries lost
I
I
letc.
IWord 3 Time of Day in timer units of the firstl
I
I
I
I
lost entry
I
~-----+---------------------------------+----------------------------------------------~
I'D' INormal entry (contains words 1-3 IWord 1 Bytes 1-2 TJID or 0
I
I
lof the DPA).
I
Byte 3
Reserved (x' 00')
I
I
I
I
Byte 4
Entry code
I
I
I
I Word 2 Contents of register 1 on entry to TSIP I
I
I
I
I Word 3 Time of Day in timer units
r-----+---------------------------------+-----------------------------------------------~
I IE' IFollowing a normal entry with
I Words 1-2 Command name
I
I
lentry code 0 (TMP entry).
IWOrd 3
Unpredictable
I
r-----+-----~---------------------------t-----------------------------------------------~
I 'F' IFollowing a normal entry with
IBytes 1-7
USERID
I
lentry code 25 (LOGON establishes IBytes 8-12 Unpredictable
I
I
I
IPSCB).
I
I
~-----+---------------------~-----------+-----------------------------------------------~
I • G', I Following a normal entry with
I Diagnostic data (There will be2n+1 3-word
I
I
lentry code 44 (FE serviceability) I groups of data available. The value of n is
I
I
I
'
Icontained in bits 5-7 of word 2 of the normal I
IL_____ I ____________ - -___________________ I ______________
entry.
- ________________________________ JI
~

Figure 45.

~

Format of the TS Trace Data set

CODES
specifies which class of entry codes
are to be included in the listing.
The subparameters, S,T and D represent
'§ystem'codes, '.!erminal I/O' codes,
and n,Qispatcher n codes, respectively.
The listing, therefore, will contain
only those entry codes belonging to
the class, or classes, specified.
Appendix C lists the Entry Code
classes. These subparameters may be
written in any order, but must not
contain delimiters nor embedded
blanks. If the CODES parameter is
omitted, all non-dispatcher entries
will be listed, i.e., CODES=ST is the
default. option.
TJID=XXX[- YYYl
specifies that only entries associated
with the TJID specified by the number
XXX are to,be listed. If YYY is also

given, all entries associated with
TJID's in the range xxx to YYY,
inclusive, are listed. If the value
given for xxx is zero, all entries
will be listed.
(This is also the
default if the 'TJID' parameter is not
specified.) Both numbers xxx and YYY
must be specified as decimal digits.
The maximum length of each number is
three digits.
CLOCK=XXXXXXX[- YYYYYYYl
indicates that no entry before time
XXXXXXX (relative to the starting time
of the first entry) is to be included
in the listing. If -YYYYYYY is
specified no entry after that time is
listed. Both numbers must be
specified as decimal digits and given
the time in seconds. The maximum
length of each number is seven digits.

System Implementation

81

Writing Installation Exits for the
Submit Command '
A user exit from the SUBMIT command allows
an installation to:
• Verify a jobname.
• Verify a userid.

12 - display a message at the
terminal., obtain a response, and
invoke the exit. (If the user has
specified NOPROMPT, this will
cause the SUBMIT processor to
abort. )
16 - abort.

• Send a message to the terminal and
optionally request a reply.
• Cancel a SUBMIT request.
The TSO SUBMIT command allows a terminal
u~er to initiate a background job.
A
description of the syntax and use of the
SUBMIT command is found in IBM System/360
Operating system; Time Sharing Option,
Command Language.
The SUBMIT command processor writes the
contents of a user specified data set
consisting of Job Control Language
statements, (JCL), and input data, onto a
logical extension of SYS1.JOBQE. The size
of this extension is limited at system
gener'a tion time by the SUBMITQ operand of
the TSO OPTION macro. Size can be further
limited by the SUBMIT parameter which the
Time Sharing Control Task reads·from
SYS1.PARMLIB when the operator issues a
START TS command.
Any authorized terminal user can submit
a background job, but no jobs will be
scheduled if the operator has not issued a
START BRDR command.
An installation can control foreground
initiated background jobs through an
installation written SUBMIT exit routine.
Through the routine an installation can:

• Delete, modify, or insert statements.
• Request that a message be displayed at
the terminal and optionally request a
reply.
The routine must be linkage edited as an
independent module, given the name
IKJEFF10, and cataloged in SYS1.LINKLIB.
The SUBMIT command processor invokes the
user written exit when the first JOB
statement is read. Return codes in
register 15 control subsequent calls. The
return codes are:

o-

8 - display a message at the terminal
and invoke the exit.

continue -- that is process the
current statement and read the
next.

Upon entry to the user written exit
routine, register 1 contains the address of
a list of six fullwords.
1st word - address of the current
statement.
If zero, entry is to get a statement
(return code from previous ,call was
4). To delete the current statement,
zero out the first word.
2nd word - address of a message to be
displayed on terminal.
If non-zero" return code from previous
call was 8 or 12. The exit may' free
the buffer •. If zero, no message, the
return code was 0, 4, or this is the
first call.
3rd word - address of response.
If the exit return code from the
previous call was 12, SUBMIT will free
the buffer. The format of both the
message and the response is LLtext
where LL is a two byte length field
containing one length of the text,
maximum length 82 bytes.
4th word - address of USERID.
The USERID is 8 characters left
justified padded with blanks.
5th word - address of control
switches.
Byte 0 specifies under what conditions
SUBMIT will call the exit.
Byte

Bit

Meaning

0

0
1
2
3

Call for JOB card
Exec
DD
Command
Null
Reserved
Reserved
Reserved

4

5
6
7

4 - reinvoke the exit
statement -- that
current statement
exit for the next
82

for another
is process the
and invoke the
statement.

Time sharing Option Guide

(Release 20.1)

Byte 1 if non-zero contains the card
column where the operand field begins.
For example, if the operand field

begins in column 16" byte 1 contains
hex 10.
Byte 2. _ Specifies what the current
statement is.
Byte
2

Bit

o
1
2
3
4

5
6
7

JOB statement
EXEC
DD
command
null
operand to be continued
statement to be continued
statement continuation

If bit 5 is on, bit 6 must be on, but
bit 6 can be on and bit 5 off.
Byte 3 is unused.
6th word - for exit's use.
The first time SUBMIT calls the exit,
the 6th word is initialized to zeros.
The exit can use the word for counters
or switches. The value is not changed
between calls.
'

Writing Installation. Exits for the
Output, Status and Cancel Commands
An installation can write a user exit for
the OUTPUT, CANCEL, and STATUS commands.
The exit routine is common to all three
command processors and is named IKJEFF53.
An TSO supplied module performs jobname
verification if a user exit is not
supplied. The parameters and the return
codes have the same format and meaning for
all three command' processors. The user
exit determines which command processor is
invoking it from a parameter. The
parameters are passed through a standard
linkage with register one containing the
address of a list seven of full words.
Word 1 -- contains the address of the
jobname.
Word 2 -- contains the address of the
length of the jobname.
Word 3 -- contains the address of the
userid.
Word 4 -- contains the address of the
length of the userid.
Word 5 -- contains the address of a
message to be issued to the
terminal user. The format
of one message is LLtext
where LL is a two byte field
containing the length of the
entire message, maximum

length 82 bytes. If 0, the
exit is being entered to
create a message.
Word 6 -- contains the address of a
response from the terminal
user. The format of the
response is LLtext where LL
is a two byte field
containing the length of the
entire message" maximum
length 82 bytes.
Word 7 -- contains the address of the
command code.
Command codes are:

o STATUS command.
4 = CANCEL coromand.
8 = OUTPUT command.
Return codes are passed in register 15 and
are defined as:

o=
4

Valid job name, continue
process ing •

= Display

message, get response, and
call exit again. If the terminal
use has specified NOPROMPT on his
LOGON command, the command willabort and a message will be, issued
to the terminal.

8 = Display message and call exit
again.
12 = Invalid jobname, cancel request.
16 = Abort
WRITING A LOGON PRE-PROMPT EXIT
A user-written exit, cataloged in
SYS1.LINKLIB can specify most of the values
to be determined from the LOGON command or
from prompting by the LOGON command
processor. These include:
• The userid.
• The password.
• An account character string -- that is

the value specified in the ACCT
operand.
• A procedure name -- that is the name of
a cataloged procedure usually specified
in the PROC operand.
• A region

size~

• A series of 80 byte card images of Job
Control Language (JCL) to be used
instead of the JOB and EXEC statements
system Implementation

83

normally constructed by the LOGON
processor.
• Portions of the Protected Step Control
Block.
• The contents of the User Profile Table.
• The contents of the Environment Control
Table.
In addition, the exit can:
• Read but not change the Event Control
Block which will be posted if the exit
terminates due to a CANCEL request.
• Read but not change the completion code
from the last step executed from the
terminal logging on.
The parameters passed are defined in the
procedure in Figure 46. The variables
declared as either BIT or CHAR, VARYING are
passed as string Dope Vectors,. For a
definition of String Dope Vectors see IBM
System/360 Operating system: PL/I-F
Programmer's Guide, GC28-6594. The exit
may be written in any language but since
parameters are passed as String Dope
Vectors, they can be manipulated directly
in PL/I. The exit must be Linkage Edited
and cataloged in SYS1.LINKLIB with a entry
point name which processes standard
operating system parameters and the module
must be named IKJEFLD.

I PL/I

I

LOGON passes 16 parameters to the user
exit. They are of three types:
1.

Character strings defined in PL/I as
CHAR VARYING.

2.

Bit Strings defined in PL/I as BIT
VARYING.

3.

Fullwords defined in PL/I as BINARY
FIXED (31).

The parameters passed can be given any
name in the user written exit procedure but
their meaning is determined by the order in
which they appear. The following
explanation of the parameters uses the
names defined in the PL/I procedure in
Figure 46.
CONTROL SWITCHES -- a bit string that
specifies what actions the exit has
taken. The various bit switches are:
UADS FAIL -- if this bit is equal
to one" on entry to the
pre-prompt exit, then there was
an unsuccessful ENQ on the UADS
entry for the specified userid.
84

Time Sharing Option Guide

(Release 20.1)

REGION FAIL-- if this bit is
equal to one on entry to the
pre-prompt exit, the region size
specified in the LOGON REGION
operand was too large to be
satisfied. The exit can specify
a different region size.
FAIL -- if this bit is equal to
one on entry to the pre-prompt
exit, the procedure was invoked
because of an unsuccessful
attempt to obtain an unspecified
system resource.
CANCEL'-- if this bit is equal to
one upon return from the
pre-prompt exit, the LOGON
processor will cancel the
attempted log on. No message
will be issued to the terminal
user, so the pre-prompt exit must
issue any needed message.
DONT PROMPT -- if this bit is
equal to one on return from the
procedure, the LOGON processor
will not prompt the terminal user
for any necessary LOGON operand
values but will use the values
specified by the pre-prompt exit.
These include:
•
•
•
•
•

Userid.
Password.
Accounting string.
Procedure name.
Region size.

EXIT UADS -- if this bit equals
one on return from the pre-prompt
exit, the LOGON processor will
not reference the UADS but will
take all character strings and
bit strings from the procedure,.
DON'T PROMPT must be set to one
if this bit is set to one.
EXIT JCL -- if this bit is equal
to one on return from the
pre-prompt exit, the pre-prompt
exit has supplied Job Control
Language (JCL) that is to be used
instead of the JOB and EXEC
statements constructed normally
by the LOGON processor.
EXIT PSCB -- if this bit is equal
to one on return from the
pre-prompt exit, the LOGON
processor will use the PSCB
accounting string returned by the
user but will not write i t to the
UADS at LOGOFF time.
EXIT ATTR1 -- if this bit is
equal to one on return from the
pre-prompt exit, the LOGON

processor will use the PSCBATRl
string provided by the exit and
will not write it into the UADS
a t LOGOFF time.

ACCOUNT -- used to return an
accounting string to the LOGON
processor.

EXIT ATTR2 -- if this bit is
equal to one on return from the
pre-prompt exit, the LOGON
processor will use the PSCBATR2
string returned by the pre-prompt
exit and will not write it into
the UADS at LOGOFF time.

PROCEDURE -- used to return the name
of a'cataloged procedure containing
JCL to define the resources needed by
the terminal job.

EXIT GROUP -- if this bit is
equal to one on return from the
pre-prompt exit, the LOGON
processor will use the PSCBGPNM
string returned by the exit
procedure, but-will not write it
to the UADS at LOGOFF time.
EXIT UPT -- if this bit is equal
to one on exit from the
pre-prompt exit, the LOGON
processor will use the UPT string
returned by the exit procedure,
but will not be written to the
UADS at LOGOFF time.
NO ENQ UADS -- if this bit equals
one and the DONT PROMPT and EXIT
UADS bits are both one, the LOGON
processor will not ENQ on the
UADS entry for the specified
user.
If both DONT PROMPT and EXIT UADS
are equal to one then

REGION SIZE -- used to return to the
LOGON processor a region size for the
terminal job.
JCL -- used ,to provide Job Control
statements that define terminal job
resources instead the JOB and EXEC
statement constructed by the LoGON
processor.
The next six parameters must have values
specified by the pre-prompt exit if EXIT
UADS is set to one by the pre-prompt exit.
PSCB -- used by the exit procedure to
set a value for the PSCB accounting
string.
FIRST ATTRIBUTE -- used to return a
value for the PSCBATRl string.
SECOND ATTRIBUTE -- used to return a
value for the PSCBATR2 string.
GENERIC GROUP -- used to return a
value for the PSCBGPNM.
UPT -- used to return ,a value for the
Upl'.

•
•
•
•
•

EXIT
EXIT
EXIT
EXIT
EXIT

PSCB
ATTRl
ATTR2
GROUP
UPT

ECT -- used to return a value for the
Environment Control Table (ECT).
The last two parameters cannot be altered
by the pre-prompt exit but may be read.

also must be equal to one.
TERMINAL INPUT LINE -- this
parameter contains the-first line
entered from the terminal.
The values for the next five parameters
must be specified if the DONT PROMPT bit is
set to one.
USERID
used to return a userid to
the LOGON processor.
PASSWORD -- used to return a password
to the LOGON processor.

ECB -- the Event Control Block (ECB)
for the exit procedure.
COMPLETION CODE -- this full word
contains the completion code for the
l'ast job step of the last job executed
from this terminal.
For the format'of the Protected'Step
Control Block (PSCB), the User Profile
Table (UPT), and the Environment Control
Table (ECT) see the publication IBM
System/360 Operating System:
System
Control Blocks.

System Implementation

85

r---------------------------------------------------------------------------------------,
USEREXIT:
PROCEDURE
C CONTROL_SWITCHES,
TERMINAL INPUT LINE,
USERID, PASSWORD,
ACCOUNT,
PROCEDURE,
REGION_SIZE,
JCL,
PSCB,
FIRST ATTRIBUTES,
SECOND ATTRIBUTE,
GENERIC_GROUP,
UPT,
ECT,
ECB,COMPLETION_CODE)
DECLARE
CONTROL_SWITCHES BIT C*) VARYING,
UADS FAIL
BIT Cl) DEFINED CONTROL_SWITCHES POSITION Cl),
REGION_FAIL'BIT Cl) DEFINED CONTROL_SWITCHES POSITION (2),
CANCEL
BIT Cl) DEFINED CONTROL SWI~CHES POSITION (3),
DONT PROMPT BIT Cl) DEFINED CONTROL:SWITCHES POSITION (4),
EXIT:UADS
BIT ,Cl) DEFINED CONTROL_SWITCHES POSITION (5),
EXIT JCL
'BIT Cl) DEFINED CONTROL SWITCHES POSITION (6),
EXIT:PSCB
BIT Cl) DEFINED CONTROL:SWITCHES POSITION (7),
EXIT_ATTRl BIT Cl) DEFINED CONTROL_SWITCHES POSITION (8),
EXIT ATTR2 BIT (1) DEFINED CONTROL SWITCHES POSITION (9),
EXIT-GROUP BIT Cl) DEFINED CONTROL:SWITCHES POSITION Cl0),
EXIT-UPT
BIT Cl) DEFINED CONTROL SWITCHES POSITION (11),
NO ENQ USERID BIT Cl) DEFINED CONTROL SWITCHES POSITION (12);
DECLARE TERMINAL INPUT LINE CHAR C*) VARYING;
DECLARE USERID CHAR C*)
VARYING;
DECLARE PASSWORD
CHAR (*)
VARYING;
DECLARE ACCOUNT
CHAR C*)
VARYING;,
DECLARE PROCEDURE
CHAR C*)
VARYING;
DECLARE REGION SIZE
BINARY FIXED (31);
DECLARE JCL
CHAR C*)
VARYING;
DECLARE PSCB
BIT (*)
VARYING;
DECLARE FIRST ATTRIBUTE
BIT (*)
VARYING;
DECLARE SECOND ATTRIBUTE
BIT (*)
VARYING;
DECLARE GENERIC GROUP
CHAR C*)
VARYING;
DECLARE UPT
BIT C*)
VARYING;
DECLARE ECT
BIT C*)
VARYING;
DECLARE CP ABEND
BIT (1) DEFINED ECT POSITION Cl);
DECLARE CP-RETURN-CODE
BIT (24) DEFINED ECT POSITION (8);
DECLARE IO-WORD AREA ADDR BIT (32) DEFINED ECT
POSITION (33);
DECLARE NOSEC LEVEL MSG
BIT (1) DEFINED ECT POSITION (65);
DECLARE SEC_LEVEL_MSG_ADDR BIT (24) DEFINED ECT POSITION (73);
DECLARE COMMAND_NAME
CHAR (8) DEFINED ECT POSITION (97);
DECLARE SUBCOMMAND NAME
CHAR (8) DEFINED ECT POSITION (161);
DECLARE NO MAIL SWITCH
BIT (1) DEFINED ECT POSITION (228);
DECLARE NO:NOTICE_SWITCH
BIT (1) DEFINED ECT POSITION (229);
DECLARE ECB
BINARY FIXED (31);
DECLARE COMPLETION CODE
BINARY FIXED (31);

_______________ ______=________________________________________________________________
~

Figure 46.

86

Portion of Sample PL/I Logon Pre-Prompt Exit

Time Sharing Option Guide

(Release 20.1)

J

Storage Estimates

The estimates included in this chapter are
intended for planning purposes only. None
of these estimates have been verified, and
they are subject to change. Verified
estimates will appear in the publication
IBM System/360 Operating system: storage
Estimates, GC28-6551, when they are
available.
This chapter contains three sections:
main storage requirements, sample
configurations, and auxiliary storage
considerations. All figures in this
chapter are decimal. and "K" represents a
factor of 1024.

Main Storage Requirements
The main storage requirement for TSO is
divided into four major parts:
• An addition to the MVT basic fixed
requirement.
• The TCAM Message Control Program
requirement.
• The Time Sharing Control region
requirement.
• The foreground regions in which users'
programs are executed.
Only the first of these requirements has
any effect on the batch environment if time
sharing is not active. storage for the
TCAM, Time Sharing Control, and froeground
regions is obtained from the dynamic area
when the operator starts time-sharing
operations. This storage is returned to
the dynamic area when time sharing is
stopped, and is again available for batch
processing.
'
MVT BASIC FIXED REQUIREMENT
The main storage basic fixed requirement
for an MVT system is for:
•
•
•
•

The
The
The
The

nucleus.
Master Scheduler Region.
Link Pack Area (LPA).
system Queue Area 
as operand of TSOMCP macro instruction
65
use in starting MCP 66
OS PL/I Checkout Compiler
as Program Product 19,90
description of 28
prompter in 28
supported by TSO 19
OUtput
from background jobs 26
OUTPUT command 26
OUTPUT command installation exit
command codes 83
parameter format 83
return codes 83
Overview of system 54
OWAITHI
operand of buffer control parameters 77
OWAITLO
operand of buffer control parameters 77
Parallel swapping
definition 13
glossary 111
specifying 71
Passwords
definition 11

Passwords (continued)
for data sets 17
glossary 111
processing 48
with LOGON command 20
.PL/I
choice of processors 35
for problem-solving 41
for programming 35
PL/I Checker (see OS PL/I Checkout
Compiler)
PL/I (F) 37
PL/I Optimizing Compiler
options 35
program entry 32
program execution 33
preemptive scheduling
definition 59
Preempt
operand of driver parameters 76
Priority
operand of driver parameters 76
Problem-solving
Code and Go FORTRAN 42
comparison of languages 40
ITF: BASIC 40
ITF:
PL/I 41
PROC statement
in command procedures 27
Procedure name
for LCGON 11
PROFILE command 27
Program development
assembler language 36
COBOL 28
commands for 25
FORTRAN 34
introduction 18
PL/I 35
testing 25
Program execution
commands for 25
Program listing
Assembler 36
COBOL 30
FORTRAN 34
PL/I 35
Program Products
listed 89
Program protection 16
Prompter routine
definition 19
function 25
Prompting
definition 9
for input lines 23
for operands 20
glossary 111
user replies to 11
PROTECT command 23
Protection
of data sets 17
of programs 17
publications, recommended 2
PURGE SVC 48
PUTGET service routine 48
PUTLINE service routine "51
glossary 111

Question mark
reply to prompt
Queue service time
definition 58
Quiescing
control of 47
definition 13
glossary 112
scheduling 47

11

Read protection
for data sets 17
Reader/Interpreter
called by LOGON 48
Record Overflow Feature
required for swapping 13
Recovery management 45
Region Control Task 47
glossary 112
Region control task
glossary 112
Region operand of EXEC statement
used to specify MCP region size 70
Region size
operand of TSO parameters 76
regsize operand of TSO parameters 76
spe-cifying 74
REGISZE
operand of TSC parameters 76
Remote job entry 25
glossary 112
Remote terminals
as COBOL files 30
definition 9
glossary 112
RENAME command 23
Required configuration 12
RESRVBUF
operand of buffer control parameters 77
Restrictions
background SVC use 14
BTAM 14
Checkpoint/restart 14
GAM 14
Hierarchy support 14
multidrop line not recommended 12
Muitistepjobs 14
Rollout/rollin 14
TESTRAN 14
Rollout/Rollin
restriction in foreground 14
RUN command 25
Sample cataloged procedure
for logon 74
for starting an MCP 70
for starting background reader 72
for starting TSC 72
for starting TSO trace writer 73
Sample MCP cataloged procedures 71
Sample TSC cataloged procedure.for TSC
Sample TSO system parameters 78
SCAN service routine 50
SEND command 27
Sequence field
in COBOL statements 29
Index

72

123

serial swapping
definition 13
specifying 71
service
operand of driver parameters 77
service routines
Dynamic Allocation Interface 51
GETLINE 51
PARSE 51
PUTGET 51
PUTLINE 51
SCAN 50
STACK 51
Shared data sets 22
Shared Language Component
see nITF: n
Short precision
in ITF: BASIC 40
Simple dispatching 60
Simulated attention function
definition 21
glossary 112
handling 50
size of SUBMIT job queue (see also SUBMIT
operand of driver parameters) 82
Slack
operand of buffer control parameters 76
SLC

see nITF: n

SMF

function 15
glossary 112
operand of TSC parameters 77
Specifying a Time Sharing Driver 77
Specifying contents of TSO Link Pack
Area
77
'
Specify Tenninal Attention Exit 

VI

c:

c:
(1)

Poughkeepsie, N.Y. 12602

Attention: Programming Systems Publications
Department 058

----------------------------------------------Fold

~

Fold
G>

(')

~
I

00-0
(Xl

I

W

International Business Machines Corporation
Data Processing Division
112 East Post Road, White Plains, N.Y.106Ot
[USA OnlyJ
IBM World Trade Corporation
82i United Nations Plaza, New York, New York 10017
[lnternationalJ

Technical Newsletter

File No.
Base Publ. No.
This Newsletter No.
Date:
Previous Newsletter Nos.

S360- 20

GC28- 6698- 3
GN28-2497
July 1, 1971
None

IBM System/360 Operating System:
Time Sharing Option Guide
© IBM Corp. 1969,1970,1971

This Technical Newsletter, applies to release 20.1 of IBM
System/360 Operating System, provides replacement pages for the
subject publication. These replacement pages remain in effect for
subsequent releases unless specifically altered. Pages to be
inserted and/or removed are:
7,8
11-14
23,24
33-36
39-42
53,54
61-72
77,78
81,82
87-92,92.1
95,96
A change to the text or a change to an illustration is indicated
by a vertical line to the left of the change.

Summary of Amendments

Provides new information about the PLII Checkout Compiler, MCP
Generation macro instructions, EDIT facilities, Background reader,
UADS construction, the Broadcast data set.
Note: Please file this cover letter at the back of the manual to
provide a record of changes.

IBM Corporation, Programming Systems Publications, P.O. Box 390, Poughkeepsie, N.Y. 12602
PRINTED IN U.S.A.

Summary of Major Changes

Release 20.1

GC28-6698-2

r---------------------T--------------------------------------------------,
I
Item
I
Description
I
I

~--------------------+--------------------------------------------------1

Isystem Implementation A section has been added describing the techniques
I
used in implementing a TSO system. This section
I
consists of discussions of:

I

I
I
I
I
I
I
I
I

Generating a Message Control Program
Writing Cataloged Procedure's Used With TSO
specifying TSO System Parameters
Tuning the Time Sharing Driver
Writing Installation Exits for:
The SUBMIT Command
The OUTPUT, STATUS, and CANCEL Commands
The LOGON Command

~--------------------+------------------.--------------------------------1

Istorage Estimates
I
I
I
I

IMast of the information in the Storage Estimates
Isection, including the sample TSO configuration,
Ihas been deleted and moved to the publication IBM
Isystem/360 Operating system Storage Estimates
I GC28-6551.

I
I
I
I
I

r---------------------+-----------~--------------------------------------1

IDriver Entry Codes
I
I
I

IAn appendix has been added containing the format I
I and meaning of the TSEVENT macro instructions used I
Ito notify the Time Sharing Driver of system
I
I events.
I

I Requiring
I Installation Action

Iwhich when received at a terminal requires the
I installation to take certain actions.

r---------------------t--------------------------------------------------1
ITerminal Messages
IAn appendix has been added containing messages
I

I
I

~--------------------+--------------------------------------------------1

IMessage Control
IAn appendix has been added containing the text of I
IProgram Assembly
I error messages generated by the macro instructions I
IError
Messages
lused
to generate the Message Control Program.
L
_____________________
__________________________________________________
JI
~

Release 20.1

GC28-6698-3

r---------------------T--------------------------------------------------T--------------,
Item
I
Description
I Areas Affectedl
r---------------------+--------------------------------------------------f--------------1
ITMP Step Library
IA discussion of the advantages of concatenating
120,74
I
I

I
I

I Command Library to SYS1.LINKLIB, the Linkage
I Library.

I
I

I
I

~--------------------+--------------------------------------------------f--------------~

lOS PL/I Checkout
I Compiler

IA discussion of the uses and facilities of the
ICheckout Compiler.

135-36
I

I
I

~~--------.-----------+--------------------------------------------------f--------------~

12260,2265
IThe macro instructions for generating the MCP have I 63-69
I
I_____________________ I __________________________________________________
additional operands for 2260 and 2265 support.
I ______________ JI
L
~

~

Summary of Major Changes -- Release 20.1

7

Page of GC28-6698-3, Revised July 1. 1971, By TNL:

GN28-2497

Release 20.1 CGC28-6698-3 MODIFIED BY TNL GN28-2497

r---------------------T-------------------------------------------------r--------------,
I
Item
I
Description
IAreas Affectedl
r------------------~-+--------------------------------------------------+--------------~

ITeletype ASR
I

IUse of paper tape reader/punches attached to
ITeletype ASR terminals are not supported.

112

I

i

I

r---------------------+--------------------------------------------------+--------------~

IRestrictions to
I Foreground Programs
I

ITape and multivolume data sets are not supported
Iby most Command Processors and cannot be
1dynamically allocated.

114
1
I

I
I
I

I instruction

I

I

I

I

I
I
1The valid screen sizes are 12x80, 12x40, 6x40, andl
115x64.
I

I
I
I

.---------------------+--------------------------------------------------t--------------i
ITSOMH macro
IThe NOLOG operand has been removed
162
I

.---------------------+--------------------------------------------------t--------------i
12260,65
IThe SCRSIZE operand has changed to SCREEN.
164,66
I
I

I

.---------------------+--------------------------------------------------t--------------i
I DIAL operand
1DIAL=YES is default for TERM=333S.
165
I
r---------------------+--------------------------------------------------+--------------~

IFEATURE operand

ITWO defaults have changed.

165

I

ISUBMIT command

Icommand is placed on SYS1.SYSJOBQE.

I

1

I

Ispecified for each non-switched line with a 1050
I terminal attached to it.

I

t
I

.---------------------+--------------------------------------------------t--------------i
I Background Reader forlThe output of the backround reader for the SUBMIT 172,82
I

.---------------------+--------------------------------------------------t--------------i
IADDR operand
10nly one station identification character can be 166
I
I

I

r---------------------+--------------------------------------------------t--------------~

lOS PL/I Checkout
1compiler

IThe titles of publications describing the checkout I 92-92.1
1Compiler is added.
1

I
I

r---------------------+--------------------------------------------------t--------------~

ISwap data sets

IIBM 2311 is not supported as a swap device.

189

I

I

lusers and should not be password protected.

1

I

I pointer

Iline referenced.

I

I

.---------------------+--------------------------------------------------t--------------i
IBroadcast data set
1The Broadcast data set contains a list of valid
171
I
.---------------------+--------------------------------------------------t--------------i
IEDIT default line
IThe default line pointer is positioned at the lastl23
I

.---------------------+--------------------------------------------------t--------------i
1FORTRAN
1The EDIT FORT operand has no default.
134
I
r---------------------+--------------------------------------------------t--------------~

IRelative Line Number IThe order of Relative line numbers is determined
I
Iby the MCP start cataloged procedure.

166
I

I
I

r---------------------+------------------------~-------------------------t--------------~

IDefining a New UADS
I

IThe new UADS should be defined with a file name ofl72
ISYSUADS and a data set name other than SYS1.UADS. I

I
I

r---------------------+--------------------------------------------------t--------------~

Istorage Estimates

IThe MCP storage requirements are increased.

188

I

.---------------------+--------------------------------------------------t--------------i
IDrive Entry Codes
ICLASS refers to the CODES parameter of the TSO
196
I
CLASS
ITrace
Cata Set Processor.
I_____________________
L
__________________________________________________
~

8

Time Sharing Option Guide

(Release 20.1)

I______________ JI

~

U sing a Terminal
A terminal session is designed to be an
uncomplicated process for a terminal user:
he identifies himself to the system and
then issues commands to request work from
the system. As the session progresses, the
user has a variety of aids available at the
terminal which he can use if he encounters
any difficulties.
Commands specifically tailored to an
installation's needs can be written and
added to the command language or used to
replace IBM-supplied commands.
starting and stopping a Terminal Session
When the user has some work to perform with
the system, he dials the system number if
he has a terminal on a switched line, or he
turns the power on if he has a terminal on
a non-switched line. A switched line is
one in which the connection between the
computer and a terminal is established by
dialing the system's number from the
terminal. A non-switched line is one with
a connection between the computer and the
terminal. With an IBM 2741 terminal or an
IBM 1050 terminal, the system responds by
unlocking the keyboard. In any case, the
user identifies himself by entering nLOGONn
and one or more of the following fields:
• A user identification, for example, the
user's name or initials, which the
system will use to identify his
programs and data sets.
o

A password assigned by his
installation, usually known only to the
user and the system manager.

o

An account number, which defines the
account in which his system usage
totals are to be accumulated.

• A LOGON procedure name, which
identifies a cataloged procedure that
specifies what system resources he will
be using.
The user may omit the last three fields if
the system manager has defined only one
account number and LOGON procedure for him
and no password is used.
The LOGON processor verifies that the
user is an authorized TSO user, then checks
the password, if it is required, and
account number in a record it keeps of user
attributes, called the User Attribute Data
Set (UADS). From the attributes, the LOGON
command operands, and a LOGON cataloged
procedure, the system builds a user
profile, which is used to control the

processing of his job. The system assigns
the user's job to a time-sharing
(foreground) region of main storage and
allocates other resources, such as
auxiliary storage space and user data sets
according to the LOGON procedure.
LOGON marks the start of a terminal
session.
When the user completes his work,
he enters nLOGOFF" to end the session. The
system then updates his job's system use
totals, releases resources allocated to it,
and releases the terminal from TSO. A
session is also terminated any time the
terminal user enters LOGON to start a new
session.
In this case, the old session is
terminated and a new one is begun; the
terminal is not released in the process.

Working at the Terminal
The user enters commands to define and
execute his work at the terminal.
He
enters a command by typing a command name,
such as EDIT and possibly some additional
operands. The system finds the appropriate
command processor--a load module in a
command library--and brings it into the
foreground region assigned to the user for
execution. For example, in response to
entering the EDIT com~and, the system
brings in the EDIT command processor, the
data handling routine used to create and
update data sets.
If a user does not enter all the
operands associated with a particular
command name, default values are assumed
where possible. If necessary operands are
missing, the system prompts the user for
them with a message such as nENTER DATA SET
NAME.n The user can reply with the missing
value, or enter a question mark for a
further explanation of what the system
needs. If the user chooses, he can specify
that prompting messages be suppressed.
A terminal user can also receive
assistance through the HELP facility.
He
can request information regarding the
syntax, operands, or function of any
command, subcommand, or operand.
If he
enters HELP followed by a command name, he
receives an explanation of the command and
the operands required with it. HELP
followed by a subcomreand name furnishes an
explanation of the subcommand if you are
working with the command at that time.
Entering HELP by itself returns a
description of the comroand language, a list
of the commands, and an explanation of how
to use HELP to obtain further information.

Introduction

11

Page of GC28-6698-3, Revised July 1, 1971, By TNL:

During a typical session, the user
enters a series of commands to define and
perform his work.
If the sequence is one
that is used often, he can store the
sequence in a data set and then execute the
sequence whenever he needs i t by entering
the EXEC command.
The commands provided with the system
handle data and program entry, program
invocation in either the foreground or the
background, program testing, data
management, and session and system control.
IBM Program Products are available to
support problem solving, data manipulation,
and text formatting, to provide
terminal-oriented language processors, and
to make these processors more convenient to
use from the terminal.

System Configurations
TSO is an extension of the MVT
configuration of the control program on
System/360 Models 50 through 195, or
System/370 Models 155 and 165. TSO also
operates with the Model 65 Multiprocessing
(M65MP) configuration.
The minimum machine
configuration for Systern/360 models must
include 384K of main storage, the required
I/O devices for MVT, plus at least one each
of the following:
o

A terminal (IBM 1050, 2741, 2260 Local
or Remote, 2265, or Teletype1 Model 33
or 35 KSR and ASR).

• A transmission control unit (IBM 2701,
2702, or 2703), unless all terminals
are locally attached 2260 Display
stations.
o

sufficient direct access storage space
(IBM 2301, 2311, 2303, 2305, 2314, or
3330) for command libraries and system
data sets.

• Sufficient direct access storage space
to swap data sets.
In a Systern/360 with 384K of main storage,
TSO is, in effect, a "dedicated" time
sharing system. In other words, with 384K
the system can run as a time sharing system
or as a batch job processing system, .but
not both at the same time.
To run both
time sharing and batch jobs concurrently or
to execute on M65MP or system/370 models,
at least 512K of main storage is required.
At least 128K of main storage is required
for system generation.
1T~ademark

of Teletype Corporation, Skokie,

Illinois .•
12

Time Sharing Option Guide

(Release 20 .• 1)

GN28-2497

Terminals
Some remote terminals suitable for
interactive applications have keyboards for
entering input data and either
typewriter-like printers or display
screens. A remote terminal incorporates or
is attached to a control unit. The control
unit is in turn connected to the system by
either of two ways:
• Through a device such as a data set to
a dialed (switched) line ~o the system.
• Through either a direct or a leased
line to the system.
.At the computer site the communication
line connects to a Transmission Control
Unit, which in turn is attached to one of
the computer system's rrultiplexor channels.
The IBM 2260 Display Station can be an
exception to this general configuration.
Its control unit, the IBM 2848 Display
Control, can b~ attached directly to a
multiplexor or selector channel. This mode
of operation is called local attachment.
TSO uses the Telecommunications Access
Method (TCAM) for terminal access. TSO
provides terminal handling programs for the
following terminals:
• IBM 2741 Communication Terminal.
• IBM 1050 Printer-Keyboard.
• Teletype 1 Model 33 and 35 KSR and ASR.
(Paper tape is not supported for
Teletype 1 • )
o IBM 2260 and 2265 Display Stations.
The IBM 2741 Receive Interruption
Feature and the Transmit Interruption
Feature are recommended for use with the
2741. These features are described in the
publication IBM 2741 Communications
Terminal.
The Transmit Interrupt, Receive
Interrupt, and Text-Tirreout Suppression
features are recommended for use with the
IBM 1050. 1050 multidrop is not sUpported.
These features are described in the
publication IBM 1050 System summary.
Note
that some of these features 9re not
available through the IBM 2701 Data Adapter
Unit. 2
Transmission Control Unit
TSO requires at least one of the following
transmission control units to handle
terminal communications:
2Terminals which are equivalent to those
explicitly supported may also function
satisfactorily. The customer is
responsible for establishing equivalency.
IBM assumes no responsibility for the
impact that any changes to the
IBM-supplied products or programs may have
on such terminals.

• IBM 2701 Data Adapter Unit .•
• IBM 2702 Transmission Control.
• IBM 2703 Transmission Control.
The Terminal Interruption Features are
recommended for use with the 2702 and 2703
transmission control units and must be
present if the terminals are to use the
features.
These units are described in the
following publications:
• IBM 2701 Data Adapter Unit, Component
Description.
• IBM system/360 Component Description,
IBM 2702 Transmission Control.
• IBM 2703 Transmission Control,
Component Description.
swap Data Set Devices
The process of copying images back and
forth between main and auxiliary storage is
called swapping. Writing an image to
auxiliary storage is a swap out; reading
one into main storage is a swap in. The
pre-formatted data sets into which jobs are
written are called swap data sets. A swap
data set is divided into swap allocation
units, each of which consists of a
device-dependent number of 2048-byte
records. An integral number of swap
allocation units, not necessarily
contiguous, are assigned to each job to
contain the swapped out image of the job.
If there is more than one foreground
region, they share the availabl€ swap data
sets, but the cycle of swapping for each
region is essentially independent of other
regions. However, the system avoids
queuing on swap data sets if possible.
TSO requires sufficient storage capacity
on one or more of the following for swap
data sets:
• IBM 2301 Drum Storagee
IBM 2303 Drum Storage.
• IBM 2305 Fixed Head storage,
Modell or 2.
• IBM 2314 Direct Access Storage
Facility .•
• IBM 3330 Disk Storage Facility.

o

See the storage Estimates section of
this publication for information on swap
data set sizes.
The record overflow feature is required
for the devices used to store the swap data
sets.
One or more data sets on any of the
above devices can be used for swap data
sets.
The direct access storage space required
for the swapped data may be divided among
the devices listed above in either of two
ways. The user may specify that swapped

data be distributed serially among a
hierarchy of data sets, or he may specify
parallel distribution of data onto two
devices.
With serial distribution, the
first data set in the hierarchy is filled
with swapped data, and then the next data
set in the hierarchy is used.
For example,
a drum, because of its higher access speed,
could be assigned as the first unit in the
hierarchy, with a 2314 assigned to receive
any overflow of swapped data.
With the parallel distribution scheme, two
devices are used concurrently to receive
swap data sets.
The exact order in which
data sets are written on either of the
devices is determined by the system, based
on the I/O activity taking place in the
channel at the time of a swap out.
For
example, if the two data sets are on
devices on separate channels, swap
performance improves substantially.
Before a terminal job can be swapped out
of main storage, activity associated with
the job must be brought to an orderly halt.
The halt must be performed in such a way
that the job is not aware of it, and
information must be saved to restart the
job when its next time slice is scheduled.
The orderly suspension of a job's activity
before a swap out is called guiescing the
job. Quiescing includes the removal of the
majority of the control blocks associated
with the job from the system queues so they
can be written to the swap data set along
with the contents of the main storage
region assigned to the job.

The Relationship of TSO to the
Operating System
For the data processing center, TSO is
compatible with operating system standard
formats and services, while providing the
flexibility needed for various time sharing
and terminal-based applications.
TSO is not necessarily intended to be
used as a dedicated tirre-sharing system,
that is, a system on which only
time-sharing operations take place. TSO
augments the facilities already available
with the operating system:
batch
processing, teleprocessing, and other data
processing activities can take place
concurrently on the same system.
Once an installation has generated a
system that includes TSO, time sharing
operations can be started and stopped at
any time by the system console operator.
The operator can specify how many regions
Introduction

13

Page of GC28-6698-3, Revised July 1, 1971, By TNL:

of main storage are to be assigned to time
sharing users. Each region can serve many
users, whose programs are swapped back and
forth between main and auxiliary storage.
Time sharing, or foreground operations, can
take place concurrently with batch or
background operations.
(Background jobs
are not swapped.)
If the user choos es, he
can dedicate his system to time sharing and
run only foreground jobs. If there are
periods when TSO is not needed in the
system, time sharing operations can be
stopped, and the system will then process
background jobs in the usual way with MVT
and TCAM.
Terminal communications are handled by
the Telecommunications Access Method (TCAM)
through an interface that allows the use of
standard sequential access method I/O
statements and macro instructions.
All of the MVT facil i ties are a va ilable
to a background job. Foreground jobs ca.n
use most of the operating system access
methods for data set access (e.g., BS~l,
QSAM, BDAM etc.). All devices available to
these access methods are usable by
foreground jobs. A detailed list of
restrictions is in the "Restrictions and
Limitations" section of this manual.
Execution of Background Jobs from the
Terminal

GN28-2497

programs. Most problem programs can be
executed in either the background or the
foreground without revision or
recompilation.
Restrictions and Limitations
Certain facilities are unavailable to
foreground jobs, although they remain
available to background jobs. These
include:
• The BTAM and QTAM telecommunications
access methods.
• The Graphics Access Method (GAM).
• The EXCP equivalents of the BTAM, QTAM,
and GAM access methods.
• Main storage requests for hierarchy 1
(all foreground requests for main
storage are allocated to hierarchy 0).
• Use of Job Control Language in the
foreground for other than single-step
jobs (the TSO command language is used
to provide the equivalent of multi-step
jobs).
• Checkpoint/Restart Facility (foreground
requests for checkpcint are ignored).
• Rollout/Rollin Opticn.

In addition to the foreground execution of
programs, TSO allows jobs to be submitted
for execution in the background, or batch,
portion of the system. If his installation
authorizes it, a user can submit a
background job at his terminal, be notified
of the job's status, and then receive
results of the job at the terminal. If he
chooses, he can specify that the output of
his job be produced at the computing
center, rather than at the terminal.
Foreground-Background Compatibility
Because time sharing is carried out within
the framework of MVT job and task
management, the foreground and background
environments are compatible. TSO uses the
same data formats, programming conventions,
and access methods as the rest of the
operating system. The programming
languages and service programs available
with TSO are compatible with their
background counterparts.
The TSO command language is also
generally compatible with the
Conversational Remote Job Entry (CRJE)
command language. Programs can be
developed in the foreground and stored in
background libraries. These programs are
compatible with other operating system

14

Time Sharing Option Guide

(Release 20.1)

• TESTRAN Facility.
• Multi volume or tape data sets are not
supported by most Command Processors
and cannot be allocated dynamically.
SVC numbers 92 through 102 (decimal) are
added to the system for TSO. The following
SVCs can be issued by problem programs in
the foreground region:
• SVC 93--TGET/TPUT (execute terminal
I/O).
• SVC 94--STCC (specify terminal control
characteristics).
• SVC 95--TSEVENT (notify the supervisor
of an event).
• SVC 96--STAX (specify a terminal
attention exit).
• SVC 97--Breakpoint (used by TEST
command) •
• SVC 98--PROTECT (protect a data set
with a password).
• SVC 99--Dynamic Allocaticn (of a data
set) •

Page of GC28-6698-3, Revised July 1, 1971, By 'I'NL:

One input line from the terminal
normally becomes one record in the data
set.
Because of this equivalency between
records and lines at the terminal, data
sets created by EDIT are called line data
sets.
On request, EDIT appends a line
number to each record of the data set as it
is entered.
Entry Modes for EDIT
Depending on the type of work the user is
doing with his data set, he uses one of two
entry modes provided by EDIT (some other
modes specifically for particular
programming languages are discussed later).
The input mode allows rapid entry of
successive lines of input for the data set.
The edit mode allows subcommands to be
entered to modify, insert, or delete lines.
Input Mode
In input mode, the user enters successive
lines of input. The lines are normally
appended at the end of the data set,
although the user can request they be
inserted at some other point. The only
subcommand recognized in the input mode is
the null line (hitting the return key with
no preceding characters), which requests
transfer to the edit mode.
Services available in the input mode
include translation of lowercase letters to
uppercase, t~anslation of tab characters to
a series of blanks, and interpretation of
the character-delete and line-delete
characters. If line numbers are being
assigned to each line, the user may request
each new number be typed out by the system
at the beginning of each input line. If
line numbers are not being assigned, the
user can request prompting for each new
line by an underscore.
If no prompting is
requested, lines are entered one after
another, with no intervening response from
the system. Programming language syntax
checkers can be requested to process input
lines as they are entered.
Edit Mode
In edit mode, the user enters subcommands
to point to particular records of the data
set, to modify or renumber records, to add
and delete records, to control editing of
input, or to compile and execute a program.
Whenever the terminal is in edit mode,
the user is considered to be positioned at
a particular record, or line, of the data
set. The EDIT command processor maintains
a current line pointer to keep track of the
user's position. In general, the current
line pointer, which can be referred to in
subcommands by an asterisk (*>, is
positioned at the last line referred to,

GN28-2497

entered, changed, or printed. Using the
subcoIT.rrands provided, the us er can move the
current line pointer to any record in the
data set.
For line-numbered data sets, specifying
a line number as an operand of a subcommand
moves the pointer to that record before the
action requested by the subcommand is
carried out. This method of operation is
called line number editing.
Another method of repositioning the
current line pointer is called context
editihg. A set of subcc~mands is provided
to reposition the current line pointer
without reference to line numbers. The
user can move the pointer up or down a
specified number of lines, or request the
system to find a line with a particular
series of characters in it, and move the
pointer to it.
Modifying Data Sets
The most common use of the EeIT command for
existing data sets is the addition,
deletion, or modification of records.
The
INSERT and DELETE subccmrr:ands handle single
or multiple record insertions and
deletions.
The CHANGE subcommand allows
the user to replace one character string
with another, not necessarily of the same
length.

Data Set Management Commands
To allow the user to rranage his data stored
on auxiliary storage devices, a set of data
set utility commands is included in the TSO
command language. All user data is kept in
standard operating systero data sets, and as
a default, data sets used by foreground
programs are entered in the system catalog,
reducing the amount of information the user
must supply about the data set from the
terminal when he refers to it.
The LISTCAT and LISTDS commands retrieve
information from the system catalog for the
user. He can find out what data sets are
currently allocated to him, and what the
attributes of the data sets are. The
RENAME command can assign a new data set
name to an existing data set, or add an
alias name to a partitioned data set
member. The DELETE cOITITand removes a data
set from the catalog, and frees the
auxiliary storage space i t occupies.
The PROTECT comrrand is the facility to
assign password protection to data sets.
Protection can be assigned for read access
or for write and delete access. Multiple
passwords can be assigned to a single data
set.

I

Command Language Facilities

23

The ALLOCATE and FREE commands invoke
the dynamic data set allocation routines
from the terminal. A user who wants to run
a program that requires one or more data
sets not currently allocated to his
foreground job enters ALLOCATE commands to
have the data sets assigned,. The FREE
command is used to release the data sets
assigned by ALLOCATE. The ALLOCATE command
can also be used to find data sets not in
the system catalog, and to control the size
of new data sets and the volumes to which
they are assignedo

separate line in the data set, starting
with a period in the first pOSition,
followed by a control word (or a
two-character abbreviation). The EDIT
processor does not interpret the· controls;
they are retained in the data set for
interpretation later by the FORMAT
processor.
The controls allow the user to:
• Print a heading on each page.
• Center lines of text between margins.
• Control the amount of space for all
four margins on the page.

TSO Data Utilities

• Control line spacing.

The TSO Data Utilities Program Product is
available to augment the data entry and
data set management commands by providing a
text-formatting capability and data set
utilities for terminal users. The product
provides four commands:

• Justify left and right margins of the
text.

• FORMAT, to format textual information
into pages.
• LIST, to display all or part of a data
set at the terminal.
• COPY, to copy a data set.
• MERGE, to merge all or part of one data
set into another.
The FORMAT and MERGE commands Gan also
be used as subcommands of EDIT (EDIT
incorporates a less powerful listing
capability). The COpy and MERGE commands
can be used for access to ASCII tape data
sets. See the publication IBM System/360:
Planning for the Use of Information
Interchange Standards, GC28-6756, for
details.

• Number pages of output consecutively.
• Halt printing when desired.
o

Print multiple copies of selected
pages.

The FORMAT processor scans the data set
for the format controls and inserts blanks,
carrier return characters, headings, and
page numbers as needed. At the user's
option, the output can be formatted for a
terminal or saved in a data set for
deferred printing, either on the terminal
(with the LIST command) or on a high-speed
printer.
Either an all-capitals or an
uppercase and lowercase print chain can be
used on the printer.
Data Set Manipulation
The COpy, LIST, and MERGE commands allow
the terminal user to move information
between data sets and to display data sets
at the terminal.

Text-Handling
The EDIT, FORMAT, and LIST commands provide
a facility for the entry, editing, storage,
and output of text.
With the EDIT command,
the terminal user creates a data set with
the type qualifier TEXT, and enters the
material line-by-line.
If his terminal has
both uppercase and lowercase letters, the
material will not be translated to
uppercase letters, but will be saved just
as entered. The user can specify what tab
settings he wants to use, and the system
will convert tabs in the material into
strings of blanks of the proper length.
The use of line numbers is optional.
The user formats the data set by
inserting format control records into it.
A format control record is entered as a

24

Time Sharing Option Guide

(Release 20.1)

The COpy command will duplicate
sequential or partitioned data sets or a
member of a partitioned data setu While
doing so, i t can resequence or change the
record length, blocksize, or record format
as requested. The MERGE command will copy
all or part of one data set or member into
another data set and will resequence the
record numbers in the target data set if
requested. Both these commands will
process tape data sets in ASCII format.
Tape devices must be allocated to a user in
his LOGON procedure.
The LIST command displays all or part of
a data set at the terrrinal. The user can
request that fields within records be
rearranged for output, and line numbers can
be suppressed or includedD

r---------------------------------------------------------------------------------------,
coblib
1

122 link query load(commands(query»
READY

1

123 query

I
I

I

I

1
3288540
1
1
3288540 PAWL SPRING (4-INCH) 13 DOZ ON HAND
7 ORDER POINT
1
1L_______________________________________________________________________________________
READY
J1

Figure

9.

A Terminal Session Creating a COBOL Program (Part 2 of 2)

Programming at the Tel:minal

33

Page of GC28-6698-3, Revised July 1, 1971, By TNL:

I As

FORTRAN
Two versions of FORTRAN IV with special
support for the foreground environment are
available as Program Products to TSO users:
• Code and Go FORTRAN.
• FORTRAN IV (Gl).·
Both processors can also be used in the
background environment. Two additional
Program Products are available to
complement the processors:
• FORTRAN IV Library (Mod I), for use
with either processor to provide
list-directed input/output support,
ASCII data set handling, and PAUSE and
STOP output to the terminal.
• TSO FORTRAN Prompter, which allows the
terminal user to invoke the FORTRAN IV
(Gl) processor with the FORT or RUN
commands.
A FORTRAN programmer can also invoke the
FORTRAN (E), (G), or (H) processors with
the CALL command, but not with the RUN or
FORT commands. The user is responsible for
allocating the dat:a sets needed by these
compilers, and for specifying the compiler
options. The prompter perf orms thes e
services for the FORTRAN IV (Gl) compiler,
which also has output specially formatted
for the terminal.
Code and Go FORl'RAN is optimized for a
fast compile-and-execute sequence, carried
out entirely within main storage for smallto medium-sized programs. This makes i t a
useful tool for problem-solvers.
It
accepts free-form source statements, and
has simplified I/O statements for
addressing the terminal. However. no
permanent object program is produced. and
some execution speed is sacrificed for fast
compilati':)n.. Whenever the programmer needs
to link separately compiled programs and
subroutines, when he is working with very
large programs, or when he wants to produce
an object program he can save, he will use
the FORTR1\N (Gl) compiler.
He may develop
and test his program with Code and Go
FORTRAN. and then compile it a last time
with the l?ORT command. The TSO CONVERT
command will change free form source
statements to fixed form or vice versa.
Code and ~;o FORTRAN is discussed in greater
detail in the chapter "Problem Solving."
Entering

t~he

Source Program

The programmer uses the EDIT command to
create a Siource program. An operand of the
EDIT command informs the syntax checker
what FORTRAN compiler is going to be used.

34-

GN28-2497

Time sharing Option Guide

(Release 20.1)

the program source statements are
entered, the FORTRAN syntax checker
processes each line, interrupting the input
sequence if i t detects an error.
Figure 10
shows a sY_'1tax checker diagnostic response
and the user action to correct the error.
The first CHANGE subcommand inserts a left
parenthesis, the second, a right
parenthesi:'> •
Compiling a FORTRAN Program

When the programmer finishes entering the
source program, he saves his data set with
the SAVE subcommand, and switches to
command mode to enter the FORT command, or
stays in edit mode and uses the RUN
subcommand. Operands of FORT allow him to
specify various compiler oFtions: whether
or not a listing is to be produced, the
contents of the listing, where it is to be
printed or stored, whether or not an object
program is to be produced, and whether
diagnostics are to be sent to the terminal.
All operands except the input data set name
can default to standard values.

r-----------------------------------------,

1
1

100030 30 format (flO.3)
100040 12 read (2,30) a(i),i=1,5
I> REQUIRED FOR IMPLIED DO
1 EDIT
1change / a/ (a/
Ichange /5/5) /
Ilist *
1 00040 12 read (2,30) (A (I) ,1=1,5)

I
I
I INPUT
1

do 50 i=1,5

1

IL-________________________________________ J
Figure 10.

FORTRAN Syntax Checker
Diagnostic

As the compiler processes the program,
it may find program organization errors
that were not detected by the syntax
checker on a statement-by-statement basis.
Compiler diagnostic messages are sent to
the terminal, along with the statement in
error, and a pointer tc the field in error,
if possible. Figure 11 is an example of
compiler output to the terminal during a
single compilation. The number preceding
the source statement is the line number
assigned by EDIT when the source program
was entered. The line number allows the
programmer to use the edit mode subcommands
to correct the statement quickly, without
listing the entire source program.

Page of GC28-6698-3. Revised July 1, 1971, By TNL:

r----------------------------------------.I

IGl COMPILER ENTERED
1000170 30 FORMAT (16)

I

I

I

$

that offers two types of processing: a
rapid compile-and-execute sequence for
small- to medium-sized programs, or
line-by-line interpretation and execution
of PL/I statements as they are entered.
ITF: PL/I does not produce a permanent
object program.
ITF:
PL/I is described in
the chapter, "Problem Solving."

101)
IGI006I DUPLICATE LABEL
I
ISOURCE ANALYZED
I
IPROGRAM NAME=MAIN
I
1*001 DIAGNOSTICS GENERATED,
I
HIGHEST SEVERITY CODE IS 8
I
READY
L_________________________________________
JI

I

Figure 11.

The PL/I Optimizing Compiler, an IBM
Program Product, is a language processor
for use in either the background or the
foreground environment. For the foreground
environment, the compiler incorporates a
prompter, which allows the user to invoke
it with the PLI or RUN commands. Compiler
options allow the user to request
diagnostics and listings formatted for the
terminal, or to request termination of
compilation if syntax errors are found.

sample of FORTRAN compiler
Output

When the program compiles successfully,
the programmer can print an error-free
listing, and use the LOADGO command to load
his program for execution.
Testing FORTRAN Programs
The FORTRAN programmer has two testing
facilities: The debug facility of the
FORTRAN language, and the TSO test mode.
The debug facility of FORTRAN (Gl)
allows the programmer to monitor program
execution from his terminal. output from
the debug statements such as TRACE and
DISPLAY is sent to the terminal, unless
directed elsewhere with the UNIT option of
the DEBUG statement. DUMP and PDU¥~ output
also goes to the terminal. Execution of
the program can be synchronized with the
terminal by inserting READ statements in
the debug packets, forcing the program to
wait for the user to allow it to continue.
Since FORTRAN debug statements are grouped
together in the source program, they can be
easily deleted with EDIT subcommands when
testing is completed.
The test mode is also availanle for
FORTRAN programmers.
Using an object
program listing and storage map produced by
the compiler, the prograrrmer can ir~ert
breakpoints to interrupt execution of his
program, list and modify variable values in
main storage, and control program flow.
Some knowledge of System/360 instruction
formats and hexadecimal notation is helpful
in using test mode.

PL/I
The PL/I programmer can use the following
language processors from the terminal:
•
•
•
•

ITF:
PL/I.
PL/I Optimizing Compiler.
PL/I (F) Compiler.
PL/I Checkout Compiler.

The ITF: PL/I Program Product is a subset
of PL/I designed for solving problems at
the terminal. It is provided by a compiler

GN28-2497

I

I

The PL/I programmer can also use the
PL/I (F) compiler froIT the terminal, but no
special prompting or output format is
available. The F-level syntax checker can
be used to scan source statements as they
are entered or to scan complete programs.
The PL/I (F) compiler cannot be invoked
with the PLI or PLIC cOITmands, but an
example of a command procedure that uses
the CALL command for the PL/I (F) processor
is given in the last section of this
chapter.
The PL/I Optimizing Compiler implements
a more comprehensive subset of PL/I than
previous compilers and offers a choice of
fast compilation, optirrization for speed of
object program execution, or optimization
for rrinimum object prcgram size. A
sunroutine library is required during
linkage editing of a corrpiler output
module. A second library is required for
execution of the object program. Each
library is available as an IEM Program
Product:
• OS PL/I Resident Library •
• OS PL/I Transient Library.
The PL/I Checkout Compiler is a
two-stage processing prcgram which
translates and interprets (executes) PL/I
prograrr,s.
It can be used in either the
batch or TSO environments of the IBM
System/360 Operating System.
Using the checkout compiler in a TSC
environment will often enable you to check
out a PL/I program in one session at the
terminal. Its conversational checkout
features allow you to communicate with the
compiler during processing. The compiler
prints messages and listings at the
terminal (as requested by the TERMINAL
option) and you can respond with PL/I
subcomrands, or PL/I staterr.ents for
Prograrrming at the Terminal

35

Page :of GC28-6698-3, Revised July'-l, 1971, By TNL:

immediate executionG The subcommands allow
you to change compiler options, request
more information, copy output files at the
terminal, make temporary modifications to
the PL/I program (during interpretation
only), and either continue or terminate
processing.
You can also communicate with the PL/I
program when i t is being interpreted, by
using the conversational I/O feature of
PL/I.
Entering a PL/I Program
The programmer uses the EDIT command to
create his source program and save it as a
data set. He can request EDIT to assign a
line number to each line of his source
program as he enters it. If line numbers
are assigned, he can request the PLII
Optimizing Compiler to use them in
diagnostic messages, instead of statement
numbers. The programmer can use the line
number to retrieve the erroneous source
statement, correct the error, and invoke
another compilation, all without having the
complete listing displayed at the terminal.
Compiling a PL/I Program

I

To invoke the compiler, the prograrrmer uses
either the RUN, the PLIC, or the PLI
command. RUN can be used as a subcommand
of EDIT, allowing the user to correct
errors without entering the EDIT command
again. RUN causes a complete
compile-Ioad-go sequence but does not
produce a permanent object program. RUN is
normally used during the initial
compilations to check for source language
errors. When a program is debugged, the
PLI command can be used to produce an
object program and a full listing. The
object module can be loaded for execution
or linkage eaited into a program library
for use as a load module. Whether invoked
by RUN or PLI, the PL/I Optimizing Compiler
directs diagnostic messages to the
terminal, in either a full or an
abbreviated format.
During testing" the
programmer can have traces and other output
generated by PL/I program checkout
facilities displayed at the terminal.
Program Execution
Programs produced by the compiler can be
executed in either the background or the
foreground.
In the foreground I/O can be
directed to the terminal by allocating a
PL/I file, such as SYSIN or SYSPRINT, to
the terminal with the ALLOCATE command. In
the background these same files can be
directed to data sets or unit record
devices.
36

Time Sharing Option Guide

(Release 20.1)

'GN28-2497

Assembler Language
Like programmers who use the higher level
languages, the assembler language user
enters his source program statements with
the EDIT command. Assembler (F) accepts
free form input, but the tab setting
facilities of EDIT allow the user to create
a forrratted listing.
On request, EDIT
assigns line numbers to the source
staterr€nts, which are later referred to by
diagnostic messages preduced during
assembly. Line number or context editing
is always available te cerrect errors,
modify source statements, or add comments.
Asse~bling

the Program

When tpe programmer completes his source
program and saves it, he invokes Assembler
(F) with the RUN or ASM commands. The use
of these commands requires the TSO
Assembler Prompter Program Product.
Operands of ASM give hirr centrol over the
listing format, disposition of output, and
diagnostic messages.
Assembler diagnostic messages sent to
the terminal include the statement in
error, if possible; both the EDIT-assigned
line number and the assembler-assigned
statement number; and an explanation of the
error.
Usually, the user will not need to
have the complete listing displayed in
order to obtain an error-free assembly.
Using the line nurrbers in the diagnostic
messages, the programmer can quickly locate
and fix source staterrent errors with the
edit mode subcommands.

Test Mode
When assembly completes without error, the
programmer creates a lead module with the
LINK command, and uses the TEST command to
bring it into storage. The TEST command
processor uses the symbol table produced by
the assembler and linkage editor, which
gives the address and attributes of each
symbolic name used in the source program.
Before passing control to the program, TES'I
allows the user to establish initial values
to be passed to the program as test data,
and to set up breakpoints where execution
is to be interrupted for displays, dumps,
and other debugging activity. The user can
refer to points in the program by symbolic
names, absolute relative or indirect
addresses.
To display storage and register
contents, the programmer uses the LIST
subcommand, specifying a register range or

Page of GC2S-669S-3, Revised July. 1, 1971, By TNL:

r-------------------~---------------------,

11

12
13
14
15

16

PROC 1, NAMl
1
FREE FILECSYSUT1,SYSUT3,SYSIN,SYSPRINT)1
ALLOCATE DATASETC*) FILECSYSIN)
1
ALLOCATE DATASET(*) FILECSYSPRINT)
1
LOADGO &NAM1 •• 0BJ PL1LIB
1
END
_____________________________________ -J1

L_~

Figure 15.

A Command Procedure to Invoke a
User Program

It would be possible to call this
procedure from the PLIF procedure by
inserting a record containing:
EXEC LDGO '&NAME'
However, it would be preferable to call it
only when the return code from the compiler
indicates successful execution is likely,
that is, no serious errors were detected
during compilatione To test the compiler
return code, the user inserts a WHEN
statement:
WHEN SYSRCCLE 4) EXEC LDGO

GN28...,2497

The WHEN statement imrrediately follows the
CALL command invoking the compiler Crecord
7 in Figure 12). If the compiler return
code is less than or equal to four C" LE
4"), indicating that no errors, or only
minor errors, were detected, the EXEC
command is executed. If the return code is
greater than four, the EXEC command will be
ignored, the FREE cOITITand is executed, and
the procedure ends. The terminal returns
to comnand mode, and the user will pro.cably
use the LIST command to display the
compiler listing, deterrrine the errQrs in
the source program, correct them with the
EDIT command, and reinvcke the procedure
for another compilation. Figure 16 shows
the modified PLIF corrrrand procedure. A
DELETE command has been added for the
object module, since it is not executable.
Figure 17 shows a use of the procedure for
a successful compilation. The LIST operand
is specified to display each command as it
is executed.

'&NA~ili'

r---------------------------------------------------------------------------------------,

IPROC 1,NAME
I
IALLOCATE DATASETC&NAME •• PLI) FILE(SYSIN)
I
IALLOCATE DATASET(&NAME •• LIST) FILECSYSPRINT) BLOCK(125) SPACEC300,100)
I
IALLOCATE DATASET(&NAME •• OEJ) FILE(SYSLIN) BLOCK(SO) SPACE(250,100)
I
IALLOCATE FILECSYSUT1) BLOCK(1024) SPACE(60,60)
I
IALLOCATE FILECSYSUT3) BLOCKCSO) SPACE(250,100)
I
ICALL 'SYS1.LINKLIB(IEMAA)' 'LIST,ATR,XREF,STMT,MACRO'
I
IWHEN SYSRCCLE 4) EXEC LDGO '&NAME.'
I
IFREE FILECSYSUT1,SYSUT3)
I
IDELETE &NAME •• OBJ
I
lEND
L _______________________________________________________________________________________ JI
Figure 16.

A Command procedure for a Compile-Load-Go Sequence

r---------------------------------------------------------------------------------------,

lexec plif 'derv' list
IALLOCATE DATASETCDERV.PLI) FILECSYSIN)
IALLOCATE DATASETCDERV.LIST) FILE(SYSPRINT) BLOCK(80) SPACEC300,100)
IALLOCATE DATASET(DERV.OBJ) FILECSYSLIN) BLOCK(80) SPACE (250,100)
IALLOCATE FILECSYSUT1) BLOCK(1024) SPACEC60,60)
IALLOCATE FILECSYSUT3) BLOCK(80) SPACEC250,100)
ICALL 'SYS1.LINKLIBCIEMAA)' 'LIST,ATR,XREF,STMT'
IWHEN SYSRCCLE 4) EXEC LDGO 'DERV'
IFREE FILECSYSUT1,SYSUT3,SYSIN,SYSPRINT)
IALLOCATE DATASETC*) FILECSYSIN)
IALLOCATE DATASET(*) FILECSYSPRINT)
1L_______________________________________________________________________________________
LOADGO DERV.OBJ PL1LIB
J
Figure 17.

Using a Compile-Load-Go Command Procedure

Prograrrming at the Terrr.inal

39

Problem Solving

To meet the needs of users who may not be
professional programmers, three
problem-solving languages are available as
IBM Program Products with TSO: Interactive
Terminal Facility (ITF); BASIC ITF:
PL/I,
and Code and Go FORTRAN. These languages
are available as separate program products.
ITF: BASIC is a simple, algebra-like
language that can be quickly learned, yet
it has the power to perform complex
mathematical calculations. ITF: PL/I is a
subset of the full PL/I language. It is a
more powerful language than BASIC for
subroutine handling, but is simpler than
the full PL/I language, making it a good
teaching tool.
ITF: PL/I can be used in
two ways: statements can be interpreted
and executed as they are entered (desk
calculator mode): or they can be collected
into procedures for compilation and
execution as programs or subroutines. Code
and Go FORTRAN provides the full FORTRAN IV
language for terminal users.
It has a very
fast compile-and-execute sequence, carried
out entirely in main storage. Code and Go
FORTRAN accepts free-form source
statements, and has simplified I/O
statements for terminals.
All three languages have
statement-by-statement syntax checking as
the programs are keyed in, and additional
diagnostics are sent to the terminal for
errors detected during compilation and
execution phases. For the ITF: BASIC and
PL/I languages, the test mode allows the
user to monitor program execution with
breakpoints and traces, to inspect and
reset the values of variables and to modify
main storage during execution. The debug
facilities of FORTRAN (G) are included in
Code and Go FORTRAN.
Programs in any of the three languages
are created, and can be run, in edit mode.
Whenever necessary, the user can use EDIT
to replace or modify source statements.
For small to medium-sized programs
performance is better in edit mode than in
corr~and mode, since the source statements
and, in the case of Code and Go FORTRAN,
the object program, can be kept in main
storage and do not have to be read in from
auxiliary storage.

ITF: BASIC
The ITF: BASIC Program Product is
based on the original BASIC language
created for time sharing use at Dartmouth
40

Time Sharing Option Guide

(Release 20.1)

College. With TSO, the BASIC user logs on
to the system, then enters the EDIT
command.
In the input mode he enters
successive statements to define his
problem. If the system detects a syntax
error, he is notified immediately so that
he can correct the faulty statement before
continuing. The user can defer syntax
checking until compilation. When all his
statements have been entered and syntax
checked, the user issues the RUN subcommand
to compile and execute the program. An
operand of the RUN subcommand specifies
whether he wants to execute with short
precision (6 significant decimal digits) or
long precision (15 digits). Programs and
data can be saved from one session to the
next, or deleted after use.
BASIC statements are entered one to an
input line, and can refer to other
statements by the line number assigned by
EDIT. Variables always have one- or
two-character names. Arithmetic operators
used in BASIC statements are +, -, /, *,
and ** (exponentiation).
BASIC includes statements for defining
and handling one- and two-dimensional
arrays. Array references have the form
A(i,j) where "An is the array name, and "i"
and "j" are variables or constants
referririg to the row and column of an
element. Elements can contain arithmetic
or character values.
A special set of statements is included
to handle matrices. A BASIC matrix is
always a two-dimensional array, and can
contain only arithmetic values. Two
matrices with the same dimensions can be
multiplied, added, or subtracted, and a
matrix can be inverted or transposed with
built-in matrix functions.
Figure 18 shows a terminal session
creating a BASIC program to calculate the
infinite sum
00
~

X-n

n =1

to the limit of machine precision.
Statements 010 and 020 write messages to
the terminal, describing the input
requested by ~~atement 030. After
ini tiali zing the variables, the user states
the sum as in BASIC format: S =
S+l/(X**N). statement 070 increments N,
and 080 is a check to see if the precision
limit has been reached. If it has, control
branches to statement 100, to print the
results at the terminal. Note that

Page of GC28-6698-3, Revised July 1, 1971, By TNL:

statement 110 uses an "image" statement to
format output, while statement 130 uses the
default format.
During the execution of the program, the
requests the user to enter the input.
When the results are printed and the
program terminates, the user is returned to
edit mode where he saves the program for
use in later sessions.
"?"

r-----------------------------------------,
edit rsumx basic
INPUT
010 print 'summing l/(x**n)'
020 print 'what x'
030 input x
040 let n=O
050 s=O
060 s=s+l/(x**n)
070 n=n+l
080 if s=s+l/(x**n) then 100
090 goto 60
100 print 'number of terms:' I (n-l)
110 print using 120, s
120
'sum='##.#############
130 print 'last term=', l/(x**(n-l»
140 end
150
EDIT
I run
I
SUMMING l/(X**N)
I
WHAT X
I? 1.065
I
NUMBER OF TERMS:
176
I
SUM= 16.3836700000000
I
LAST TERM=
1.53643E-05
Isave
I SAVED
lend
ILREADY
________________________________________ _
Figure 18.

ITF:

BASIC Sample Session

ITF: PL/I
The ITF:
PL/I Program Product is a subset
of the full PL/I language, suited to
problem-solving because of its simplicity
and eas e of us e. For exampl €, there are no
arithmetic conversion rules to remember:
all arithmetic data is kept in decimal
floating-point format.
The language is
compatible with PL/I as provided by the
PL/I (F) compiler, except that Interactive
PL/I does not require semicolons to
terminate statements, source language
programs are stored with variable-length
records, and some arithmetic data formats
that would default to fixed-point binary in
full PL/I are floating-point decimal in
ITF: PL/I. A utility command, CONVERT, is
provided to format ITF: PL/I source
programs for submission to a batch PL/I
compiler, if the user wants to create an
object program.

GN28-2497

ITF: PL/I can be used under either the
EDIT or the CALC comrrands. Under EDIT,
statements are collected into a program.
When the program is cCIq:lete, the RUN
subcommand is used to compile and execute
it. Under the CALC corrrrand, statements are
interpreted and executed as they are
entered.
Statements are discarded as soon
as they have been executed. Variables,
however, are all defined as "static
externals" and kept in a table in main
storage, where they can be referred to by
subsequent ITF: PLII statements, or
displayed at the terminal. The table of
variables created during a session using
the CALC command can be saved in a data set
for use in later sessicns.
Variables included in ITF:
PL/I are
scalars of either single or double
precision, arrays of up to three
dimensions, character and bit strings,
labels, externals, and entry and return
parameters. Execution control statements
include DO loops, GOTO branch statements,
and IF THEN ELSE conditionals. Procedures
collected under the EDIT command can be
saved and invoked with the CALL statement,
either from another prccedure or under the
CALC command. Only list-directed and
edit-directed stream I/O is provided,
either to a file or the terminal. An
appropriate set of the PL/I built-in
functions is included in ITF:
PL/I.

Test Facility: When a user invokes an ITF:
PL/I or BASIC procedure for execution, as
an option he can specify that the program
is to be tested. In this case, the system
allows the user to set breakpoints in the
program before it is started, and to set up
program traces and displays of variables.
All output from the testing routines is
displayed at the terminal. ~hen the
program is interrupted by a breakpoint, or
when the user hits the attention key, he
can display and modify variab~e values,
modify test procedures, and then restart
the program at the point of interruption.
The ITF testing subcomrnands are a subset of
the TEST subcommands available for the
programming languages.
Syntax errors in an ITF: PLII source
statement are detected as soon as the
statement is entered, and the user is
notified to correct the statement. The
user can request deferral of syntax
checking to compile time. When operating
under EDIT, some errors will only be
detected at compile-execute time.
In this
case, a message is sent to the terminal,
and the user is returned to the edit mode
to correct the error in the source program.
Problem Solving

41

r---------------------------------------------------------------------------------------,
edit div ipli
INPUT
00010
00020
00030
00040
00050
00060
00070
00080
00090
00100
00110
00120
00130
00140
00150
00160
00170
00180
EDIT
save
SAVED
end
READY

div: procedure(x,y);
/* this procedure is a subroutine that finds the */
/* greatest common divisor of any positive x and */
/* Y of six digits or less
*/
xl = max(x,y);
yl = min(x,y);
if (xl <= 0)1 (yl <= 0) then do;
put list ('invalid values');
return;
end;
lab: rem = xl - (floor(xl/yl)*yl);
if rem = a then go to out;
xl = yl;
yl = rem;
go to lab;
out: put list ('the common divisor is:'.yl);
end

calc
CALC
call div (9,24)
THE COMMON DIVISOR IS:
3.00000E+00
end
IL ______________________________________________________________________________________
READY
Figure 19.

ITF:

Code and Go FORTRAN
For the many problem-solvers who are
familiar with the FORTRAN programming
language, the Code and Go FORTRAN Program
Product is available for use from the
terminal. The user creates his program,
and optionally has it syntax-checked, with
the EDIT command. He uses the RUN
subcommand to invoke the Code and Go
FORTRAN compiler. The source program is
converted to an object program in main
42

~

PL/I Sample session

Sample Session: Figure 19 shows a sample
terminal session using ITF: PL/I to create
a procedure finding the largest common
divisor of two positive numbers.
"Max" and
"min" in statements 50 and 60, and "floor"
in statement 110 are built-in functions.
Note that since no file is specified in the
PUT statements, the output is sent to the
terminal. At statement 180, the user
entered a null line, indicating a switch
from the input mode to edit mode. The SAVE
subcommand stores the procedure on
auxiliary storage. The user then enters
CALC to go to the desk calculator terminal
mode, and uses a CALL statement to invoke
the procedure.

Time Sharing Option Guide

(Release 20.1)

~J

storage. As soon as~)th'e object program is
complete, control is Fas~sed to it. The
compiler used for Code and Go FORTRAN
bypasses certain object code optimization
processing for greater compilation sp,eed.
The language includes all the features
of FORTRAN IV as deflned in the publication
IBM System/360: FORTRAN IV Language. Two
extensions to the language are included for
ease of use from the terminal: free-form
source statements and list-directed I/O
statements similar to those provided by
PL/I.
Free-Form Statements: Code and Go FORTRAN
does not require statements to begin in
column 7. If a statement has a label, the
statement can immediately follow the label.
If it has no label, it can start in column
1.

A utility command (CONVERT) is available
to change free-form source statements to
fixed form, if a user wants to submit them
to one of the batch FORTRAN compilers after
developing and testing them in free form.
Code and GO FORTRAN will also accept the
conventional fixed format.

Page of GC28-6698-3 .. Revised July 1"

control characters, and whether an output
transmission is to break in on any input
transmission in progress. A program using
TGET and TPUT does not have to perform OPEN
or CLOSE processing, and need not provide a
DCB for the terminal. However, these macro
instructions are available only to programs
executing in the foreground.
Programs designed to be command
processors can call on the Getline,
Put line, and putget service routines used
by the IBM-supplied command processors for
I/O. As noted earlier, these service
routines have the capability to switch the
input source from the terminal to a b~fer
in main storage, and to 'suppress certa1n
types of output if the terminal is not the
current input source,.
The sequential access methods, BS~
(READ, WRITE, CHECK) and QSAM (GET, PUT),
have been extended to issue TGET, TPUT
when called from foreground programs for
terminal I/O. This is the normal route
for terminal I/O from programs that must
be executable in the background as well
as the foreground, or which are coded in
a higher leve~ language, such as FORTRAN
or COBOL.
Programs using BSAM or QSAM to reach the
terminal use the standard macro
instructions or I/O statements. When the
program is executed, the DD statement or
ALLOCATE command defines whether the I/O is
for a data set or the terminal. No
recompilation is necessary to switch from
one to the other" only a change in the DD
statement.
Getline, putline, Putget and the
sequential access methods all issue TGET or
TPUT for the caller when the I/O is for a
terminal. Figure 29 shows this SVC routine

1971, By TNLz

GN28-2497

handling calls from a TSO user region and
passing the requests to the TCAM Message
Control Program.
Multi-Terminal Message Processors
Independent of TSO, the Telecommunications
Access Method includes facilities for
routine messages received from remote
terminals to queues for an application
program, and transmitting replies generated
by the applications program to queues for a
terminal. In a·system without TSO, such a
message processing program must reside in
main storage in one of the problem program
regions, when it is to be available if one
of the terminals in the telecommunication
network sends a message that requires
processing. With the addition of TSO, a
terminal user logged on to TSO can execute
a TCAM message processing program in a
foreground region. He can do this by
invoking it through the TSO command
language, or by specifying it instead of
the TSO Terminal Moniter Program on his
LOGON procedure. The DD statements which
define the process queues must be contained
in the LOGON procedure. The program will
be swapped in whenever needed, but will not
occupy main storage space when it has no
messages to process. Unlike standard
foreground jobs., which are associate'd with
a single terminal, these message processing
programs can handle GET/READ, PUT/WRITE
TCAM oriented input/output from any
terminal defined to the TCAM processing
queues, through the QNAME operand of the
statements on the LOGON procedure. In
addition, the standard TSO terminal
interfaces, can be used to interact with
the terminal executing the Message
Processing Program. Forfurther
information on message processing programs,
see IBM system/360, TCAM Programmer's Guide
and Reference Manual.

System Summary

53

I/o

MVT Control Program

Operator
Start
Command

TSO Control

Terminal I/o
Requests
From TSO
Routines
Or
User Programs

Figure 29.

TCAM

To/From
Terminals

Mes~age

TPUTTGET
SVC

Control
Program
(MCP)

~lessage

Con trol Program

'1

54

Time Sbaring Option Guide

(Release 20.1>

reduced before the calculation by any
guaranteed background percentage.
The first minor time slice is assigned
to the foreground job at the top of the
group of time-sharing TCBs on the queue.
When the minor slice expires, the TCBs
associated with that job are moved to the
bottom of the time-sharing group, and the
next foreground job receives a minor time
slice.
weighted Dispatching: The third way the
minor time slice calculation can be
performed is on a weighted basis. This
method allows the system to compensate for
jobs that are likely to spend much of their
minor time slice in the wait state, usually
because of pending I/O requests.
(But not
for pending terminal I/O, since a job
waiting for terminal I/O is not swapped in,
and never becomes eligible for a minor time
slice.> Under weighted dispatching, the
system keeps an estimated wait time
percentage for terminal job, based on
averages of time spent waiting by each job
during previous major time slices.
Jobs
with a high estimated wait time percentage
tend to be I/O-bound, and will donate much
of their time slices to jobs with TCBs on
the queue below them. Jobs with low
estimated wait time percentages tend to be
compute-bound, and will use most of their
minor time slice themselves.
It is often
desirable to assign the I/O-bound job a
weighted, or longer, minor time slice to
compensate for its "donation" of execution
time to other jobsa
To weight the minor time slices, the
system forms a sum of the estimated wait
time percentages of the jobs to be assigned
minor slices in the current cycle. Each
job is then given a fraction of the
available execution time equal to its
fraction of the total estimated wait time
percentages.
The algorithm is:
This job's EWT%

where ~s is the minor slice to be assigned
to a terminal job, EWT% is the estimated
wait time percentage, and AT is the
available execution time for this minor
slice cycle, again adjusted for any
guaranteed background percentage.

As an example, consider a minor time
slice calculation for two foreground
regions, one containing Job A, which is
expected to wait 40 percent of its minor
time slice; the other ccntaining Job B,
which is expected to wait only 10 percent.
The SUIT of the estimated wait time
percentages is 50 percent. Job A gets
40/50, or 4/5, of the available execution
time as its minor time slice. Job B is
assigned 10/50, or 1/5, of the available
execution time.
However, Job B will
probably be able to execute for about 40
percent of Job A's minor time slice too
(while Job A is waiting for I/O), and so
will end up with just under half the
available execution time -- about what i t
would have been assigned on an equal
division. Job A, however, will be able to
get its I/O started, wait for it to
complete, and still have some processing
time left to handle the data or issue
another I/O request.
On an equal division
of available time, its minor time slice
might have expired before its first I/O
request completed.

The estimation of wait time percentage
is made by updating a running average of a
job's wait tirr,e percentages at the end of
every major time slice.
In making the
average, a weighting factor is used to
emphasize recent usage over earlier usage.
The weighting factor is called the wait
time decay constant.
Its ~urpose and
function is similar to the region activity
decay constant, and it can also be
specified by the installation. Values
appropriate for general job mixes are
included in SYS1.PARMLIB.

x (AT)

MS
Sum of EWT%s

System Summary
,

:

:"-

'

~

:~

;.

~'

61

Page of GC28-6698-3, Revised July 1, 1971, By TNL:

GN28-2497

System Implementation

This chapter is intended for the
programmers and system analysts responsible
for generating and maintaining a system
with TSO.
(The discussions assume that the
reader is familiar with the system summary
chapter of this publication.) The
discussions contains specific
implementation information. For example,
the discussion "Tailoring a Message Control
Program" does not discuss the role a
message control program plays in a TSO
configuration, but rather provides the
syntax and meaning of the macro instruction
used to generate a message control program.
Included are discussions of how to:

instructions instead of the special TSO MCP
generating macro instructions. You use the
TCAM roacro instructions to generate an MCP
containing the TSO Message Handler and any
other message handlers for your particular
terminal applications, and the necessary
terminal I/O control blocks. The
communications lines which are to be used
with TSO must be dedicated to the TSO
message Handler through the terminal I/O
control blocks and the communications lines
for TCAM applications dedicated to their
message handlers. For further information,
see IBM System/360 Operating System: TCAM
Programmer's Guide and Reference Manual.

• Generate (or tailor) a Message Control
Program.

In addition to the standard TCAM macro
instructions, there is a specialized macro
instruction, the TSOMH macro instruction
which expands to form a TSO Message
Handler.

• Write the cataloged procedures used by
TSO.
• specify TSO starting parameters,.
• Tune the Time Sharing Driver and use
TSO Trace.

I

• Write an installation exit from the
SUBMIT command processor.
• Write an installation exit from the
STATUS, OUTPUT, and CANCEL command
processors.
• write a LOGON Pre-prompt exit.

The TSOMH macro instruction has one
operand CUTOFF which specifies a maximum
input message length. The syntax of the
TSOMH macro instruction is:

TSOMH

[CUTOFF=in;~rrJ

CUTOFF=
specifies the maximum number of bytes
before the remainder of the message is
lost to the system. The value must be
an integer between 150 and 65,535, the
defaul t is 300.

Tailoring a Message Control Program
TSo-Only MCP
TSO includes a standard Message Control
Program (MCP) to handle terminal I/O for
those installations that use TSO for all
their TCAM applications. The installation
must tailor the MCP to match its needs in
three steps. First, it assembles three
macro instructions: LINEGRP, LISTTA, and
TSOMCP. The output of this assembly is a
series of TCAM (Telecommunications Access
Method) macro instructions which must, in
turn be assembled,. The output of this
second assembly forms on MCP that must then
be link edited into SYS1.LINKLIB.
Mixed Environment MCPs
If your installation requires a mixed
environment Message Control Program,
because you have TCAM applications
programs, (message processing programs),
you must generate your MCP using TCAM macro

62

Time Sharing Option Guide

(Release 20.1)

The following is an explanation of each
step of the generation of the MCP supplied
with TSO:
Step 1 - Assemble the one or more LINEGRP
macro instructions each followed
optionally by one or more LISTTA
macro instructions, all followed
by the TSOMCP macro instruction.
Place the resultant output in a
temporary data set that will be
used as input to step 2. The
output of this assembly language
source statements -- TCAM macro
instructions which constitute a
Message Contrel Program.
step 2 - Assemble the TCAM MCP macro
instructions that are generated
within step 1. The output of Step

2 is the MCP object module and is
placed into a temporary data setG
Step 3 - Linkage Edit the object modules
from Step 2 into SYS1.LINKLIB to
create an executable MCP load
module.
Figure 34 shows the Job Control Language
necessary to run these steps.
LINEGRP Macro instruction
The LINEGRP macro is used to define a line
group, a group of terminals with similar-characteristics, for example, a group of
IBlvl 2741 terminals.
The operands specify:
• The types of terminals in the line
group.
(TERM)
U
The ddnarne of the DD statements that
define the communications lines as data
sets.
(DDNMm)
• The number of lines, that is, physical
device addresses in the line group.

(LINENO)
• The number of TCAM basic units, per
terminal buffer.
(UNITNO)
• What translation tables are to be used
to translate from the terminal code to
EBCDIC.
(TRANTAB)
• What character string will identify the
transmission code being used when
dynamic translation is required.
(CODE)
• Whether the terminals in this line
group are on switched or nonswitched
lines.
(DIAL)
• How often polled terminals are to be
polled for input.
(INTVL)
• What special features the terminals in
this line group have -- that is,
transmit or receive interruption; and
for 1050, Text Tirrecut suppression.
(FEATURE)
• The polling and addressing character of
terminals in this line group, for 1050
and 2260/2265.
(ADDR)
• For IBM 2260 and 2265 Display Stations
the screen sizes.

r-----------------------------------------------------------------------------------~---,

I//MCPGEN

JOB

Job card parameters

I

EXEC

ASMFC

1

DD

DSN=&&TCM,DISP=(,PASS),
UNIT=SYSDA,SPACE=(CYL,(l,l»

DD
~"I'.
LINEGRP
LISTTA
LINEGRP
TSOMCP
END

*

EXEC

ASMFC,COND=(4,LT,STEP1.ASM)

DD

DSN=&&OBJ,DISP=(,PASS),
UNIT=SYSDA,SPACE=(CYL, (1,1»

DD

LSN=*. STEP1"ASM. SYSPUNCH,
DISP=(OLD,PASS)

//STEP3

EXEC

PGM=LINKEDIT,COND=(4,LT,STEP2.ASM)

//SYSLMOD

DD

DSN=SYS1.LINKLIB(IEDQTCAM),DISP=SHR

//SYSPRINT

DD

SYSOUT=A

/ISYSUT1

DD

UNIT=SYSDA,SPACE=(1024,(SO,20»

/ISYSLIB

DD

DSN=SYS1.TELCMLIB,DISP=SHR

IISYSLIN

DD

DSN=*.STEP2.ASM.SYSPUNCH,

I

1/ISTEPl

I

I//ASM.SYSPUNCH

1//

I

I//ASM.SYSIN

I
I
I
I
I
I

I
I

1/*

I

1//STEP2
//ASM.SYSPUNCH
//

/ /ASM. SYSI N
//

I
II
LISP=(OLD,PASS)
L _______________________________________________________________________________________
J

Figure 34.

Job stream to Tailor MCP

System Implementation

63

Page of GC28-6698-3, Revised July 1, 1971, By TNL:

GN28-2497

LINEGRP MACRO INSTRUcrION FORMAT

r---------------------------------------------------------------------------------------,
Operation
Operand
I

I Name

.---------------------------------------------------------------------------------------i
(name)LINEGRP
TERM=type
DDNAME=ddname
LINENO=number
[UNITNO=number]
[TRANTAB=(table ,table ••• )]
[CODE=(string ,string •• o)]

[DIAL={~~S}J
[ INTVL=number]
rFEATURE=(BREAK, ) (ATTN,
) (TOSUPPR)]
L
NOBREAK, NOATTN,
[ADDR=character string]
[SCREEN=(integer, integer)]
[TERMNO=(integer, integer)]
L ______________________________________________________________________________________
_

TERM=
specifies the type of terminal making
up this line group. select only one
of the following:
1050 -- defines a line group
consisting of IBM 1050
printer-Keyboards on either
switched (dial) or
non-switched (direct) lineso
2741 -- defines aline group
consisting of IBM 2741
Communications-Terminals on
either switched or
non-switched lines.
5041 -- defines a line group
consisting of both IBM 2741s
and IBM 1050s. The terminals
in this line group must be on
switched (dial) lines.
3335 -- defines a line group
consisting of Teletype Model
33 or Model 35 or bothe The
terminals in this line group
must be on switched (dial)
lines.
226L -- defines a I ine group
consisting of IBM 2260 Dis~lay
stations connected on a local
line.
226R -- defines aline group
consisting of IBM 2260 Display
stations, connected on a
remote line, and optionally
IBM 2265 Display Stations.
2265 -- defines a line group
consisting of IBM 2265 Display
Stations.
DDNAME=
Specifies the ddnames of the DO
statement that define the terminal
lines in the line group as a data set.
These DD statements are found in the
cataloged procedure that is used to
start the MCP.
64

Time Sharing Option Guide

(Release 20.1)

LINENO=
Specifies the number of lines in this
line group. The value is an integer
between 1 and 51.
UNITNO=
Specifies the number of basic units
per buffer for terwinals in this line
groupo A basic unit is used by TCAM
to construct I/O buffers. The default
value is 1.
J,
TRANI'AB=
Specifies the 'translation tables to be
used for this line' group. If this
parameter is omitted, all of the
supplied translaticn tables that are
valid for the terminal type specified
by TERM= will be included exce~t those
marked with an asterisk.

TERM=

TRANTAB=

Comments

1050

1050

2741

CR41
EB41
BC41*

EBCDIC
BCD

5041

1050
BC41*
EB41
CR41

BCD
BCD
EBCDIC
Correspondence

3335

TTYB
T'IYC*

TTY r:arity
TTY non-parity

226L

EBCD

226R

2260

2265

2265

Ccrres~ondence

*Not used as a default translaticn
table.

Page of GC28-6698-3, Revised July 1, 1971, By TNL:

NOATTN

Note: If more than one table is
specified explicitly or implied by
default, the MCP will determine the
proper translation table dynamically
using the CODE parameter.

TCSUFPR

CODE=
Specifies the character string used to
determine the terminal character setG
Each time a terminal is connected, the
MCP translates the input line from
that terminal, using each of the
translation tables specified in the
TRANTAB operand. The MCP compares the
translated result with the character
string specified in the CODE= operand.
When the MCP finds a match, it uses
the appropriate translation table with
that terminal from then on.
The default is CODE=LOGON unless the
TRANTAB operand specified both BC41
and EB41 (2741 BCD and 2741 EBCDIC).
If both EBCDIC and BCD character sets
are present in the line group, the
default is CODE=nLOGON.
An installation can specify a maximum
of four character strings other than
LOGON, but they must be eight or less
characters.
DIAL=
specifies whether the line group is a
dial (switched) line group. If this
parameter is omitted, YES is assumed.
DIAL=NO is required for TERM=226L,
226R, 226S.
INTVL=
Specifies the poll delay intervals in
seconds for polled lines. The value
is an integer between 1 and 2SS.
If
this parameter is omitted, a value of
two is assumed for polled lines.
FEATURE=
specifies the special features that
define this line group:
BREAK

NOBREAK

ATTN

specifies that terminals in
this line group have the
Transmit Interruption
feature.
Specifies that terminals in
this line group do not have
the Transmit Interruption
feature. This operand should
be specified when any of the
terminals in the line group
do not have the feature.
Specifies that terminals/in
this line group have the
Attention feature (Receive
Interruption. )

GN28-2497

specifies that terminals in
this line group do not have
the Attention Feature.
For 10S0 terminals, this
operand specifies that the
optional 'Iext Time- out
Suppression feature is
present.
This operand
applies only to 10S0
terminals and should be
specified only if all 10S0
terminals in a 10S0 or S041
group have the feature.
When
specified read inhibit rather
than read commands will be
used.

The following table describes the
features which rr.ay be specified for
the 10S0, 2741, S041, 2260 and the
333S (TWX); where
D
A
I

o

Default.
Assumed.
Invalid.
Optional.

Feature

10S0

BREAK
NOBREAK
ATTN
NOATTN
TCSUPPR

o
D
D

o

o

2741
D

o

S041 333S 2260

o
]:;

D
C

L

o

A

0*

A
I
A
I
A

I

A
I
A
I

*TOSUPPR is optional for the 10S0
terminals in a S041 line group. It is
assumed for the 2741 terminals in the
same S041 line grcup"
ADDR=
specifies.the station identification
character (10S0) or the two byte
control unit, device address
(226R,226S) of the terminals in the
line groupG The character string
should be the hexadecimal equivalent
of the appropriate transmission code.
Hexadecimal characters should be
specified without framing characters.
For example if the station
identification character is "A", the
correct specification is ADDR=E2, the
hexadecimal equivalent of the 10S0
transmission code for the character
"A", not ADDR=Cl, the hexadecimal
equivalent of the EBCDIC character
"An.
To find the hexadecimal
equivalent of a given character in a
specific transmission code, consult
the component description
publications. For the 10S0, only the
station identification character value
need be specified: the component
selection character values will
default to the common polling and
addressing values for input and
Systerr Implementation

6S

Page of GC28-6698- 3, Revised July 1, 1911, By TNL:

output, respectively..
is not supported,.

GN28-2491

1050 multidrop

This parameter is not valid for
TERM=2741 or TERM=3335. This
parameter is required for TERM=1050 or
5041. For configurations in which the
addressing characters vary among the
different terminals in the line group
as in 2260, the addressing characters
should be specified using LISTTA macro
instructions (see below) rather than
in the LI~EGRP macro instruction.
SCREEN
Specifies the screen dimensions of the
display. station(s) on the line. The
first, --integer specifies the number of
rows on the screen.. The second
integer specifies the number of
characters per row. Standard IBM
screen size are 12x80, 12x40, 6x40,
and 15x64 non-standard sizes will be
accepted but a warning will be given.
The default for this parameter is
(12x80).
TERMNO=
Specifies the number of terminals
attached to each non-switched line,
used with TERM=226R, and 2265.
Each subparameter specifies the number
for the corresponding relative line
number. The relative line number
within a group refers to the order in
which lines are defined in the MCP
start cataloged procedure.
LISTTA Macro
The LISTTA macro instruction specifies
variations in device address (ADDR) within
a line group. One or more LISTTA macro
instructions can appear after each LlNEGRP
macro instruction.
Each LISTTA macro
instruction modifies one line (RLN) within
a line group.

in the line group defined by the first
DD statement.
ADDR=
Specifies the alphabetic station
identification character (1050) or two
byte control unit and device address
(2260 and 2225) of the terminal(s) on
this line. One character string must
be specified for each terminal on the
line. Subparameters must be specified
in the order in which polling is to
take place. Each character string
should be the hexadecimal equivalent
of the appropriate transmission code
representation for the terminal
involved.
Hexadecimal characters
should be specified without framing
characters.
Example: ADDR= (A OA1, AOA2).
For a
2848 Model 2, with two 2260 Display
stations.
For a 1050, only the station
identification character value need be
specified. 1050 nultidrop is not
supported.
SCREEN
Specifies the screen dimensions of the
display station(s) on the line. The
first integer specifies the number of
rows on the screen. The second
integer specifies the number of
characters per row. Standard IBM
screen size are 12x80, 12x40, 6x40 r
and 15x64 non standard sizes will be
accepted but a warning will be given.
The default for this parameter is
<12x80) •
TSOMCP MACRO INSTRUCTION FORMAT

LISTTA MACRO INSTRUCTION FORMAT

r----.----------.-------------------------,I
I Name I operationlOperand
.----+----------+-------------------------~
I name I LISTTA
IRLN=integer
I
I
I
I [.ADDR= (chars , chars ..... )] I
JI
[,SCREEN]
IL-___ I __________ I _________________________
~

~

RLN
specifies the relative line number
within a line group to which the
attributes specified in this macro
instruction call apply. The relative
line number within a group refers to
the order in which lines are defined
in the MCP start cataloged procedure.
For example, RLN=1 refers to the line
66

Time Sharing Option Guide

(Release 20.1)

TSOMCP Macro
The TSOMCP macro instruction:
• Names the MCP. (provides the CSECT
narre) •
• Defines the size of the TCAM basic
units used to construct terminal I/O
buffers.
• Specifies which TCAM trace tables will
be provided.
• Specifies whether a cross-reference
table will be included in the MCP~
• Specifies whether the operator can
specify parameters when he starts the
MCP.

Page of GC28-6698-3, Revised July 1, 1971, By TNL:

r----j----------j------------------------.I

I Name I Operationioperand

~----+----------+-------------------------~

I

I

I name I TSOMCP

I

I

I
I

I
I

I
I

I

I

'!UNITSIz=numberJ
I TRACE=number J
I DTRACE=number
I LNU ITS=number
I OLTEST=number

I
,

g

I
I
I

~---1----------lh2~!~2~~i~~~~~~~OM~::~-~

INote:
All operands are optional.
L
________________________________________
-JI

GN28-2497

the associated line group. If UNITNO
is omitted in the LINEGRP macro, the
default value (1) is used. This means
that each buffer will consist of one
basic unit.
If both the LNUNITS and UNITNO
keywords are defaulted, the buffer
pool created will consist of 2 buffers
per terminal with each buffer being
one basic unit in length.
(PCI
buffering is used for both input and
output. )

name
Names the start of the MCP and
provides a CSEcr label for the
generated program. This field is
required.
UNITSIZ=
specifies the size of a TCAM basic
unit and must be a value between 38
and 255 inclusive. If omitted, the
MCP uses a default size of 44.
UNITSIZ should be a multiple of 8,
plus 4 for efficient core usage.
TRACE=
Specifies the number of TCAM I/O trace
table entries in the Message Control
Program. The default value is zero.
Maximum value is 65535. See IBM
system/360 TCAM Programmers GUIde and
Reference.
r
DTRACE=
specifies the number of TCAM subtask
trace table entries in the Message
Control Program. The default value is
zero. Maximum value is 65535. See
IBM System/360 TCAM Programmers Guide
and Reference.
LNUNITS=
specifies the number of TCAM basic
units (See IBM system/360 TCAM
Programmers Guide and Reference) to be
provided in the buffer pool for
creating line buffers for this MCP. A
maximum of 65,535 may be specified.
If this operand is omitted, the system
will calculate a default value using
the following algorithm:
LNUNITS=
2 x (number of terminals> x (UNITNC
value> or
2.5 x (number of terminals> x UNIT NO
for 2265/65
where.,
UNITNO (as specified in each LINEGRP
macro) represents the number of units
per buffer for terminals defined in

OLTEST=
Specifies the number of On-line Test
procedures which can execute
simultaneously_ The value must be
between 0 and 255. The default is 0,
meaning On-line Test not supported.
OPTIONS
XREF
A cross-reference table
including control blocks
for each line will be
included in the MCP. If
this option is omitted, the
cross-reference table will
be excluded.
PROMPT
If PROMPT is specified, the
system operator will te
asked tc enter parameters
when TCAM is started. At
that time he may enter and
override some of the
parameters specified when
the MCP was assembled. The
following TCAM parameters
are ones which an
installation may want to
specify when it starts TCAM
for TSC. The last
parameter entered must be a
nUn to end the prompting
process. See IBM
system/360 TCAH
Programmer's Guide and
Reference f0r a description
of the IN~RO macro
instruction and the
parameters which can be
overridden.
KEYLEN = integer
K = integer
specifies the size of the
basic units, with which the
terminal I/O buffers are
constructed. This
corresponds to UNITSIZ=
parameter.
System Implementation

67

LNUNITS = integer
B
integer

overlay the oldest entries.
Maximum to be specified is
65,535: 'If 0 is specified,
the table is not generated.

=

Specifies the number of
basic units which are used
to build buffers"
corresponds to LNUNITS.
The value must be between 0
and 65,535
STARTUP
S

OLTEST=number
0= number
Specifies the number of
On-line Test procedures
that can execute
simul taneously.. This
parameter corresponds to
the OLTEST parameter of the
TSOMCP macro instruction.
The default is 0., which
indicates that On-line Test
is not sUpported.

=C

Specifies that a "cold"
start is to be performed
following a shutdown of the
Message Control Program or
a system failure. It is
required if OPTIONS=PROMPT
was specified on the TSOMCP
macro instruction.

CIB = integer
C = integer
Specifies the maximum
number of Command Input
Blocks (CIB's) that can be
used at anyone time in the
TCAM subsystem, CIB's are
the buffers used to contain
operator control messages
entered at the system
console. Maximum that can
be specified is 255; if the
operand is omitted, "CIB=2"
is assumed. At least two
~~B~s should be specified,
singe START uses one. If
an attempt is made to enter
an operator control message
from the system console,
and the number of CIBfs
specified is already in
use, the message is
rej ected by TCAM .•

CROSSRF=integer
F = integer
Specifies the number of
entries in the cross
reference table, a
debugging aid. If
OPTIONS=XREF is specified
in the TSO MCP" one entry
will be generated for each
line. If the operator
specifies fewer entries
than there are
simultaneously open lines,
lines opened after the
table is full will have no
entries
TRACE = integer
T = integer
specifies the number of
TCAM I/O trace entries to
be allocated, corresponds
to TRACE= in the TSOMCP
macro instruction.
Dl'RACE = integer
A = integer
Specifies the number of
entries in the TCAM
Dispatcher Trace Table,
corresponds to DTRACE= in
the TSOMCP macro. The
Dispatcher Trace Table is a
debugging aid that keeps a
sequential record of TC~l
subtasks activated by the
TCAM dispatcher. One four
word entry is created for
each subtask activated;
when the end of the table
is reached, the table is
wrapped around; new entries
68

Time Sharing Option Guide

(Release 20,.1)

Figure 35 and 36 show the MCP macro
specifications for two sample systems.
The first system has:
1.

2.
3.

10 lines for leased, (non-switched),
2741's; all are BCD terminals and use
EBCDIC character set only. All
terminals in this line group have both
Receive and Transmit Interrupt
features.
5 lines of teletype (which could be
either 33 or 35).
The system operator will be prompted
to enter TCAM parameters when he
starts TCAM. At that time he can
override any of the parameters
specified on the TSOMCP macro, as well
as other TCAM parameters. See the
description of the TSOMCP macro
instruction, for parameters pertinent
to TSO.
(The operator will always

Page of GC28-6698-3, Revised July 1, 1971, By TNL:

have to reply "s=c,u": STARTUP=COLD
and a "un to terminate prompting.} A
Dispatcher Subtask Trace Table, useful
for debugging purposes, is to be
included in the MCP. It will contain
100 4 byte entries.
(DTRACE=100)

C.

Five 2741's, Correspondence Code,
Receive and Transmit Interrupt
features.

D.

TWo 2741's, EBCDIC code.

The defaul t
The sample system shown in Figure 36 has 10
dial lines, to be used by both 1050·s and
2741's. The station identification
character for the 1050's is "A". Notice
that it is specified in terminal
transmission code, (E2) not EBCDIC (Cl).
Assume there are four types of terminals in
the line group.
A.

Three 1050's, with Text Timeout
Suppression feature, Receive and
Transmit Interrupt features.

B.

One 1050, with Text Timeout
Suppression feature.

GN28-2497

is ATTN and NOBREAK.

Users at terminals in groups A and C would
use the TERMINAL comreand to request
Transmit Interrupt handling, (BREAK), the
installlation could provide a special LOGON
cataloged procedure for these users
containing a suitable TERMINAL command as
the PARM value. Users at terminals in
groups Band D would not be able to cause
an attention interruption during output, or
while the keyboard is locked. They would
use the TERMINAl: command to set up
simulated attention breaks by time interval
when the keyboard is locked, or after a
number of consecutive lines of output, when
output is being sent. This also could be
specified in a LOGON procedure.

r---------------------------------------------------------------------------------------,
ILINEGRP
TERM=2741,DDNAME=LNGP2741,LINENO=10,
X
I
I
TRANTAB=EB41,DIAL=NO
I
TERM=3335, DDNAME=LNGPTWX,LINENO=5
I
I LINEGRP
L-______________________________________________________________________________________
JI
OPTIONS=PROMPT,DTRACE=100
I TSOMCP
Figure 35,.

Sample MCP

r-----------------------~~-------------------------------------------------------------,
ILINEGRP
TERM=5041,DDNAME=DIAL5041,LINENO=10,ADDR=E2, X
I
I
FEATURE=TOSUPPR
I
IL-______________________________________________________________________________________
TSOMCP
rf
JI

Figure 36.

Sample MCP

System Implementation

69

Page of GC28-6698-3, Revised July 1, 1971, By TNL:

GN28-2497

Writing Cataloged Procedures for TSO

Message Control Program

Two categories of cataloged procedures are
used by TSO. The first includes procedures
invoked by the system operator when he
starts any of these four TSO tasks:

The cataloged procedure used to start the
Message Control Program specifies through
the PGM= operand of the EXEC statement the
MCP to be started. The MCP should be named
IEDQTCAM. This name allows the MCP to run
in a region smaller than MINPART and ensure
that the MCP can not be canceled, that is
the operator must halt it~ specify
TIME=1440 to eliminate timing. Specify
ROLL=(NO,NO) to preclude an attempt to
Rollout the MCP. Specify DPRTY=(15,15) to
insure high priority. The MCP must run at
a higher priority than the TSC.

1.
2.
3.
4.

The Message Control Program (MCP).
The Time Sharing Control Task (TSC).
The Background Reader for the SUBMIT
coromand (BRDR).
The TSO Trace Writer.

The second category consists of those
procedures invoked each time a LOGON
command is entered at a terminal. The PROC
operand of the LOGON command specifies the
name of the cataloged procedure which:
1.

2.

Contains the JCL statements that
define the data sets available to the
terminal us er •

The cataloged procedure used to start
the MCP also must define any terminals
attached to the systerr as data sets. This
is done through the ddnames specified in
the LINEGRP macro instructions used in
generating the MCP. Figure 37 shows two
procedures that can be used to start the
two sample MCPs generated in Figure 35 and
36.

I

Specifies the name of the Terminal
Monitor Program (TMP) supplied with
TSO or the user-written substitute for
the TMP.

Both categories of cataloged procedures
must be members of SYS1.PROCLIB or members
of partitioned data sets concatenated to
SYS1. PROCLIB.

Time Sharing Control Task
The cataloged procedure used to start the
Time Sharinq Control Task contains the Job
Control statements defining all the system
resources the TSC requires. The procedure
consists of an EXEC statement and several
Data Definition .staterrents.

r---------------------------------------------------------------------------------------,

1//MCP1
EXEC PGM=IEDQTCAM,ROLL=(NO,NC},TI~E=1440,DPRTY=(15,15),REGION=70K
1//LNGP2741
DD UNIT=021 FIRST LINE GROUP DATA SET 2741
1//
DD UNIT=022
1//
DD UNIT=023
1//
DD UNIT=024
1//
DD UNIT=025
1//
DD UNIT=026
1//
DD UNIT=027
1//
DD UNIT=028
1//
DD UNIT=029
1//
DD UNIT=02A
I//LNGPTWX
DD UNIT=02B SECOND LINE GROUP DATA SET TWX
1//
DD UNIT=02C
1//
DD UNIT=02D
1//
DD UNIT=02E
1//
DD UNIT=02F
1

1//MCP2
EXEC PGM=IEDQTCAM,ROLL=(NO,NO),TIME=1440,DPRTY=(15,15),REGION=66K
1//DIAL5041
DD UNIT=021 LINE GROUP DATA SE~
1//
DD UNI'I=022
1//
DD UNIT=023
1//
DD UNIT=024
1//
DD UNIT=025
1//
DD UNIT=026
1//
DD UNIT=027
1//
DD UNIT=028
1//
DD UNIT=029
1//
DD UNIT=02A

L _____________________________________________________ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Figure 37.
70

Sample MCP start Procedures

Time Sharing Option Guide

(Release 20.1)

Page of GC28-6698-3, Revised July 1, 1971, By TNL:

The EXEC statement of the cataloged
procedure that starts the Time Sharing
Control Task, specifies:
• The TSC program name, which is
IKJEATOO.
u

The TSC region size. If the TSC needs
a different sized region, it will
obtain one.

• ROLL=(NO,NO) to preclude an attempt to
Rollout the TSC region, if
OPTICNS=ROLLOUT has been specified
during system generation.
o

DPRTY=to set a priority for the TSO.
It must be lower than the MCP.

six data sets must be defined.
• SYSPARM -initiation
parameters
TSO system

The library containing TSC
parameters. These
are discussed under "Writing
Parameters".

GN28-2497

For example, if an installation has two
data sets and wants to use parallel
swapping it would use SYSWAPOO and SYSWAP01
as the ddnames.
If an installation wanted to use a IBM
2301 drum for a prime swap data set and a
IBM 2314 as overflow, the ddnames would be
SYSWAPOO for the 2301 the prime data set,
and SYSWAP10 for the 2314, the first
overflow data set.
If a system or TSO
failure causes TSO to be restarted, you can
use IMDPRDMP program to save the swap data
sets before attempting to restart TSO.
When invoking IMDPRDMP, the DD statements
for the swap data sets should be the same
as those in the TSO cataloged procedure;
the //PRINTER DD statement writes to tape
with chained scheduling and a large
blocking factor so that the data sets are
dumped quickly.
The publication IBM
Systerr/360 Operating System: Service Aids
GC28-6719 shows the procedures for
analyzing system failures and how to use
the IMDPRDMP program to save the swap data
sets.
STARTING AND STOPPING TSO

• SYSUADS -- The User Attributes Data
Set, this data set cannot be
concatenated.
o

SYSLBC -- The broadcast data set which
contains messages from the SEND command
and a list of valid us'ers should not be
password protected.

When the operator starts TSO for the day,
he must:
1.

Issue a START corrrrand to start the
Message Control Program. The operand
of the START command is the name of
the cataloged procedure that provides
the Job Control statements necessary
to execute the MCP.
For example if
the cataloged procedure used to start
the MCP is named TCAM, the operator
will issue a START TCAM command.

2.

Issue a START command to start the
Time Sharing Control Task (TSC). The
operand of this command names a
cataloged procedure used to start the
TSC.
For example if the cataloged
procedure used to start the TSC is
named TS, the operator would issue a
START TS command.

• SYSWAPOO -- 'The -swap data sets.
o

o

IEFPDSI -- The partitioned data set
containing LOGON cataloged procedures.
This data set may be either
SYS1.PRCCLIB or a partitioned data set
dedicated to LOGON procedures. A
dedicated data set will speed up LOGCN
processing.
SYSTSDP the TSO dump usua.lly a tape
volume.

For each of these data set definitions,
DISP=SHR should be specified.

When the operator stops TSO for the day,
he must:

Figure 38 shows a sample cataloged
procedure to start the TSC.

1.

The data definition ddname on the DD
statement defining the SWAP data set
specifies whether serial or parallel
swapping- is to be used.
The ddname is of
the form

Issue a STOP corrrrand to stop the Time
Sharing Control Task. The operand of
the STOP command rrust be the same as
the operand that was used to start the
'I'SC.

2.

Issue a HALT corrrrand to stop the
Message Control Program.
If the PGM=
operand of the EXEC statement in the
cataloged procedure used to start the
MCP is IEDQTCAM, then the MCP cannot
be cancelled with a CANCEL corrmand.
If the operator cancels the MCP, the
TSO must be stopped before the MCP is

SYSWAPln
Where 1 indicates the level of the data
set, i.e., 0 for prime, 1 for first
overflow; and n is the data set number at
this level.

System Implementation

71

Page of GC28-6698-3, Revised July I, 1971, By TNL:

GN28-2497

.--------------------------------------------------------------------------------------,
I//IEFPROC
EXEC PGM=IKJEATOO,ROLL= (NO,NO),DPRTY=(13, 13)
1
I//SYSPARM
DD DSN=SYS1.PARMLIB,DISP=SHR
1
I//SYSUADS
DD DSN=SYSl.UALS,DISP=SHR
1
I//SYSLBC
DD DSN=SYS1.BRODCAST DISP=SHR
1
I//SYSWAPOO DD DSN=SYS1.SwAP1,DISP=SHR
I
1//SYSWAP01 DD DSN=SYS1.SWAP2,DISP=SHR
1
I//IEFPDSI
DD DSN=SYS1.PROCLIB,DISP=SHR
L_______________________________________________________________________________________
J1
Figure 38.

Sample Cataloged Procedure to Start Time Sharing Control Task

restarted. The MCP cannot be halted
with a HALT command unless the TSO is
stopped.

• Specify the prograrr name of the
Background Reader.
• Pass the Background Reader standard
Reader-Interpreter parameters.
• Define required data sets.

DEFINING A UADS USING THE TSC PROCEDURE

J

When a TSO system is first started after
system generation, it is necessary to
construct a UADS using the ACCOUNT command.
The distributed DADS contains one valid
user:IBMUSER and this user is authorized to
use one procedure:
IKJACCNT. He should
use the ALLOCATE command to define a new
UADS with a file name of SYSUADS and a data
set name other than SYS1cUADS, specifying
its volume serial number, and define his
UADS structure with a series of ACCOUNT
command ADD subcornrnands. He should then
log off, stop the system, and change the
SYSUADS DD statement in the TSC start
procedure, to point to the new UADSo If
the cataloged procedure defines SYSUADS
though a DSN= operand, then he need only
rename the data set.

The Background Reader, (BRDR), runs as a
system task. It is started by the
operator. It interprets Job Control
Language passed by a terminal user with the
SUBMIT command. If there is no input for
the BRDR, i t will relinquish its region and
wait for input. Output from the BRDR is
placed on SYS1.SYSJOBQE and is queued for
execution by a standard initi~tor. The
cataloged procedure that provides the Job
Control Language to start the Background
Reader is similar to cther reader
procedures. The BRDR program name is
IKJEFF40. Figure 39 shews an example of a
BRDR procedure. For fUrther information on
writing system reader/interpreter cataloged
procedures, see IBM Systern/360 Operating
System: System Programmers Guide,
GC28- 6550.

Background Reader (BRDR)

An installation exit can gain access to and
modify or delete any JCL passed by the
SUBMIT command processor. The section,
"Writing Installation Exits for the SUBMIT
Command" describes how to write this exit.

The cataloged procedure used to start the
Background Reader (BRDR) contains Job
Control statements that

r---------------------------------------------------------------------------------------,
EXEC PGM=IKJEFF40,
1

I//BRDR

1//
1//

REGION=70K,
1
PAR1-1='READERPARM'
1
I//IEFPDSI DD
DSN=SYS1.PROCLIB,
1
1//
DISP=SHR
1
I//IEFDATA DD
UNIT=SYSDA
1
1//
SPACE= (80, (SOO,SO),RLSE,CONTIG) ,
1
1//
DCB=(BUFN0=2,LRECL=80,BLKSIZE=80,DSORG=PS,
1
1//
RECFM=F,BUFL=80)
1
I//IEFRDER
DD
DUMMY
L _______________________________________________________________________________________
J1

Figure 39.

72

Sample Background Reader (BRDR) Procedure

Time Sharing Option Guide

(Release 20.1)

Page of GC28-6698-3, Revised July 1, 1971, By TNL:

GN28-2497

PARAMETER
OWNER

KEYWORD

MEANING

TS

TERMAX=nnnn

Specifies maximum number of users.

USERS=nnnn

Specifies initial maximum number of users, defaults to
TERMAX, can be changed by MODIFY command.

REGNMAX=nn

Specifies number of TSO user regions.

MAP=nn

Specifies the number of MAP entries, used to reduce
swapping of unused storage.

SMF=[g~~=11 [,EXT=JYES}ll
OPT=iJ

DRIVER

Figure 42.

hill

U

standard SMF parameters, see MVT Job Management.

DSPCH=cccccc

Specifies first six characters of Time Sharing Driver.
Defaults to IKJEAD, driver supplied with TSO. This
parameter defines the names of all four Driver
modules. That is the driver supplied with TSO has
four modules, IKJEADOO to IKJEAD03.

LPA=(module list)

List of modules to be included in Time Sharing Link
Pack Extension.

REGSIZE(nn)=(mmK,
iiik)

Specifies region size (mmk) and LSQS size (iiik)
for region nne Defaults to zero.

SUBMIT=nnnn

Specifies the maximum number of tracks in the SUBMIT
command job queue. Defaults to limit set at System
Generation.

DUMP= fDUMP ]
LNODUMP

Specifies whether the SYSTSDP DD statement is in the
START TSO procedure and the TSO dump facility will be
used.

WAIT
NOWAIT

Specifies use of wait estimate option.

ACTIVITY
NOAcrIVITY

specifies whether Region activity estimate is to be
used in assigning a user to a region. NOACTIVITY
required for single region system.

OCCUPANCY
NOOCCUPANCY

Specifies whether core occupancy estimates are to be
used in queue selection.

SWAPLOAD
NOSWAPLOAD

specifies whether swapload is to be used in queue
placement.

AVGSERVICE
NOAVGSERVICE

specifies average queue service time to be used.

PRIORITY
NOPRIORITY

specifies whether priority scheduling is to be used.

PREEMPT/
NOPREEMPT

specifies whether preemptive scheduling is to be used

BACKGROUND=nn/
NOBACKGROUND

specifies a percentage of CPU time guaranteed to
the background or no guaranteed time.

DECAYWAIT=nnnn

Specifies in 100ths the decay constant for the wait
estimate. Assumes WAIT specified.

TSO System Parameter Syntax (Part 1 of 2)

System Implementation

77

PARAMETER
OWNER

TIOC

Figure 42.

78

KEYWORD

MEANING

DECAYACT=nnnn

Specifies in 100ths the decay constant for the
activity estimate. Assumes ACTIVITY specified.

SUBQUEUESCn)=mmm

Specifies the number of queues for region n.

CYCLESCn,m)=iii

Specifies the number of service cycles to be given to
the roth queue of the nth region.

MAXSWAP=Cn,m)=iii

Specifies the maximum number of 1024 byte blocks which
may be allowed to a user on queue m, in region n.
Assumes SWAPLOAD specified.

MAXOCCUPANCY Cn,
m)=iii

Specifies the maximum amount of time in 100th of a
second a user on queue m in region n can reside in
core.

SERVICE (n,ro)=iii

Specifies the average service time in 100ths of a
second for a user on queue m in region n.

MINSLICECn,m)=iiii

Specifies the minimum time slice in 100th of a second
to be given to a user on queue m in region n.

BUFSIZE=nn

specifies size of terminal buffer.

BUFFERS=nn

Total number of buffers.

OWAITHI=nn

Specifies maximum number of allocated output terminal
buffers per user in order to put a user program into
output wait.

INLOCKHI=nn

Specifies the maximum number of allocated input
terminal buffers per user in order to lock a users
keyboard.

OWAITLO=nn

Specifies the number of allocated output buffers to
bring a user out of output wait state.
In other words
if OWAITLO=4, when 4 or less buffers remain allocated,
the user is brought out of output wait.

INLOCKLO=nn

Specifies the number of currently allocated input
buffers to unlock the terminal keyboard for input.
other words, when the number of allocated input
buffers falls to or below the INLOCKLO value, the
user's keyboard is unlockeda

Default 44.

In

US ERCHG=nn

Specifies percentage of change in logged on users
needed to redistribute buffers and recalculate the
OWAITHI and INLOCKHI numbers during slack time.

RESVBUF=nn

Specifies the total number of terminal buffers that
must be free to avoid locking all terminals to prevent
input.

SLACK=nn

Specifies number of logged on users that constitute
slack time.

TSO System Parameter Syntax (Part 2 of 2)

Time Sharing Option Guide

CRelease 20.1)

r-----T---------------------------------T-----------------------------------------------,
I Entry I
When Produced
I
Description of Contents
I
IType \

I

I

r-----+---------------------------------+-----------------------------------------------~

I 'A' I When the trace writer is started. I Word 1
I
I
\Word 2
I
I
\Word 3

X'FFFFFFFD'

# of 3-word entries per record

Time of Day in

ti~er

units

I
I
I

r-----+---------------------------------+-----------------------------------------------~

I 'B' IWhen the trace writer is stopped.\Word 1
I
I
\Word 2
\
I Word 3
I

X'FFFFFFFE'
Date in packed decirr.al OOYYDDDS
Time of Day in timer units

I
I
I

r-----+-----·----------------------------+-----------------------------------------------~

I 'c' \When information was lost (volume\Word 1
I
I
I

I switching, low sampling rate,
letc.
I

IWord 2
IWord 3
I

X'FFFFFFFF'
I
Number of entries lost
I
Tirre of Day in tirrer units of the firstl
lost entry
I

r-----+---------------------------------+-----------------------------------------------~

I'D'
I
I
I
I

INormal entry 
0"
::I

co

c:

::I
(D

Note: Please direct any requests for copies of publications, or for assistance in using your
IBM system, to your IBM representative or to the IBM branch office serving your locality.

Fold

Fold

FIRST CLASS
PERMIT NO. 81
POUGHKEEPSIE, N. Y.

BUSINESS

REPLY

MAIL

NO POSTAGE STAMP NECESSARY IF MAILED IN THE UNITED STATES

POSTAGE WILL BE PAID BY •••

IBM Corporation
P.O. Box 390
Poughkeepsie, N.Y. 12602

Attention: Programming Systems Publications
Department 058

Fold

International BusineEs Machines Corporation
Data Processing Division
112 East Post Road, White Plains, N.Y. 10601
[USA Only]
IBM World Trade Corporation
821 United Nations Plaza, New York, New York 10017
[International]

Fold

._------_.

_.-

....•.

_._ ...•._..

Technical Newsletter

File No.

8360-20 (08 Release 20.6)

GC28-6698-3

Base Publ. No.

GN28-2502

This Newsletter No.
Date:

september 16 1971

Previous Newsletter Nos.

GN28-2497

IBM 8ystem/360 Operating System:
Time Sharing Option Guide
© IBM Corp. 1969,1970,1971
This Technical Newsletter, applies to release 20.6 of IBM
System/360 Operating System, provides replacement pages for the
subject publication. These replacement pages remain in effect for
subsequent releases unless specifically altered.
Pages to be
inserted and/or removed are:
Cover,2
Summary of Amendments
15,16,16.1
47,48,48.1
71,72
75-78,78.1
87,88
A change to the text or a change to an illustration is indicated
by a vertical line to the left of the change.
Summary of Amendments

The TSC start parameters and the operator START command have been
changed. The specifications for the swap data set definitions
have changed.
Note:
Please filoe this cover letter at the back of the manual to
provide a record of changes.

'EM Corporation, Programming Systems Publications, P.O. Box 390, Poughkeepsie, N.Y. 12602
PRINTED IN U.S.A.

File No. 8360-20
Order No. GC28-6698-3

Dm~

Systems Reference Library

IBM System/360 Operating System:
Time Sharing Option Guide

OS

Page of GC28-6698-3, Revised September 1, 1971, By TNL:

GN28-2502

Fourth Edition (June, 1971)

This is a major revision of, and obsoletes, GC28-6698-2.
Changes or additions to the text and illustrations are
indicated by a vertical line to the left of the change.

I

This edition with Technical Newsletters GN28-2497 and
GN28-2502 applies to release 20.6. of IBM System/360
Operating system, and to all subsequen't releases until
otherwise indicated in new editions or Technical Newsletters.
Changes are continually made to the information herein;
before using this publication in connection with the
operation of IBM systems. refer to the latest IBM system/360
SRL Newsletter, Order No. GN20-0360. for the editions that
are applicable and current.
Requests for copies of IBM publications should be made to
your IBM representative or to the IBM branch office serving
your locality.
A form for reader's comments in provided at the back of
this publication. If the form has been removed, comments may
be addressed to IBM Corporation, Programming systems
Publications, Department D58, PO Box 390, poughkeepsie, N. Y.
12602. Comments become the property of,IBM.

© Copyright International Business Machines Corporation 1969,1970,1971

Page of GC28-6698-3, Revised september 1, 1971, By TNL:

GN28-2502

SUMMARY OF AMENDMENTS
FOR GC28-6698-3
OS RELEASE 20.6

TSC START PARAMETERS
Programming Change
Two new parameters; TSCREGSZ and DUMP
have been added. TSCREGSZ allows an
installation to specify a size for the
TSC region.
DUMP reserves the swap
data sets so they are not initialized
during a restart.

MISCELLANEOUS CHANGES
Swap Data Sets
Swap data sets must begin on a cylinder
boundary.
Parallel data sets must
reside on the same device types.

START COMMAND
Programming Change
Most of the TSC start parameters can
be altered by the operator using the
START command~

Summary of Amendments

6.1

Page of GC28-6698-3, Revised september 1, 1971, By TNL:

• SVC 100--Submit a job to the
background.
• SVC 102--AQCTL -- used by TCAM to
communicate with problem programs.
Of these, only SVC 98--PROTECT--can be
issued by programs executing in the
background. SVCs 92 (TCB EXCP) and 101
(TCAM-TSO Communication) are used only by
supervisor programs.
Including TSO in a system adds no
restrictions to programs executed in the
background. For example, other
teleprocessing applications can be run
simultaneously.
system Control
The management of an installation can shift
most of the responsibility for controlling
the time sharing system from the operator
at the system console to users at remote
terminals, called control terminals. A
control terminal user can alter the system
configuration to meet changing work loads.
FOr instance, he can assign an extra region
of main storage to time sharing operations
during peak periods, and then release it to
be used for batch operations during slack
periods. Such changes require no shutdown
of TSO and are not noticed by the users of
other regions. EVen the starting and
stopping of TSO operations is accomplished
without shutting down the system or
affecting background operations.
Job Definition and scheduling
To the operating system, each terminal
session from LOGON to LOGOFF is one
terminal job, corresponding to a single
step batch job. The job control statements
that define a terminal job are stored in
the LOGON procedure used to begin the
session. The "EXEC" JCL statement in the
LOGON procedure identifies the program the
user wants loaded into his region for
execution. The program may be the
TSO-provided command language handler or an
installation provided application program.
An important feature of TSO is the
dynamic allocation of data sets for time
sharing users. A user may defer definition
of his data sets until he requires them.
During LOGON processing, any data sets
named on Data Definition (DD) statements in
the procedure are allocated to the terminal
job. Any data sets requiring volume
mounting by the operator, must be defined
here. The procedure also includes dynamic
DD statements (similar to a DD DU~~Y),
which reserve control block space for data

GN28-2502

sets the user may allocate during the
session. The dynamic allocation facility
allows data sets to be created, deleted,
concatenated, or separated without previous
allocation at the beginning of the job
step.
Tuning the Time Sharing System
In a time sharing system, execution time is
divided among the active foreground jobs
and background jobs in brief time slices.
A time slice must be long enough to perform
a meaningful amount of processing, but not
so long that the time between successive
slices prevents quick response to
conversational users. At the same time,
time slices cannot be so short and frequent
that system overhead for swapping and task
switching becomes excessive. Balancing
these factors depends on the number and
type of jobs the system is processing. A
solution for one job mix is not necessarily
suitable for another job mix. The TS.O time
sharing algorithms -- the formulas used to
calculate the division of time among jobs
-- are based on several Variables, most of
which can be specified by the installation
to tune the system for their particular
workload. Most of the tuning variables
such as the number of foreground regions
and the maximum nurober of users, can be set
or modified by the system operator or a
user at a control terminal whenever the
system is running. Others are specified as
parameters in SYS1.PARMLIB. These
parameters are used when the operator
starts the time sharing operations.
The time sharing algorithms are
described in detail in the "system Summary"
section of this manual. They are
implemented by a subroutine called Time
Sharing Driver.
The Driver makes decisions
about system functions such as swapping and
task switching. An installation may
experiment with other time sharing
algorithms by modifying or replacing the
driver, and specifying use of the new
Driver in the SYS1.PARMLIB parameters used
when the operator starts time sharing
operations.
Execution time may also be affected by
the choice of modules to be included in the
Link Pack Area (LPA) extension in the Time
Sharing Control task (TSC) region. The
size of the LPA extension and the amount of
main storage dynamically allocated by the
driver are major factors in determining the
size of the TSC region. The installation
may let the TSC calculate its own region
size or may specify a TSC region size,
either in the SYS1.PARMLIB or on the START
command, to compensate for additional main
storage requirements created during tuning.

Introduction

15

Monitoring System Use and
Performance
By extending the services of the system to
many concurrent users, TSO makes the
operating system more useful to more
people. However, installation management's
job of monitoring system use and
performance becomes more complex. Three
tools are provided to help management
maintain a clear picture of what the system
is doing.
system Management Facilities (SMF): The
SMF Option can be used with TSO. Both the
data collection and dynamic control
facilities are extended to the foreground
environment.
With the data collection facility,
records describing both the system
environment and individual user activity
ar.e written to the SMF data sets in a
format similar to that used for background
records. The system environment data
includes:
• Machine configuration.
• Resource status.
• Library management information.
This information is recorded whenever
time-sharing operations are started,
modified, or stopped by an operator. The
user data includes:

processing for foreground jobs just as they
do for background jobs. SMF is discussed
in detail in the publication IBM System/360
Operating system: system Management
Facilities, GC28-6712.
An additional installation exit,
separate from the SMF dynamic control
exits, is provided from the routine
handling user LOGON. This exit allows the
installation to establish its own user
verification and control procedures,
independent of those supplied with the
system. The section of this publication
Writing a Logon Pre-prompt Installation
Exits describes the parameters passed and
what actions the exit may take.
MONITOR Command: The MONITOR command
allows the operator to watch the changing
workload on the system over a period of
time. In addition to the job initiation,
data set, and volurre information formerly
available with the DISPLAY command, he can
request notification of time-sharing users
logging on and off the system. The DISPLAY
command now gives the system workload at a
particular point in ti~e, and has been
extended to include information relative to
the time-sharing environment, such as the
number of foreground regions and the number
of active terminals.
Both MONITOR and
DISPLAY, like other operator commands
concerned with the time-sharing operation,
are available to a control user at a remote
terminal as well as the system operator at
the console.

• I/O device use.
• Data set use.
• Main storage used.
• Time resident in main storage.
• Time actually spent executing.
The user data is recorded at LOGON and
LOGOFF and during a terminal session
whenever a user changes the status of his
data sets with the dynamic allocation
facility. The information on the use of
data sets is particularly useful to the
installation for controlling the use of
secondary storage in the time-sharing
environment.
The SMF dynamic control exits give the
installation access control program
information at key points during the
processing of jobs, including foreground
jobs. The step initiation and termination
exits are taken, if present, when a user
begins or ends a terminal session. These
routines can record information and control

16

Time Sharing Option Guide

(Release 20.6)

TSO Trace Program: The TSO Trace Writer
Program provides a detailed history of what
the system does over a period of time. The
Trace Program records a stream of
information that all ccmponents of the
system are continuously passing to the Time
Sharing Driver. The Driver uses this
information in its calculations of resource
allocation. When the operator starts the
Trace Program, it intercepts these event
signals and records them with a time stamp
in a data set. Typical events recorded are
"job requesting terminal input" and "swap
completed." The TSO Trace Data Set
Processor can be used at a later time to
format and print out the information
recorded by the Trace Program. The Trace
Data Set Processor can be requested to list
only those events associated with a
particular component of the system, such as
the dispatcher, or to list only those
events associated with a particular
terminal or set of terminals. Using this
information, system rranagement can
determine how well the system is responding
to the workload and make adjustments to the
tuning variables if necessary.

System Security
The need for adequate data and program
protection is increased in the time-sharing
environment, where many persons are
simultaneously using the system. The
system itself must be protected against
unauthorized users. Each user's programs
and data must be protected against

accidental destruction by other users.
Confidential data must be safeguarded
against unauthorized access.
User Verification
Any user starting a terminal session is
required to supply a user identification
recognized by the system; that is, one that

Introduction

16.1

Page of GC28-6698-3, Revised September 1, 1971, By TNL:

~he

Time sharing Control Task

rhe Time Sharing control task, as shown in
23, handles all functions affecting
the entire time sharing portion of the
5ystem. This includes responding to the
START, MODIFY, and STOP operator commands,
and handling the swapping of foreground
jobs into and out of main storage.

GN28-2502

foreground job is waiting for input from
the terminal, a swap out is scheduled
whether a channel is free or not.

~igure

When the operator enters the START
command for TSO, an initialization module
of the Time Sharing Control task is given
control. The initialization module
calculates the size of the Time Sharing
Control region that will be needed and
obtains it from the main storage management
routine of MVT. In this region, the Time
Sharing Control task builds the control
blocks and buffers the system will need,
and invokes a Region Control task for each
foreground region.

I

The installation may override the
calculated TSC region size by specifying
the size i t wants in SYS1.PARMLIB or on the
START command. This may be necessary if an
installation written driver has greater
main storage requirements than the driver
supplied w~th TSO.

MVT Control Program

Command
Time
Sharing
Control
Task
(TSC)

Figure 23.

The Time Sharing Control Task

While the time sharing system is
operating, the major function of the Time
Sharing Control task is the swapping of
foreground jobs into and out of main
storage. Swapping is handled at this level
so it can be optimized on a system~wide
basis when multiple foreground regions are
active. Whenever possible, an active job
is not quiesced for swapping out until a
channel will be free for the swap output.
But in many cases when there is nothing to
be gained by delaying, such as when a

The Time Sharing Control task maintains
an input queue and an output queue for swap
requests (one of each set if parallel
swapping is being used).
It builds a
channel program for each swap request. A
program-controlled interruption (PCI) will
occur near the end of each channel program.
When the interruption occurs, an exit
routine selects the next channel program to
execute. The exit routine inserts a
transfer to the next channel program at the
end of the current channel program. Thus
as the number of requests increases, the
swap process is carried out by a
never-ending channel program. Seek time is
minimized by attempting to swap jobs out to
the direct access area from which the last
job was swapped in, or if this is not
possible, by using the free. space closest
to the current arm position.
In determining what portion of a
foreground region to swap out, the Time
Sharing Control task uses a map of the
foreground job created by the Region
Control task. Each entry in the map
identifies the starting address and length
of a section of the region that the job is
using. The number of entries in this map
is the same for every job and is specified
by the installation in the system parameter
library. If there are too few entries,
inactive main storage must be included (and
swapped). A large number of entries cuts
down on the amount of inactive storage that
has to be swapped, but adds to processing
overhead.
When the operator enters a STOP command
to shut down the time sharing operation,
the Time Sharing Control task initiates a
logoff for each active user. When all
users are disconnected, the Time Sharing
Control task ensures that all the system
resources that had been assigned to it are
returned; the Time Sharing Control task
then terminates, returning its main storage
region to the system.
If any users cannot be logged off, the
Time Sharing Control task cannot terminate.
The operator is given the facility to
. "force" TSO to terminate even if it appears
that normal STOP processing cannot be
completed. For further information on
"forced STOP" see Messages and Codes,
message IKJ024D.

System Summary

47

The Region Control Task
A major function of the Region Control task
is quiescing and restoring foreground job
activity before and after swapping. There
is one Region Control task for each active
foreground region, invoked by the Time
Sharing Control task with an ATTACH macro
instruction. Figure 24 shows a single
Region Control task under the Time Sharing
Control task.
Before a foreground job can be swapped
out of main storage, any activity
associated with it must be brought to an
orderly halt, or set up to be handled by
some supervisor routine that will be
remaining in main storage. This includes
removing control blocks associated with the
job fLom system queues, or flagging them as
inactive.

Region
Control

Task

Figure 24.

The Region Control Task

Quiescing of I/O activity is initiated
by the Region Control task (at the request
of the Driver), which issues the Purge
supervisor Call for each task associated
with the foreground job. The Purge routine
removes I/O requests from the I/O
Supervisor's queues of pending requests if

48

Time Sharing Option Guide

(Release 20.6)

they have not yet been initiated.
If a
request has been started, that is, if data
transfer is already taking place, it is
allowed to complete before the job is
marked ready for swapping. The control
blocks associated with unstarted requests
are stored in the foreground region where
they will be swapped out of main storage
along with the job.
I/O requests that address the terminal
are an exception to the quiescing procedure
because of their long completion time.
These requests are handled through the TSO
interface with TCAM and are buffered in
supervisor main storage, not in the
foreground region. Data can be written or
read to these buffers whether the job is
present in its main storage region or not.
Many control blocks, like the I/O
requests mentioned above, reside in the
foreground region. For background jobs,
these control blocks would be created and
maintained in the System Queue Area, a
section of main storage set aside for this
purpose during nucleus initialization.
Foreground regions, however, each contain a
Local system Queue Area to hold control
blocks. As part of quiescing, the Region
Control task removes pointers to these
control blocks from system queues. The
blocks can then be swapped out of main
storage along with the foreground job. The
only control blocks for foreground jobs
that are assigned in the system Queue Area
(and remain in main storage) are requests
for timer interruptions, operator replies,
and assignment of resources through ENQ.
When a job is swapped into main storage
by the Time Sharing Control task, the
Region Control task receives control to
restore the I/O requests i t intercepted at
swap out time, and to return the control
blocks associated with the job to the
appropriate system queues.

LOGON/LOGOFF
The LOGON/LOGOFF Scheduler routine performs
the same functions for foreground jobs that
the reader/interpreter and initiator do for
background jobs. When defining a
foreground job, LOGON uses many of the same
programs as subroutines.
When LOGON is invoked by the Region
Control task, as shown in Figure 25, it is
swapped into the foreground region. A copy
of the LOGON/LOGOFF Scheduler for each
foreground region is kept in the swap data
set, reducing the amount of initialization
time needed. LOGON, and all routines below
it in the control flow diagram, execute
from the foreground region, and are swapped
in and out of main storage. LOGON first
validates the user's identification and
pa$sword in the User Attribute Data Set,
and reads in the rest of the user profile.
From the profile and any operands entered
with the LOGON command, LOGON builds, in
main storage, a JOB and an EXEC statement
that define the foreground job. The EXEC
statement names the LOGON Procedure
specified by the user, and the procedure in
turn specifies the name of the program to
be invoked. The procedure also contains DD

statements for data sets the user always
wants allocated to him, and some special DO
statements that save control block space
for data sets he may allocate later,
dynamically.

Swapped Into Foreground
Region And Attached
One Per
User

Figure 25.

Logon!
Logoff
Scheduler

The LOGON/LOGOFF Scheduler

The JOB and EXEC statements built by the
LOGON routine are passed to the
reader/interpreter to define the resources
required by the job, and then to the

System Summary

48.1

Page of GC28-6698-3, Revised september 1, 1971, By TNL:

The EXEC statement of the cataloged
)rocedure that starts the Time Sharing
:ontrol Task, specifies:
• The TSC program name, which is
IKJEATOO.
• The TSC region size. If the TSC needs
a different sized region, it will
obtain one.
• ROLL=(NO,NO) to preclude an attempt to
Rollout the TSC region, if
OPTIONS=ROLLOUT has been specified
during system generation.
• DPRTY=to set a priority for the TSO.
It must be lower than the MCP.
?ive data sets must be defined.
• SYSPARM -initiation
parameters
TSO system

The library containing TSC
parameters.
These
are discussed under nwriting
Parameters n •

• SYSUADS -- The User Attributes Data
set, this data set cannot be
concatenated.

GN28-2502

For example, if an installation has two
data sets and wants to use parallel
swapping it would use SYSWAPOO and SYSWAP01
as the ddnames.
If an installation wanted to use an IBM
2301 drum for a prime swap data set and an
IBM 2314 as overflow, the ddnames would be
SYSWAPOO for the 2301 the prime data set,
and SYSWAP10 for the 2314, the first
overflow data set. Parallel units must be
of the same device type. A swap data set
must begin on a cylinder boundary.
If a system or TSO failure causes TSO to
be restarted, you can use IMDPRDMP program
to save the swap data sets before
attempting to restart TSO. When invoking
IMDPRDMP, the DO statements for the swap
data sets should be the same as those in
the TSO cataloged procedure; the //PRINTER
DO statement writes to tape with chained
scheduling and a large blocking facto+ so
that the data sets are dumped quickly. The
publication IBM System/360 Operating
System: service Aids GC28-6719 shows the
procedures for analyzing system failures
and how to use the IMDPRDMP program to save
the swap data sets.
STARTING AND STOPPING TSO

• SYSLBC -- The broadcast data set which
contains messages from the SEND command
and a list of valid users should not be
password protected.

When the operator starts TSO for the day,
he must:
1.

Issue a START command to start the
Message Control Program. The operand
of the START command is the name of
the cataloged procedure that provides
the Job Control statements necessary
to execute the MCP. For example if
the cataloged procedure used to start
the MCP is named TCAM, the operator
will issue a START TCAM command.

2.

Issue a START command to start the
Time Sharing Control Task (TSC). The
operand of this command names a
cataloged procedure used to start the
TSC.
For example if the cataloged
procedure used to start the TSC is
named TS, the operator would issue a
START TS command.

• SYSWAPOO -- The swap data sets.
• IEFPDSI -- The partitioned data set
containing LOGON cataloged procedures.
This data set may be either
SYS1.PROCLIB or a partitioned data set
dedicated to LOGON procedures. A
dedicated data set will speed up LOGON
processing.
If an installation uses the TSO dump,
SYSTSDP, the TSO dump data set,usually a
tape volume, should also be defined.
For each of these data set definitions,
DISP=SHR should be specified.
Figure 38 shows a sample cataloged
procedure to start the TSC.
The data definition ddname on the DO
statement defining the SWAP data set
specifies whether serial or parallel
swapping is to be used. The ddname is of
the form

When the operator stops TSO for the day,
he must:
1.

Issue a STOP command to stop the Time
Sharing control Task. The operand of
the S'IOP command must be the same as
the operand that was used to start the
TSC.

2.

Issue a HALT command to stop the
Message Control Program. If the PGM=
operand of the EXEC statement in the
cataloged procedure used to start the
MCP is IEDQTCAM, then the MCP cannot

SYSWAPln
Where 1 indicates the level of the data
set, i.e., 0 for prime, 1 for first
overflow; and n is the data set number at
this level.

system Implementation

71

Page of GC28-669S-3, Revised september 1, 1971, By TNL:

GN2S-2502

r---------------------------------------------------------------------------------------,

I//IEFPROC
EXEC PGM=IKJEATOO,ROLL=(NO,NO),DPRTY=(13,13)
1
I//SYSPARM
DD DSN=SYS1.PARMLIB,DISP=SHR
1
I//SYSUADS
DD DSN=SYS1.UA~S,DISP=SHR
I
I//SYSLBC
DD DSN=SYS1.BRODCAST DISP=SHR
1
I//SYSWAPOO DD DSN=SYS1.SWAP1,DISP=SHR
I
1//SYSWAP01 DD DSN=SYS1.SWAP2,DISP=SHR
I
I//IEFPDSI
DD DSN=SYS1.PROCLIB,DISP=SHR
I
I//SYSTSDP
DD UNIT=2400,VOL=SER=TSODUMP,DISP=(,KEEP)
L
_______________________________________________________________________________________
JI
Figure 3S.

Sample Cataloged Procedure to start Time Sharing Control Task

be cancelled with a CANCEL command.
If the operator cancels the MCP, the
TSO must be stopped before the MCP is
restarted. The MCP cannot be halted
with a HALT command unless the TSO is
stopped.
DEFINING A UADS USING THE TSC PROCEDURE
When a TSO system is first started after
system generation, it is necessary to
construct a UADS using the ACCOUNT command.
The distributed UADS contains one valid
user:IBMUSER and this user is authorized to
use one procedure: IKJACCNT. He should
use the ALLOCATE command to define a new
UADS with a file name of SYSUADS and a data
set name other than SYS1.UADS, specifying
its volume serial number, and define his
UADS structure with a series of ACCOUNT
command ADD subcommands. He should then
log off, stop the system, and change the
SYSUADS DD statement in the TSC start
procedure, to point to the new UADS.
If
the cataloged procedure defines SYSUADS
though a DSN= operand, then he need only
rename the data set.
Background Reader (BRDR)
The cataloged procedure used to start the
Background Reader (BRDR) contains Job
Control statements that:

• Specify the program name of the
Background Reader.
• Pass the Background Reader standard
Reader-Interpreter parameters.
• Define required data sets.

The Background Reader, (BRDR), runs as a
system task. It is started by the
operator. It interprets Job Control
Language passed by a terminal user with the
SUBMIT command. If there is no input for
the BRDR, it will relinquish its region and
wait for input. Output from the BRDR is
placed on SYS1.SYSJOBQE and is queued for
execution by a standard initiator. The
cataloged procedure that provides the Job
Control Language to start the Background
Reader is similar to other reader
procedures. The BRDR program name is
IKJEFF40. Figure 39 shows an example of a
BRDR procedure. For further information on
writing system reader/interpreter cataloged
procedures, see IBM System/360 Operating
System: system Programmers Guide,
GC28-6550.

An installation exit can gain access to
and modify or delete any JCL passed by the
SUBMIT command processor. The section,
"Writing Installation Exits for the SUBMIT
Command" describes how to write this exit.

r---------------------------------------------------------------------------------------,
I//BRDR
EXEC PGM=IKJEFF40,
1
1//
1//

REGION=70K,
1
PARM='READERPARM'
1
I//IEFPDSI DD
DSN=SYS1.PROCLIB,
I
1//
DISP=SHR
1
I//IEFDATA DD
UNIT=SYSDA
1
1//
SPACE= (SO,(500,50),RLSE,CONTIG),
I
1//
DCB=(BUFNO=2,LRECL=80,BLKSIZE=80,DSORG=PS,
1
1//
RECFM=F,EUFL=80)
1
I//IEFRDER
DD
DUMMY
L
_______________________________________________________________________________________
J1

Figure 39.

72

sample Background Reader (BRDR) Procedure

Time Sharing Option Guide

(Release 20.6)

Page of GC28-6698-3, Revised september 1, 1971, By TNL:

• Specify the number of users.

GN28-2502

1.

What type of queueing service to use
in a region.

2.

What the cutoff points for each queue
are.

• Specify whether SMF is to be used.
• Specify which DRIVER to use.
• Limit the number of tracks the SUBMIT
command can use to queue jobs.
• Defines the module contents of the Time
Sharing Link Pack Extension.
Notes:
• All parameters except LPA and
DUMP/NODUMP may be overridden on the
START command.
• USERS, SMF, REGSIZE(n), and SUBMIT may
be changed by a MODIFY command.
• TERMAX, REGNMAX, and MAP must be
specified either in the SYS1.PARMLIB or
on the START command to start TSO.
The contents of the Time Sharing Link
Pack Area, that part of the TSC region
containing reenterable modules common to
different TSO applications has a direct
effect on system response and overhead.
The following routines are used by
different users many times during an
average session and should reduce loading
time if included.
• The I/O service routines -- that is
GETLINE, PUTLlNE, PUTGET, and STACK.
• The TMP mainline routines.
• Command Scan
a service routine used
to check the syntax of commands.
• TIME -- a routine used to get the time
of day.
• PARSE -- a routine that analyzes the
syntax of commands.
In addition if EDIT is being used
extensively, portions of the EDIT command
processor should be included.

• The Edit Mainline routines.
• INPUT subcommand processor.
• LIST subcommand processor.
• CHANGE subcommand processor.
• Implicit change processor, that is, the
update function for portions of
individual lines.

For example, the SWAPLOAD/NOSWAPLOAD
parameter specifies whether or not swap
load will be used as a criterion for
determining which queue a user will be put
in. If SWAPLOAD has been specified, the
MAXSWAP parameter defines the maximum swap
load for each queue.
In a single region system, NOWAIT and
NOACTIVITY should be specified.
The decay constant for the wait estimate
(DECAYWAIT) and the activity estimate
(DECAYACT) if set to 100, (that is, a decay
constant of one since the value is in
hundredths), will mean that the current
value has a weight equal to the total prior
value. This will nsmooth n out the effects
of excessive variations.
MINSLICE, the minimum amount of time
given to a terminal user, should be set to
allow a useful amount of execution time.
If PREEMPT is specified, CYCLES should be
set to zero, since a higher priority queue
will preempt a lower Friority queue.
Buffer Control Parameters
TSO controls the allocation of terminal
buffers in the TSC region. Buffers
allocations are based on initial parameters
specified in SYS1.PARMLIB.
The BUFSIZE= parameter specifies the
size in bytes of each TSO terminal buffer.
The BUFFERS= parameter specifies the
total number of TSO buffers. The remaining
parameters deal with allocating the number
of buffers per user when a given number of
users is logged on.
TSO maintains a count of the number of
allocated buffers per user, both for input
and output. When the number of buffers
either for input or output rises to a given
level, the user is prevented from
continuing until more buffers are
available. If the specified maximum number
of input buffers are allocated, the
keyboard is locked up. If the maximum
number of output buffers are allocated, the
user's program is put into a wait. This
level is determined by the OWAITHI value
for output and the INLOCKHI value for
input.

Driver Parameters
The DRIVER parameters specify:

When the number of logged on users
changes by the percentage specified in the
System Implementation

75

USERCHGE parameter, and when the number of
users falls below SLACK value, the number of
buffers per user is readjusted. The number
of buffers for input and output are
distributed in the same ratio as specified
by INLOCKHI and OWAITHI.
System Parameter Format
The format of the parameter records is:
parameter-owner keyword=value •••
The possible parameter-owners are:
• TS -- parameters for the Time sharing
Control Task.

76

Time Sharing Option Guide

(Release 20.6)

e

DRIVER -- parameters for the Time
Sharing Driver.

• TIOC -- parameters controlling terminal
buffer allocation.
Keywords cannot be continued but may be
repeated. This has the effect of
continuation, as repeated keyword values
are added on to those already specified.
When two parameters conflict, the last
value is used. Figure 42 shows an example
of system parameters for a single region
model 50 and for a double region model 65.
Figure 43 shows the syntax and meaning of
the start parameters.

Page of GC28-6698-3, Revised September 1, 1971, By TNL:

GN28-2502

PARAMETER
OWNER

KEYWORD

MEANING

TS

TERMAX=nnnn

Specifies the maximum number of terminals the
installation wants to support. Must be less than
10000.

REGNMAX=nn

specifies the maximum number of TSO user regions.
Must be between 1 and 14 inclusive.

MAP=nnnn

Specifies the number of entries in the User Main
storage Map for each user. Entry describes area to be
swapped. Used to reduce swapping of unused storage.

USERS=nnnn

specifies the initial maximum number of users the
system will allow to log on. Must be between 0 and
the value specified on TERMAX. If nnnn greater than
TERMAX, TERMAX value will be used.
Defaults to
TERMAX.

Standard SMF foreground parameters, See system
Management Facilities, GC28-6712.
DSPCH=cccccc

Specifies first six characters of Time Sharing Driver.
Defines names of all four driver modules.
Last two
characters must be 00 to 03. Defaults to IKJEAD, the
driver supplied with TSO.

LPA=(module list)

List of modules to be included in Time Sharing Link
Pack Extension.

REGSIZE(n)=
(nnnnnK, xxxxxK)

Specifies the time sharing region number and size of
that region. n is the region number and nnnnnK its
size. xxxxxK is size of Local system Queue Area
(LSQA). LSQA must be smaller than region size but
greater than zero. n must be between 1 and REGNMAX.
nnnnn and xxxxx are number of contiguous 1024 byte
areas wanted, should be even, and their sum may range
from 0 to 16382. Odd numbers specified will be
rounded up to next higher even number,.

SUBMIT=nnn

Specifies maximum number of tracks in SUBMIT command
job queue. Defaults to limit set at system
generation.

TSCREGSZ=nnnnnK

specifies amount of main storage ,to be allocated to
Time Sharing Control Task region.
nnnnn is number of
contiguous 1024 byte areas desired, must be even, and
may not be mOre than 16382. An odd number will be
rounded up to next higher even number.
If not
specified in either SYS1.PARMLIB or in START command,
Time Sharing Control Task will calculate its own
region size.

J

DUMP=[DUMP
NODUMP
Figure 42.

DUMP indicates that swap units are to be marked
reserved.
Necessary if a SWAP dump to betaken.

TSO system Parameter Syntax (Part 1 of 3)

System Implementation

77

PARAMETER
OWNER

KEYWORD

MEANING

DRIVER

WAIT
NOWAIT

Specifies use of wait estimate option.

Figure 42.

78

ACTIVITY
NOACTIVITY

Specifies whether Region activity estimate is to be
used in assigning a user to a region. NOACTIVITY
required for single region system.

OCCUPANCY
NOOCCUPANCY

Specifies whether core occupancy estimates are to be
used in queue selection.

SWAPLOAD
NOSWAPLOAD

Specifies whether swapload is to be used in queue
placement.

AVGSERVICE
NOAVGSERVICE

Specifies average queue service time to be

PRIORITY
NOPRIORITY

Specifies whether priority scheduling is to be used.

PREEMPT
NOPREEMPT

Specifies whether preemptive scheduling is to be used.

BACKGROUND=nn
NOBACKGROUND

Specifies a percentage of CPU time guaranteed to
the background or no guaranteed time.

DECAYWAIT=nnnn

specifies in 100ths the decay constant for the wait
estimate. Assumes WAIT specified.

DECAYACT=nnnn

Specifies in 100ths the decay constant fo~ the
activity estimate. Assumes ACTIVITY specified.

SUBQUEUES(n)=rnmm

specifies the number of queues for region n.

CYCLES (n,m)=iii

Specifies the number of service cycles to be given to
the mth queue of the nth region.

MAXSWAP=(nrm)=iii

Specifies the maximum number of 1024 byte blocks which
may be allowed to a user on queue m, in region n.
Assumes SWAPLOAD specified.

MAXOCCUPANCY(n,
m)=iii

Specifies the maximum amount of time in 100th of a
second a user on queue m in region n can reside in
core.

SERVICE (n,m)=iii

Specifies the average service time in 100ths of a
second for a user on queue m in region n.

MINSLICE(nrm)=iiii

Specifies the minimum time slice in 100th of a second
to be given to a user on queue m in region n.

TSO System Parameter Syntax (Part 2 of 3)

Time Sharing Option Guide

(Release 20.6)

~sed.

PARAMETER
OWNER

KEYWORD

MEANING

TIOC

BUFSIZE=nn

Specifies size of terminal buffer.

BUFFERS=nn

Total number of buffers.

OWAITHI=nn

Specifies maximum number of allocated output terminal
buffers per user in order to put a user program into
output wait.

INLOCKHI=nn

Specifies the maximum number of allocated input
terminal buffers per user in order to lock a users
keyboard.

OWAIT LO=nn

Specifies the number of allocated output buffers to
bring a user out of output wait state.
In other words
if OWAITLO=4, when 4 or less buffers remain allocated,
the user is brought out of output wait.

INLOCKLO=nn

specifies the number of currently allocated input
buffers to unlock the terminal keyboard for input.
other words, when the number of allocated input
buffers falls to or below the INLOCKLO value, the
user1s keyboard is unlocked.

Default 44.

In

US ERCHG=nn

Specifies percentage of change in logged on users
needed to redistribute buffers and recalculate the
OWAITHI and INLOCKHI numbers during slack time.

RESVBUF=nn

Specifies the total number of terminal buffers that
must be free to avoid locking all terminals to prevent
input.

SLACK=nn

specifies number of logged on users that constitute
slack time.

System Implementation

78.1

Storage Estimates

?he estimates included in this chapter are
Lntended for planning purposes only. None
)f these estimates have been verified, and
:hey are subject to change.
Verified
=stimates will appear in the publication
[BM System/360 Operating system: storage
Estimates, GC28-6551, when they are
3.vailable.
This chapter contains three sections:
main storage requirements, sample
configurations, and auxiliary storage
considerations. All figures in this
chapter are decimal, and nK n represents a
factor of 1024.

Main Storage Requirements
The main storage requirement for TSO is
divided into four major parts:
• An addition to the MVT basic fixed
requirement.
• The TCAM Message Control Program
requirement.
• The Time Sharing Control region
requirement.
• The foreground regions in which users'
programs are executed.
Only the first of these requirements has
any effect on the batch environment if time
sharing is not active. storage for the
TCAM, Time sharing Control, and froeground
reyions is obtained from the dynamic area
when the operator starts time-sharing
operations. This storage is returned to
the dynamic area when time sharing is
stopped, and is again available for batch
processing.
MVT BASIC FIXED REQUIREMENT
The main storage basic fixed
for an MVT system is for:
•
•
•
•

The
The
The
The

re~irement

nucleus.
Master Scheduler Region.
Link Pack Area (LPA).
System Queue Area (SQA).

Storage for the basic fixed requirement is
allocated by the Nucleus Initialization
Program (NIP) when the system is started
and does not normally vary while the system
is running.

Nucleus
Including TSO at system generation adds
approximately 3K to the size of the
resident MVT nucleus, for a total
requirement of about 45K.
In addition,
communication lines, like other I/O
devices, require 40 bytes each in the
nucleus for control blocks.
Master Scheduler Region
The master scheduler region is increased by
approxinately 4K to handle new or extended
operator commands for the time-haring
environment, and for extended error
recovery. The total requirement is about
16K.
Link Pack Area
One small TSO module is added to the
required MVT link pack area list of
resident modules. The minimum link pack
area size remains 10K. If the standard MVT
resident reenterable load module. and
resident SVC lists are used at system
generation, the LPA requirement is about
54K. If space is available, an additional
16K of SVC modules for time sharing are
appropriate for the resident list" for a
total LPA size of 70K.
Additional resident reenterable load
modules for time sharing are placed in an
extension to the link pack area allocated
in the Time Sharing Control region, and are
resident only when time sharing is active.
The size of this extension, called the Time
Sharing Link Pack Area (TSLPA), is
discussed with the Time Sharing Control
Region requirement.
System Queue Area
During time-sharing operations, use of the
system queue area is kept to a minimum by
~lacing as many control blocks as possible
1nto a local system queue area (LSQA)
defined in each foreground region. Control
blocks in the local SQA are swapped in and
out of main storage along with the
foreground job they apply to.
Some control blocks associated with
foreground jobs, such as queue elements for
named data sets and operator reply queue
elements, must remain in main storage while
the job is swapped out. Space for these
control blocks, and for all control blocks
associated with the tasks supervising the
time-sharing operation must be allocated
storage Estimates

87

Page of GC28-6698-3, Revised September 1, 1971, By TNL:

GN28-2502

from the system queue area • . These
requirements must be considered when
setting SQA size at system generation or at
nucleus initialization.

and two 2314 swap data sets, four
foreground regions, and 100 users would
require about 117K for the time sharing
control region.

MESSAGE CONTROL PROGRAM REQUIREMENT

DYNAMIC AREA REQUIREMENTS

The size of the TCAM Message Control
Program region depends largely on what
options are selected and what hardware is
present on the teleprocessing network. In
addition to the minimum requirement for the
Message Control Program routines, there are
requirements for each defined line group,
each additional terminal type, and for each
permitted user.
If teleprocessing
applications other than TSO are present,
additional routines to handle different
buffering and queuing techniques will be
needed.

The SEND operator command, like several
others already in the MVT configuration,
obtains and uses an 12K operator command
region from the dynamic area when the
operator enters it. This area is freed
when processing of the command is
completed.
When it is active, the time sharing
trace facility requires a 20R region from
the dynamic area.
FOREGROUND REGION REQUIREMENT

In a system with TSO as the only
teleprocessing application, with three
terminal types and two line groups, the
Message Control Program requirement is
expected to be about 52K plus 800 bytes for
each possible concurrent user. Although
the Message Control Program executes in a
problem program region, the region may be
smaller than the normal minimum problem
program region size (MINPART).
TIME SHARING CONTROL REGION REQUIREMENT

I

The Time Sharing Control region must
provide space for programs for the Time
Sharing Control Task, Region Control Tasks,
several resident SVC routines, the Time
Sharing Driver, the time sharing extension
to the link pack area, and various control
blocks. Some of the control blocks are
repeated for each foreground region, for
each swap data set, or for each time
sharing user. An initialization routine
brought in when the operator starts time
sharing analyzes the time-sharing
parameters supplied by the installation,
calculates the region size requirement', and
obtains the region from the dynamic area.
The installation may override the
calculated TSC region size either in
SYS1.PARMLIB or on the START command. This
may be necessary if an installation written
driver has greater main storage
requirements than the driver supplied with
TSO.
Using a buffer length of 40 bytes, and
assuming eight buffers per time-sharing
user, a TSO configuration with two IBM 2314
swap data sets, one foreground region, and
20 users would require a time sharing
control region of about 87K. A larger
configuration, with two 2301 swap data sets

88

Time Sharing Option Guide

(Release 20.6)

The foreground region contains the programs
invoked by the terminal user. Space must
be provided in the foreground region for
the local system queue area (LSQA) and for
four main storage subpools used for control
blocks for the command system.
The subpools defined are:
•
•
•
•

Subpool
Subpool
Subpool
Subpool

0-- 4K.
1--4K.
78--2K.
251--2K.

The m1n1mum foreground region size is 72K,
and all IBM-supplied command processors
except some of the language processors can
execute in this region.

AUXILIARY STORAGE REQUIREMENTS
The major additions to the system auxiliary
storage requirements for TSO are for the
swap data sets and new or larger system
libraries and data sets. The installation
must also consider the direct access
storage needs of the individual terminal
users, and make allowances for these in the
size of the system catalog and password
data sets.
SWAP DATA SETS
A swap data set is divided into swap
allocation units, each of which consists of
a device-dependent number of 2K records.
To avoid space fragmentation, space in the
swap data set is always assigned in
integral swap allocation units. Figure 47
shows the sizes of allocation units for
various swap devices.



Source Exif Data:
File Type                       : PDF
File Type Extension             : pdf
MIME Type                       : application/pdf
PDF Version                     : 1.3
Linearized                      : No
XMP Toolkit                     : Adobe XMP Core 4.2.1-c043 52.372728, 2009/01/18-15:56:37
Create Date                     : 2012:06:13 15:17:11-08:00
Modify Date                     : 2012:06:13 20:11:23-07:00
Metadata Date                   : 2012:06:13 20:11:23-07:00
Producer                        : Adobe Acrobat 9.51 Paper Capture Plug-in
Format                          : application/pdf
Document ID                     : uuid:8aa34262-1429-4fad-8d34-7aaaf896046a
Instance ID                     : uuid:cbbb6db0-186c-433d-b7ec-cd68c8f15012
Page Layout                     : SinglePage
Page Mode                       : UseNone
Page Count                      : 202
EXIF Metadata provided by EXIF.tools

Navigation menu