HP MPE-iX Getting Started Guide

900 Series HP 3000 Computer Systems
Getting Started as an
MPE/iX Programmer
Programmer's Guide
ABCDE
HP Part No. 32650-90008
Printed in U.S.A. 1992
Second Edition
The information contained in this document is sub ject to change
without notice.
Hewlett-Packard makes no warrantyofany kind with regard to this
material, including, but not limited to, the implied w
merchantability or tness for a particular purpose. Hewlett-P
shall not be liable for errors con
special, incidental or consequential damages in connection with the
furnishing or use of this material.
Hewlett-Packard assumes no responsibility for the use or reliability of
its software on equipment that is not furnished by Hewlett-Packard.
This document contains proprietary information which is protected
by copyright. All rights are reserved. Reproduction, adaptation, or
translation without prior written permission is prohibited, except as
allowed under the copyrightlaws.
c
Copyright
Use, duplication, or disclosure by the U.S. Government is sub ject
to restrictions as set forth in subparagraph (c) (1) (ii) of the
Rights in Technical Data and Computer Software clause at DFARS
252.227-7013. Rights for non-DoD U.S. Government Departments and
agencies are as set forth in FAR 52.227-19 (c) (1,2).
tained herein or for direct, indirect,
1992 by Hewlett-Packard Company
arranties of
ackard
Hewlett-Packard Company
3000 Hanover Street
Palo Alto, CA 94304 U.S.A.
Restricted Rights Legend
Printing History
The following table lists the prin
dates for each edition. The softw
at the time this documen
document. Therefore, do not expect a one-to-one corresp ondence bet
and document editions.
Edition Date Software Version
First Edition November 1987 A.01.00
Update 1 July 1988 A.10.00
Update 2 December 1988 A.20.00
Second Edition June 1992 B.40.00
twas issued. Many product releases do not require c
tings of this documen
are version indicates the version of the softw
t, together with the respectiv
ween product releases
e release
are product
hanges to the
iii
iv

Preface

Note
MPE/iX, Multiprogramming Executive with Integrated POSIX, is the latest
in a series of forward-compatible operating systems for the HP 3000 line of
computers.
In HP do cumentation and in talking with HP 3000 users, y
ou will encounter
references to MPE XL, the direct predecessor of MPE/iX. MPE/iX
is a sup erset of MPE XL. All programs written for MPE XL will run
without change under MPE/iX You can continue to use MPE XL system
documentation, although it may not refer to features added to the op erating
system to support POSIX (for example, hierarc
Finally,you may encounter references to MPE V, whic
system for HP 3000s, not based on P
can be run on the P
compatibility mode
A-RISC (Series 900) HP 3000s in what is kno
.
Getting Started as an MPE/iX Programmer
A-RISC architecture. MPE V softw
is a manual designed to introduce a programmer
hical directories).
h is the operating
wn as
to the Hewlett-Packard MPE/iX operating system, which runs on 900 Series HP 3000
computers. It provides:
An overview of the op erating system architecture, features, and facilities, explaining the
concepts necessary for a programmer to obtain a working knowledge of the system.
References to other manuals for detailed information, syntax, and advanced concepts.
are
As a prerequisite, you should review the self-paced training course
Advanced Skills
Getting Started as an MPE/iX Programmer
consists of the
(32650-60039).
is part of the Programmer's Series. This series
MPE/iX Intrinsics Reference Manual
(32650-90028) and a set of task-oriented
HP 3000 Series 900
user's guides.
How to Use this Manual
If you are new to the subject of programming on the MPE/iX operating system, y
read chapter 1 rst. If you are familiar with MPE/iX, turn directly to the c
hapter that
contains the information you need.
For information on additional programming manuals refer to the
Guide
(32650-90144).
MPE/iX Documentation
ou should
v
Organization of this Manual
The guide contains the following chapters:
Chapter 1 Overview
covers the basics of programming on MPE/iX. It in
900 Series HP 3000, HP-P
describes the following topics on a high lev
programming purposes: MPE/iX operating system features and
fundamentals, user interface, accounting structure, migration from the MPE
V/E operating system, and data con
Chapter 2 Utilities and Tools
covers programmatic access to the MPE/iX Command
Interpreter and many other MPE/iX subsystems and utilities.
Chapter 3 Program Development
running a program on MPE/iX. It discusses the m
environment, error detection, and control co des.
Chapter 4 Link Editor
covers HP Link Editor/XL, whic
used to bring pieces of code together in
maintain libraries of sharable code.
Chapter 5 Optimizing a Program
improves program performance.
Chapter 6 File System
describes the MPE/iX File System, including le and record
structure, File System services, le specications, le domains, data
transfer, and le security.
Chapter 7 Data Management
covers data management concepts and subsystems on
MPE/iX, including KSAM, ALLBASE/SQL, TurboIMAGE, and QUERY.
troduces the
A architecture, and MPE operating systems. It
el, suitable for management and
version from MPE V/E.
covers writing, compiling, linking, loading, and
ultiprogramming
h is a subsystem of MPE/iX
to executable program les and
covers the Optimizer subsystem of MPE/iX, which
vi
Conventions
UPPERCASE
In a syntax statement, commands and keywords are shown in
uppercase characters. The characters must b e entered in the order
shown; however, you can enter the characters in either upp ercase or
lowercase. For example:
COMMAND
can be entered as any of the following:
command Command COMMAND
It cannot, however, b e en
tered as:
comm com_mand comamnd
italics
In a syntax statement or an example, a w
ord in italics represents a
parameter or argument that you must replace with the actual v
In the following example, you must replace
lename
with the name
alue.
of the le:
bold italics
COMMAND
In a syntax statement, a word in bold italics represents a parameter
lename
that you must replace with the actual value. In the following
example, you must replace
COMMAND(
lename
)
lename
with the name of the le:
punctuation In a syntax statement, punctuation characters (other than brackets,
braces, vertical bars, and ellipses) must be entered exactly as shown.
In the following example, the parentheses and colon must be entered:
(
lename
):(
lename
)
underlining Within an example that contains interactive dialog, user input and
user responses to prompts are indicated by underlining. In the
following example, yes is the user's response to the prompt:
Do you want to continue? >> yes
{ }
In a syntax statement, braces enclose required elements. When
several elements are stacked within braces, you must select one. In
[ ]
the following example, you must select eitherONor
COMMAND
ON
OFF
In a syntax statement, brackets enclose optional elements. In the
following example,
COMMAND
OPTION
lename
can be omitted:
[OPTION]
OFF
:
When several elements are stacked within brackets, you can select
one or none of the elements. In the following example, you can select
OPTIONorparameter
COMMAND
lename
or neither. The elements cannot be repeated.
OPTION
parameter
vii
Conventions (continued)
[
...
]
In a syntax statement, horizontal ellipses enclosed in brackets
indicate that you can repeatedly select the elemen
within the immediately preceding pair of brac
example below, you can select
instance of
[,
parameter
parameter
][...]
parameter
must b e preceded b
t(s) that appear
kets or braces. In the
zero or more times. Eac
y a comma:
h
In the example b elo
parameter
of
parameter
[
|
...
|
In a syntax statement, horizontal ellipses enclosed in v
is repeated; no comma is used before the rst o ccurrence
:
parameter
indicate that you can select more than one elemen
w, you only use the comma as a delimiter if
][,...]
ertical bars
t within the
immediately preceding pair of brackets or braces. However, each
particular element can only be selected once. In the follo
example, you must select
A, AB, BA
,orB. The elements cannot be
wing
repeated.
A
|
...
B
|
... In an example, horizontal or vertical ellipses indicate where p ortions
of an example have been omitted.
1
In a syntax statement, the space symbol1shows a required blank.
In the follo wing example,
parameter
and
parameter
must b e
separated with a blank:
(
4 5
parameter
The symbol
4
RETURN
)1(
parameter
4 5
indicates a key on the keyboard. For example,
5
represents the carriage return key or
)
4
Shift
5
represents the
shift key.
viii
4
CTRL
5
character
4
CTRL
5
character
indicates a control character. For example,
4
CTRL
5
means that you press the control key and the Y key simultaneously.
Y

Contents

1. OVERVIEW
Introduction to the HP 3000
900 Series HP 3000 . . . . . . . . . . . . . . . . . . . . . . . . . 1-1
HP Precision Architecture (HP-PA) . . . . . . . . . . . . . . . . . . 1-1
MPE Operating Systems .
MPE/iX and MPE V/E Op erating Systems
Naming Conventions for HP 3000 Systems and Soft
Native Mode and Compatibilit
MPE/iX Mixed Mo des . . . . . . . . . . . . . . . . . . . . . . . 1-5
900 Series Migration . . . . . . . . . . . . . . . . . . . . . . . . . . 1-5
Object Code Translator . . . . . . . . . . . . . . . . . . . . . . . 1-6
Native Mode Compilers . . . . . . . . . . . . . . . . . . . . . . . 1-6
Data Base Manipulations . . . . . . . . . . . . . . . . . . . . . . 1-6
Migration Restrictions . . . . . . . . . . . . . . . . . . . . . . . . 1-6
Cross-family Application Development. . . . . . . . . . . . . . . . . 1-7
MPE/iX Features . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-7
Multiprogramming . . . . . . . . . . . . . . . . . . . . . . . . . 1-8
Interactive and Batch Processing . . . . . . . . . . . . . . . . . . . 1-8
MPE/iX Information Management . . . . . . . . . . . . . . . . . . . 1-8
Self-adjusting System Tables . . . . . . . . . . . . . . . . . . . . . 1-9
On-line Diagnostics for Peripherals . . . . . . . . . . . . . . . . . . 1-9
Disc Failure Tolerance . . . . . . . . . . . . . . . . . . . . . . . . 1-9
Automatic Power Fail Recovery . . . . . . . . . . . . . . . . . . . . 1-9
MPE/iX Transaction ManagementFacility. . . . . . . . . . . . . . . . 1-10
Transaction Locking . . . . . . . . . . . . . . . . . . . . . . . . . 1-10
Transaction Logging and Recovery . . . . . . . . . . . . . . . . . . 1-10
Simplifying a Program . . . . . . . . . . . . . . . . . . . . . . . . 1-11
DEBUG . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-11
MPE/iX User Interface . . . . . . . . . . . . . . . . . . . . . . . . 1-12
MPE/iX System Performance . . . . . . . . . . . . . . . . . . . . . 1-13
Mapped Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-13
Directory Entries . . . . . . . . . . . . . . . . . . . . . . . . . . 1-14
Native Mode System Comp onents . . . . . . . . . . . . . . . . . . . . 1-14
Terminal Keyboard Layouts . . . . . . . . . . . . . . . . . . . . . . 1-15
Giving Commands to MPE/iX . . . . . . . . . . . . . . . . . . . . . 1-16
MPE/iX Commands . . . . . . . . . . . . . . . . . . . . . . . . 1-16
MPE/iX Command Parameters . . . . . . . . . . . . . . . . . . . 1-17
Continuing an MPE/iX Command to Another Line . . . . . . . . . . 1-18
On-line Help in Using an MPE/iX Command . . . . . . . . . . . . . 1-18
Correcting or Mo difying an MPE/iX Command . . . . . . . . . . . . 1-18
Referring to Several Files at Once . . . . . . . . . . . . . . . . . . 1-18
Command Files and User-dened Command Files . . . . . . . . . . . . 1-19
. . . . . . . . . . . . . . . . . . . . . . 1-1
. . . . . . . . . . . . . . . . . . . . . . . 1-2
. . . . . . . . . . . . . . 1-3
ware . . . . . . . . . 1-4
yMode . . . . . . . . . . . . . . . . . 1-5
Contents-1
Break Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-21
Echo On/O . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-23
Accounting Structure Overview . . . . . . . . . . . . . . . . . . . . . 1-23
Logon and Logo . . . . . . . . . . . . . . . . . . . . . . . . . . 1-23
Account . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-23
User . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-24
Group . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-25
File Specications . . . . . . . . . . . . . . . . . . . . . . . . . . 1-26
Referring to a File in a Dieren
Referring to a File in a Dieren
t Group . . . . . . . . . . . . . . . 1-27
t Account . . . . . . . . . . . . . . 1-27
Session and Batch Mo des . . . . . . . . . . . . . . . . . . . . . . . 1-27
Converting Data Files from MPE V/E to MPE/iX
. . . . . . . . . . . . 1-29
Data Alignment Dierences . . . . . . . . . . . . . . . . . . . . . 1-29
Converting Files . . . . . . . . . . . . . . . . . . . . . . . . . . 1-32
Data Communications . . . . . . . . . . . . . . . . . . . . . . . . . 1-33
Network File Transfer (NFT) . . . . . . . . . . . . . . . . . . . . . 1-33
Remote Process Management (RPM) . . . . . . . . . . . . . . . . . 1-33
Local Area Network (LAN) . . . . . . . . . . . . . . . . . . . . . 1-34
Remote File Access . . . . . . . . . . . . . . . . . . . . . . . . . 1-34
Remote Terminal Access . . . . . . . . . . . . . . . . . . . . . . . 1-34
Remote Data Base Access . . . . . . . . . . . . . . . . . . . . . . 1-34
2. Utilities and Tools
Programmatic Access to the Command Interpreter . . . . . . . . . . . . 2-1
Concatenating Strings and String Substitution . . . . . . . . . . . . . 2-2
Expression Evaluation . . . . . . . . . . . . . . . . . . . . . . . . 2-2
Using Job Control Words (JCWs) . . . . . . . . . . . . . . . . . . . 2-2
Job Control Word Name and Type . . . . . . . . . . . . . . . . . 2-2
Changing the Value of a JCW . . . . . . . . . . . . . . . . . . . 2-2
JCW and CIERROR . . . . . . . . . . . . . . . . . . . . . . . 2-3
Reserved-word Prexes . . . . . . . . . . . . . . . . . . . . . . 2-3
Help Facility . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-3
Toolset/XL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-4
Useful Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-5
Forms Design and Screen Handling Tools . . . . . . . . . . . . . . . 2-5
Source Data Entry . . . . . . . . . . . . . . . . . . . . . . . . 2-5
Transaction Pro cessing . . . . . . . . . . . . . . . . . . . . . . 2-5
VPLUS/V Features . . . . . . . . . . . . . . . . . . . . . . . . 2-5
Report Generation Tools . . . . . . . . . . . . . . . . . . . . . . . 2-6
Business Report Writer/XL . . . . . . . . . . . . . . . . . . . . 2-6
Report/V . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-6
HP Visor . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-6
System Dictionary/XL . . . . . . . . . . . . . . . . . . . . . . . . 2-7
Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-8
SORT-MERGE/XL . . . . . . . . . . . . . . . . . . . . . . . . . . 2-9
Key . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-9
Ordering Sequence . . . . . . . . . . . . . . . . . . . . . . . . . 2-9
Collating Sequence . . . . . . . . . . . . . . . . . . . . . . . . . 2-9
DISCFREE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-10
FCOPY/XL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-10
Contents-2
3. Program Development
Writing a Program . . . . . . . . . . . . . . . . . . . . . . . . . . 3-2
How to Use Intrinsics . . . . . . . . . . . . . . . . . . . . . . . . 3-2
Compiling a Program . . . . . . . . . . . . . . . . . . . . . . . . . 3-3
Compiler Input . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-3
Compiler Output . . . . . . . . . . . . . . . . . . . . . . . . . . 3-4
Compiler Operation .
. . . . . . . . . . . . . . . . . . . . . . . . 3-4
Compiled Co de . . . . . . . . . . . . . . . . . . . . . . . . . . 3-6
Data Variables Information . . . . . . . . . . . . . . . . . . . . . 3-6
Unresolved References . . . . . . . . . . . . . . . . . . . . . . . 3-6
Compiler Libraries . . . . . . . . . . . . . . . . . . . . . . . . 3-6
Command to Compile Only . . . . . . . . . . . . . . . . . . . . 3-6
Compiler Control . . . . . . . . . . . . . . . . . . . . . . . . . 3-7
Linking a Program . . . . . . . . . . . . . . . . . . . . . . . . . . 3-7
Creating Executable Program Files . . . . . . . . . . . . . . . . . . 3-9
Symbol Listing . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-9
Loading and Running a Program
. . . . . . . . . . . . . . . . . . . . 3-13
Program Auxiliary Header . . . . . . . . . . . . . . . . . . . . . . 3-13
Using Executable Libraries . . . . . . . . . . . . . . . . . . . . . . 3-14
Searching Executable Libraries . . . . . . . . . . . . . . . . . . . . 3-14
UNSAT Procedure . . . . . . . . . . . . . . . . . . . . . . . . . 3-14
System Libraries . . . . . . . . . . . . . . . . . . . . . . . . . . 3-15
Mixing Execution Mo des . . . . . . . . . . . . . . . . . . . . . . . 3-15
Virtual Memory and Demand Paging . . . . . . . . . . . . . . . . . 3-16
LMAP: Load MAP . . . . . . . . . . . . . . . . . . . . . . . . . 3-16
Load-time Binding Sequence . . . . . . . . . . . . . . . . . . . . . 3-16
Running a Program . . . . . . . . . . . . . . . . . . . . . . . . . 3-16
Multi-programming Environment . . . . . . . . . . . . . . . . . . . . 3-17
Priority Levels . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-17
Linear Subqueues . . . . . . . . . . . . . . . . . . . . . . . . . 3-17
Circular Subqueues . . . . . . . . . . . . . . . . . . . . . . . . 3-18
Error Detection . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-18
Command Interpreter Errors . . . . . . . . . . . . . . . . . . . . . 3-18
File System Errors . . . . . . . . . . . . . . . . . . . . . . . . . 3-18
Compiler, Link Editor, and Loader Errors . . . . . . . . . . . . . . . 3-18
Run-time Errors . . . . . . . . . . . . . . . . . . . . . . . . . . 3-19
Abort Message Information . . . . . . . . . . . . . . . . . . . . . 3-19
Typical Causes of Program Ab orts . . . . . . . . . . . . . . . . . . 3-20
File Information Display (Tombstone) . . . . . . . . . . . . . . . . . 3-20
Control Codes (JCWs) . . . . . . . . . . . . . . . . . . . . . . . . 3-21
System JCW . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-21
JCW Notation . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-22
Using a System JCW . . . . . . . . . . . . . . . . . . . . . . . . 3-23
User-dened JCWs . . . . . . . . . . . . . . . . . . . . . . . . . 3-24
Using a User-dened JCW . . . . . . . . . . . . . . . . . . . . . . 3-24
Contents-3
4. HP Link Editor/XL
Common Uses of HP Link Editor/XL
Linking a Relocatable Object File .
Comparison of HP Link Editor/XL and MPE V/E Segmen
How HP Link Editor/XL W
orks . . . . . . . . . . . . . . . . . . . . 4-4
. . . . . . . . . . . . . . . . . . 4-3
. . . . . . . . . . . . . . . . . . . 4-3
ter . . . . . . . 4-4
Files Used by HP Link Editor/XL . . . . . . . . . . . . . . . . . . . . 4-4
HP Link Editor/XL Commands .
. . . . . . . . . . . . . . . . . . . . 4-6
Case Sensitivity. . . . . . . . . . . . . . . . . . . . . . . . . . . 4-7
Keyword and Positional Parameters . . . . . . . . . . . . . . . . . . 4-7
Using an Indirect File . . . . . . . . . . . . . . . . . . . . . . . . . 4-7
Starting and Ending HP Link Editor/XL
Creating an Executable Program File
Comparison of Executable and Relocatable Libraries
Using a Relocatable Library
. . . . . . . . . . . . . . . . . . . . . . 4-12
. . . . . . . . . . . . . . . . 4-8
. . . . . . . . . . . . . . . . . . 4-9
. . . . . . . . . . . 4-11
Using an Executable Library . . . . . . . . . . . . . . . . . . . . . . 4-13
5. Optimizing a Program
Optimizer Levels . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-2
Use of MPE/iX Optimizer with Languages . . . . . . . . . . . . . . . . 5-3
Optimizer Assumptions . . . . . . . . . . . . . . . . . . . . . . . . 5-3
Coding for Performance and Optimization . . . . . . . . . . . . . . . . 5-4
Reduce Aliasing . . . . . . . . . . . . . . . . . . . . . . . . . . 5-4
Use Optimal Data Types . . . . . . . . . . . . . . . . . . . . . . . 5-4
Eliminate Common Subexpressions . . . . . . . . . . . . . . . . . . 5-5
Instructions Required for Operations on Simple Data T
ypes . . . . . . . 5-6
Optimize Arrays . . . . . . . . . . . . . . . . . . . . . . . . . . 5-6
Reduce Pro cedure Calls . . . . . . . . . . . . . . . . . . . . . . . 5-7
Expand Small Pro cedures In-line . . . . . . . . . . . . . . . . . . . 5-7
Extract Procedure Calls from Loops . . . . . . . . . . . . . . . . . . 5-8
Avoid Non-native Alignment . . . . . . . . . . . . . . . . . . . . . 5-8
Optimize HP COBOL II/XL Data Types . . . . . . . . . . . . . . . 5-9
Optimize HP COBOL II/XL Data Types . . . . . . . . . . . . . . . 5-9
6. File System
Records and Files in the File System . . . . . . . . . . . . . . . . . . 6-2
Device Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-2
Disc Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-3
Disc File Storage . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-4
File Directory Structure . . . . . . . . . . . . . . . . . . . . . . . . 6-5
Domains . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-5
File Specications . . . . . . . . . . . . . . . . . . . . . . . . . . 6-8
File Designators . . . . . . . . . . . . . . . . . . . . . . . . . . 6-9
User-dened Files . . . . . . . . . . . . . . . . . . . . . . . . . . 6-11
System Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-12
Contents-4
NEW Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-7
TEMP Files . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-7
PERMANENT Files . . . . . . . . . . . . . . . . . . . . . . . 6-7
Eect of File Domain on Operations . . . . . . . . . . . . . . . . . 6-7
Changing Domains . . . . . . . . . . . . . . . . . . . . . . . . 6-8
Backreferencing a File . . . . . . . . . . . . . . . . . . . . . . . 6-10
File Classes . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-11
Input/Output Sets . . . . . . . . . . . . . . . . . . . . . . . . . 6-14
Passed Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-15
Searching File Directories . . . . . . . . . . . . . . . . . . . . . . 6-16
Finding Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-16
Types of Operations Allow
ed on Files . . . . . . . . . . . . . . . . . 6-16
Opening a File . . . . . . . . . . . . . . . . . . . . . . . . . . 6-16
Closing a File . . . . . . . . . . . . . . . . . . . . . . . . . . 6-17
Using Files at Run Time .
. . . . . . . . . . . . . . . . . . . . . . . 6-20
Hierarchy of File Overrides . . . . . . . . . . . . . . . . . . . . . . . 6-21
Record Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-22
Storage Format . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-22
Record Types . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-22
Specifying a Record Size .
. . . . . . . . . . . . . . . . . . . . . . 6-24
File Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-25
File Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-25
File Codes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-26
Creating a File . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-27
HPFOPEN and FOPEN Intrinsics . . . . . . . . . . . . . . . . . 6-27
The :BUILD Command . . . . . . . . . . . . . . . . . . . . . . 6-28
Deleting Files . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-28
Renaming Files . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-28
Saving Temporary Files . . . . . . . . . . . . . . . . . . . . . . . 6-28
Listing File Characteristics . . . . . . . . . . . . . . . . . . . . . . 6-29
The :FILE Command . . . . . . . . . . . . . . . . . . . . . . . . 6-29
Record Selection and Data Transfer . . . . . . . . . . . . . . . . . . . 6-30
Record Pointers . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-30
Pointer Initialization . . . . . . . . . . . . . . . . . . . . . . . . 6-30
Record Selection . . . . . . . . . . . . . . . . . . . . . . . . . . 6-30
Mapped Access to Disc Files . . . . . . . . . . . . . . . . . . . . . 6-31
Multiple Record Transfers . . . . . . . . . . . . . . . . . . . . . . 6-31
Data Transfer Control Operations . . . . . . . . . . . . . . . . . . . 6-32
Reading from a File . . . . . . . . . . . . . . . . . . . . . . . . . 6-32
Writing to a File . . . . . . . . . . . . . . . . . . . . . . . . . . 6-33
Updating a File . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-33
Using Mapped Access to a File . . . . . . . . . . . . . . . . . . . . 6-34
Device File Buers . . . . . . . . . . . . . . . . . . . . . . . . . 6-34
Sharing a File . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-35
Maintaining File Security . . . . . . . . . . . . . . . . . . . . . . . 6-37
Lockwords . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-38
MPE/iX File Access System . . . . . . . . . . . . . . . . . . . . . 6-38
Specifying and Restricting File Access by Access Mo de . . . . . . . . 6-38
Specifying File Access byType or User . . . . . . . . . . . . . . . 6-39
Access Control Denitions (ACDs) . . . . . . . . . . . . . . . . . . 6-42
Specifying and Restricting File Access . . . . . . . . . . . . . . . . 6-42
Managing ACDs with Commands and Intrinsics . . . . . . . . . . . 6-42
Changing Disc File Security Provisions . . . . . . . . . . . . . . . 6-43
Suspending and Restoring Security Provisions . . . . . . . . . . . . 6-44
Contents-5
7. Data Management
Data Management Subsystems . . . . . . . . . . . . . . . . . . . . . 7-1
KSAM/V . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-2
FCOPY (KSAM Options) . . . . . . . . . . . . . . . . . . . . . . 7-3
KSAM procedures . . . . . . . . . . . . . . . . . . . . . . . . . 7-5
ALLBASE/SQL . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-6
HP SQL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-6
Security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-7
Logical Transaction . . . . . . . . . . . . . . . . . . . . . . . . . 7-7
Concurrency . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-8
Recovery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-8
Database Creation . . . . . . . . . . . . . . . . . . . . . . . . . 7-8
Database Restructuring . . . . . . . . . . . . . . . . . . . . . . . 7-9
TurboIMAGE/XL Data Base . . . . . . . . . . . . . . . . . . . . . . 7-11
Master Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-12
Chain Head . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-12
Automatic Master Set . . . . . . . . . . . . . . . . . . . . . . . 7-13
Manual Master Set . . . . . . . . . . . . . . . . . . . . . . . . 7-13
TurboIMAGE/XL and QUERY/V . . . . . . . . . . . . . . . . . . . 7-14
Creating a Schema . . . . . . . . . . . . . . . . . . . . . . . . . 7-14
Creating a Ro ot File . . . . . . . . . . . . . . . . . . . . . . . 7-14
DBUTIL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-15
Creating a Data Base . . . . . . . . . . . . . . . . . . . . . . . 7-16
TurboIMAGE/XL Pro cedures . . . . . . . . . . . . . . . . . . . . 7-16
Backing Up or Restructuring a Data Base . . . . . . . . . . . . . . 7-17
Changing an Existing Data Base Design . . . . . . . . . . . . . . . 7-17
Recovering a Data Base . . . . . . . . . . . . . . . . . . . . . . 7-18
QUERY/V . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-18
TurboIMAGE DBchange/V . . . . . . . . . . . . . . . . . . . . . . 7-20
Key DBchange/V Features . . . . . . . . . . . . . . . . . . . . . . 7-20
DICTDBA . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-21
DICTDBU . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-21
DICTDBL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-21
Index
Contents-6
Figures
1-1. MPE/iX On-line Access Capabilities . . . . . . . . . . . . . . . . . 1-2
1-2. 900 Series HP 3000 High-lev
el Tools . . . . . . . . . . . . . . . . . . 1-3
1-3. HP 3000 Software Naming Conventions Example . . . . . . . . . . . . 1-4
1-4. Commanding MPE/iX . . . . . . . . . . . . . . . . . . . . . . . . 1-16
1-5. UDC File Example . . . . . . . . . . . . . . . . . . . . . . . . . 1-20
1-6. Accounts Example . . . . . . . . . . . . . . . . . . . . . . . . . 1-24
1-7. User Example . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-25
1-8. Groups Example . . . . . . . . . . . . . . . . . . . . . . . . . . 1-26
1-9. Session and Job Commands
1-10. Session and Job Characteristics .
. . . . . . . . . . . . . . . . . . . . . 1-28
. . . . . . . . . . . . . . . . . . . 1-28
1-11. HP FORTRAN 77/iX COMMON Block Data Alignment Example . . . . 1-30
1-12. IEEE Single-precision Real Number Format . . . . . . . . . . . . . . 1-31
1-13. IEEE Double-precision Real Number Format . . . . . . . . . . . . . . 1-32
3-1. MPE/iX Program Development. . . . . . . . . . . . . . . . . . . . 3-1
3-2. Compiler Producing Relocatable Ob ject Mo dules
. . . . . . . . . . . . 3-5
3-3. Linking and Using User Libraries . . . . . . . . . . . . . . . . . . . 3-8
3-4. UNSAT Procedure Example . . . . . . . . . . . . . . . . . . . . . 3-15
3-5. Job Control Word (JCW) Structure . . . . . . . . . . . . . . . . . . 3-21
3-6. JCW Notation Examples . . . . . . . . . . . . . . . . . . . . . . 3-23
4-1. :LINK and HP Link Editor/XL on MPE/iX
. . . . . . . . . . . . . . 4-2
4-2. Files Used by HP Link Editor/XL . . . . . . . . . . . . . . . . . . . 4-5
4-3. Creating an Executable Program File . . . . . . . . . . . . . . . . . 4-9
4-4. Linking to Create an Executable Program File
. . . . . . . . . . . . . 4-10
4-5. Executable Program File Commands . . . . . . . . . . . . . . . . . 4-11
5-1. Reducing Aliasing . . . . . . . . . . . . . . . . . . . . . . . . . . 5-4
5-2. Eliminating Common Subexpressions . . . . . . . . . . . . . . . . . 5-5
5-3. Instructions Operations on Simple Data Types . . . . . . . . . . . . . 5-6
5-4. Optimizing Arrays . . . . . . . . . . . . . . . . . . . . . . . . . 5-6
5-5. Reducing Procedure Calls . . . . . . . . . . . . . . . . . . . . . . 5-7
5-6. Expanding Small Pro cedures In-line . . . . . . . . . . . . . . . . . . 5-7
5-7. Extracting Calls from Loops . . . . . . . . . . . . . . . . . . . . . 5-8
5-8. Avoiding Non-native Alignment. . . . . . . . . . . . . . . . . . . . 5-8
6-1. File System Interface . . . . . . . . . . . . . . . . . . . . . . . . 6-1
6-2. Records and Files Relationship . . . . . . . . . . . . . . . . . . . . 6-2
6-3. Specifying Device File Characteristics . . . . . . . . . . . . . . . . . 6-3
6-4. Identifying a Disc File using File Designators . . . . . . . . . . . . . . 6-10
6-5. Backreferencing a Previously Identied File . . . . . . . . . . . . . . 6-11
6-6. System Files in Use . . . . . . . . . . . . . . . . . . . . . . . . . 6-13
6-7. Using a System File . . . . . . . . . . . . . . . . . . . . . . . . . 6-14
6-8. Passing Files between Program Runs . . . . . . . . . . . . . . . . . 6-15
6-9. Directories Searched Based on File Domain . . . . . . . . . . . . . . . 6-19
6-10. Nested HPFOPEN/FOPEN and FCLOSE Pairs . . . . . . . . . . . . 6-20
Contents-7
6-11. File System HierarchyofOv
6-12. Record Types . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-23
6-13. Odd-byte Record Sizes . . . . . . . . . . . . . . . . . . . . . . . . 6-25
6-14. Creating a File . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-27
6-15. Actions Resulting from Multiaccess of Files
6-16. Security Level for File Access .
7-1. Building a KSAM File .
7-2. Loading a KSAM File .
7-3. Reorganizing a KSAM File .
7-4. TurboIMAGE/XL Data Set Organization Example
7-5. Example of Creating a Ro ot File
7-6. Creating a Data Base
errides . . . . . . . . . . . . . . . . . . 6-21
. . . . . . . . . . . . . . 6-37
. . . . . . . . . . . . . . . . . . . . 6-40
. . . . . . . . . . . . . . . . . . . . . . . 7-2
. . . . . . . . . . . . . . . . . . . . . . . 7-4
. . . . . . . . . . . . . . . . . . . . . 7-5
. . . . . . . . . . . 7-13
. . . . . . . . . . . . . . . . . . . 7-15
. . . . . . . . . . . . . . . . . . . . . . . . 7-16
Contents-8
Tables
1-1. Word and Integer Conversions . . . . . . . . . . . . . . . . . . . . 1-31
6-1. New, Temporary, and Permanent File Features . . . . . . . . . . . . . 6-6
6-2. Valid File Domains . . . . . . . . . . . . . . . . . . . . . . . . . 6-6
6-3. Input Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-14
6-4. Output Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-15
6-5. Comparison of Logical Record F
6-6. Standard Default Record Sizes
6-7. File Sharing Restriction Options . . . . . . . . . . . . . . . . . . . 6-36
6-8. File Access Mo de T
6-9. User Type Denitions . . . . . . . . . . . . . . . . . . . . . . . . 6-40
7-1. ALLBASE/SQL Specications . . . . . . . . . . . . . . . . . . . . 7-10
7-2. Data Base Terminology . . . . . . . . . . . . . . . . . . . . . . . 7-11
7-3. Data Management Considerations . . . . . . . . . . . . . . . . . . . 7-19
ypes . . . . . . . . . . . . . . . . . . . . . . . 6-39
ormats . . . . . . . . . . . . . . . . 6-24
. . . . . . . . . . . . . . . . . . . . 6-24
Contents-9
1

OVERVIEW

This chapter introduces the 900 Series HP 3000 and the MPE/iX operating system, describing
how they t into the HP 3000 family of computers and MPE operating systems, in general.
It describes hardw
are and software naming conventions and provides a brief overview of
migration to the 900 Series from MPE V/E-based systems. It describes MPE/iX dual
operating mo des, features, and ma jor subsystems.
It provides an overview of MPE/iX accoun
execute MPE/iX commands, and the considerations necessary to con
ting structure, session and batc
vert les to MPE/iX.
h modes, howto

Introduction to the HP 3000

The HP 3000 is a general-purpose multiprogramming machine, designed for the interactive,
transaction processing environment of business and industry. The HP 3000 family of
computers includes several mo dels of the machine, each with a dierent series number.
900 Series HP 3000
The newest high performance members of the 900 Series HP 3000 family are based on HP
Precision Architecture (HP-PA), a highly exible computer design that can meet curren
t user
requirements and requirements arising during future growth.
HP Precision Architecture (HP-PA)
HP Precision Architecture (HP-PA) is based on Reduced Instruction Set Computer (RISC)
concepts with added extensions for a complete system. This increases computer performance
by reducing and simplifying the computer instruction set. HP-PA eliminates system overhead
associated with conventional computer micro code by directly implementing computer
instructions in hardware. The uniformity of HP-PA instructions enhances pipelining,
providing higher performance byoverlapping execution of multiple instructions. Many
technologies can implement HP-PA; highly integrated VLSI designs can be achieved by
eliminating the chip space required for microco de.
High performance from HP-PA architecture results from the memory hierarchy design and the
use of optimizing compilers. Pro cessor waiting time for memory accesses is minimized due to
the following architectural characteristics:
Frequently used instructions and data are stored in a large number of CPU registers.
High-speed buering of code and data occurs.
Optimizing compilers generate ecient ob ject code, allocate registers, and schedule
instruction sequences to maintain ecient pipeline operation.
OVERVIEW 1-1

MPE Operating Systems

All HP 3000 models run under the Multiprogramming Executiv
is a disc-based operating system that manages all system resources and co ordinates execution
of all programs running on the system. The v
to another. Figure 1-1 shows the on-line access capabilities common to all MPE operating
systems.
ersion of MPE used varies from one model
e (MPE) op erating system. It
Figure 1-1. MPE/iX On-line Access Capabilities
The system simultaneously p erforms inquiry and up date, program dev
processing, and communications to other systems. All functions are available on-line (in
sessions) or in batch mo de (in jobs)submitted to the system. The same programs, les, and
commands apply for both types of use. Figure 1-2 shows the high-level to ols available on the
900 Series HP 3000.
1-2 OVERVIEW
elopment, batch
Figure 1-2. 900 Series HP 3000 High-level Tools
MPE/iX and MPE V/E Operating Systems
Since the 900 Series HP 3000 was introduced, Hewlett-Packard supports twotypes of MPE
operating system; MPE V/E and MPE/iX, which stands for MPE with eXtended Large
addressing. The"V"in the name MPE V/E is the Roman numeral for"5."MPE V/E is
the operating system formerly called MPE. MPE V/E is supported on Series 37 through the
Series 70 systems. MPE/iX is the operating system for 900 Series systems. It is designed to
take full advantage of HP Precision Architecture (HP-PA). MPE/iX has the performance and
ease-of-use of MPE V/E, plus additional functions and capabilities. It is upwardly compatible
and has a user interface consistent with MPE V/E. MPE/iX is object co de and source code
compatible for programs developed on MPE V/E. It has two run-time environments that are
transparent to the user:
OVERVIEW 1-3
Compatibility Mo de (CM), which provides ob ject-code compatibility with MPE V/E-based
applications.
Native Mode (NM), whic
h provides full performance benets and adv
anced capabilities of
HP-PA.
Naming Conventions for HP 3000 Systems and Softw
When the 900 Series w
instituted a new naming convention for HP 3000 softw
"/V"or"
/XL"to a pro duct name. Soft
as added to the HP 3000 family of computers, Hewlett-P
are products; the addition of the sux
ware pro ducts that previously had the sux
nowhave the sux"/V."For example, the pro duct named IMA
IMAGE/V, and the pro duct named COBOL/3000 is no
w named HP COBOL/V.
are
ackard
GE/3000 is now named
"
/3000
The"/V"sux indicates that a pro duct is designed for use with the MPE V/E operating
system. This product can also be used with the MPE/iX operating system running in
Compatibility Mode. A compiler with the sux
code that runs under MPE V/E and MPE/iX (in Compatibilit
"/V"
(for example, RPG/V) generates ob ject
y Mode).
The"/XL"sux indicates that a pro duct is designed for use with MPE/iX running in
Native Mode. A compiler with the sux
ob ject co de that runs with MPE/iX in Native Mo de. Figure 1-3 sho
"
/XL"(for example, HP COBOL I I/XL) generates
ws an example of naming
conventions.
"
Figure 1-3. HP 3000 Software Naming Conventions Example
Computers in the HP 3000 family that operate under the MPE V/E operating system are
frequently called"MPE V/E-based systems."Computers in the HP 3000 family that operate
under the MPE/iX operating system in native mode are frequently called"MPE/iX-based
systems."This includes 900 Series systems.
1-4 OVERVIEW
Native Mode and Compatibility Mode
MPE/iX provides two run-time execution environments: Native Mode (NM) and
Compatibility Mo de (CM). MPE/iX dynamically and transparen
modes as required b
y applications.
tly coordinates and c
hanges
NM is the native MPE/iX run-time environment. Source co de has been compiled in
Series native instruction set. NM is the preferred en
vironment for the 900 Series and pro
to the 900
vides
the highest p erformance from the systems through the use of demand paged virtual memory
and memory mapp ed les.
CM provides ob ject code compatibilit
ybetween MPE V/E based systems and 900 Series
computers. CM allows you to move applications and data to 900 Series computers without
changes or recompilation.
MPE/iX is a compatible sup erset of MPE V/E. CM pro
environment, including MPE V/E code and stac
k structures and most callable MPE V/E
vides a working MPE V/E
system intrinsics.
MPE/iX Mixed Modes
Applications can run partly in Native Mo de (NM) and partly in Compatibility Mo de (CM).
MPE/iX transparently switches between modes for system routines. MPE/iX has a Switc
Subsystem that determines if code is in NM or CM and automatically switc
hes between them,
h
as needed, while the routine is running. When the called routines are in the other mode, users
must write their own switching routines.

900 Series Migration

The use of Compatibility Mo de (CM) and migration utilities pro
migration to 900 Series systems. The high degree of ob ject code compatibility bet
V/E and MPE/iX operating in CM allo ws y
ou to store any MPE V/E based application
vides smooth, exible
ween MPE
ob ject co de program written in a language supported on MPE V/E, restore it on a 900 Series
system, and run it in MPE/iX Compatibility Mo de. You can move data bases to a 900 Series
system in the same way.
900 Series systems are fully upward compatible with other systems in the HP 3000 family
.
Migration tools are provided to facilitate upgrading to the 900 Series in stages, as your
schedule permits, without interruption of operations. Migration to the 900 Series provides:
Object code compatibility: a simple store/restore procedure allows you to move MPE V/E
applications and data to the 900 Series. You can back up applications and databases on a
tape and restore them on a 900 Series system without mo dication. The applications and
databases run on the 900 Series in CM.
Source code compatibility: you can recompile applications for maximum p erformance
by using Native Mo de (NM) optimizing compilers, which improve performance. You can
achieve maximum database performance by using software utilities to transform databases
into NM.
OVERVIEW 1-5
Migration exibility: upgrading to the 900 Series is extremely exible because applications
and databases can access and comm
modes (in other w
ords, when one is in CM and the other is in NM).
unicate with each other when they are in dieren
t
Operational exibility: MPE/iX is a functional superset of MPE V/E. They are nearly
identical in terms of user in
terface, system management, accounting, and security.
Peripheral compatibilit y: Because of common I/O mec
many of the same peripherals and w
orkstations as other HP 3000 systems do.
hanisms, the 900 Series supp orts
Cross-family development: CM allows you to develop applications on the 900 Series that
can also be run on MPE V/E-based systems.
Migration to the 900 Series is exible because y
ou can move some applications to NM and
move others to CM. Both kinds of applications can access the same database, and it can be
in CM or NM. Y
migrate applications to NM at con
ou can immediately move all your applications and databases to CM and can
venient times.
Object Code Translator
MPE/iX provides an Ob ject Code Translator (OCT) that can be used to translate MPE V/E
ob ject co de into native instructions for the 900 Series. This improves performance over that of
the MPE V/E object co de.
Native Mode Compilers
To take full advantage of 900 Series performance capabilities, y
based applications using Native Mo de (NM) compilers for the 900 Series. They pro
code compatibility with the rest of the HP 3000 family of computers. Usually
require little or no code mo dication. The NM compilers a
ou can recompile MPE V/E
vide source
, applications
vailable on MPE/iX include:
HP C/iX
COBOL II/XL
HP Pascal/iX
HP FORTRAN 77/iX
Data Base Manipulations
For improved performance of database manipulations, you can move to ALLBASE/SQL, the
Native Mode Database Management System for the 900 Series. Utilities are available for
converting to ALLBASE/SQL from TurboIMAGE/XL.
Migration Restrictions
Minor restrictions may apply to migrating MPE V/E-based applications to a 900 Series
system. An application may require modication if it uses:
Undocumented intrinsics
Privileged machine instructions
Unsupported hardware
Architecture-dependent information
Applications written in SPL/V, the systems programming language for MPE V/E-based
systems, can run in Compatibilit y Mo de (CM) on a 900 Series system, but cannot migrate to
1-6 OVERVIEW
Native Mode (NM) because SPL/V has a high dependence on the MPE V/E-based HP 3000
architecture. However, you can improve the performance of an SPL/V application running in
CM by using the MPE V/E Ob ject Code T
ranslator.
If you require NM performance, these applications should be rewritten in HP C/iX or HP
Pascal/iX, which are systems programming languages for MPE/iX. If an application written
in a high-level language calls SPL/V procedures, y
and uses a user-supplied mode switc
hing procedure to switc
ou can recompile it in NM. It runs in NM
h to CM to call SPL procedures.
For information on less frequently encountered exceptions, refer to the
manuals. For information on switching, refer to
Switch Programming Guide
Migration Series
(32650-90014).
of
Cross-family Application Development
You can develop applications on a 900 Series system for use on HP 3000 systems that use HP
Precision Architecture (HP-PA) by using a 900 Series for cen
tralized development. You can
compile the source code for programs written to run on a Native Mo de compiler on the 900
Series system and compile it to run on MPE V/E-based systems.
Similarly,you can compile source code written to run in Compatibility Mo de on the 900 Series
and compile it to run on MPE V/E-based systems. The MPE V Segmen
ter is supplied with
MPE/iX to facilitate cross-family development in these languages.

MPE/iX Features

The main features of the MPE/iX op erating system on a 900 Series computer include:
Multiprogramming: concurrent transaction processing, data communications, on-line
program development, and batch processing.
Extended large addressing: 48-bit virtual addressing.
Demand paged virtual memory, which transparently manages virtual memory and
eliminates the need for program segmentation.
Mapped disc les, which eliminates the need for File System buering for disc les. This
increases system p erformance for I/O-intensive applications.
Concurrentmultilingual capability, including HP-extended versions of C, COBOL, RPG,
FORTRAN, BASIC, and Pascal.
File System, which includes le backup, user logging, security, and interpro cess
communication (IPC).
Access security and complete accounting resources.
Command interpreter, which includes user-dened commands (UDCs), command les,
conditional job control, extensive on-line help facility, and descriptive error messages.
Device and le independence, which simplies application development and maintenance.
I/O System, which provides input/output sp ooling and a tape label facility.
Complete, automatic lo cal and remote terminal management.
Power fail/automatic restart.
OVERVIEW 1-7
Interactive Debug facility, which provides windows that allowyou to simultaneously see
the environment of the program being tested. It supports breakpoin
ts, single stepping,
calculation of expressions, macros, and command les.
Multiprogramming
MPE/iX supports m
ultiprogramming, the concurrent execution of multiple programs. All
system resources are available to you as if you were the only user on the system. While
one program is waiting for input, the system shifts con
program in the queue. In this w
ay, activities such as transaction processing, on-line program
trol of the CPU to the next highest
development, interactive data entry, data communications, and batch pro cessing can be
concurrently performed.
MPE/iX is a multiprogramming, multiuser system. On this kind of a system, m
can share code. F
process is created for eac
interpreter on the system), but eac
MPE/iX completely protects one program execution from in
or example, when multiple users access the BASIC/V in
h one. They all use the same code (b ecause there is only one BASIC
h user has a unique en
vironment created by MPE/iX.
terfering with another.
terpreter, a separate
ultiple users
Interactive and Batch Processing
MPE/iX provides interactive and batch processing. An interactive process is called a session.
A batch process is called a job.
In a session, you enter commands and data at a terminal and receiv
e an immediate resp onse.
This is especially useful for data entry and retrieval, program development, text editing, and
any application that is expedited by direct dialogue with the computer.
In batch processing, you submit a job to the computer. A job is a single unit comp osed of
commands that request various operations, such as program compilation and execution, le
manipulation, or utility functions. While a job is processing, there is no user in
the computer unless the job is set up to request information. Jobs can b e sc
teraction with
heduled to run
at lower priorities than interactive sessions and at sp ecic times (for example, when system
activities are low).

MPE/iX Information Management

Commercial applications primarily use database applications. The 900 Series provides
ALLBASE/SQL, which includes TurboIMAGE/XL, a network database management
product, and HP SQL, which has a relational interface to data. ALLBASE/SQL provides a
TurboIMAGE/XL cross-developmentenvironment. The relational interface, HP SQL, is fully
compatible with the version of SQL in most common use. It provides relational access for
increased exibility.
ALLBASE/SQL and other tools form Hewlett-Packard's information management framework.
These include:
Programming languages and tools.
Reporting and presentation to ols that allow access to information without programming.
1-8 OVERVIEW
A common data dictionary that pro
vides the integration necessary to tie the system
together.
The products that meet these needs on the 900 Series are:
System Dictionary/XL, which provides programmers and system administrators with
a single source for documen
conguration information. This cen
ting all asp ects of the system, from data denitions to
tral source of information aids in dev
eloping and
maintaining applications and eectively managing system resources. The System
Dictionary/XL has programmatic interfaces for easy integration with other softw
can customize System Dictionary/XL to meet y
our needs.
Optimizing compilers, which use HP Precision Architecture (HP-PA) to allo w all
programming on the 900 Series computers to be done in high-lev
are integrated with MPE/iX to pro
vide convenient access to ALLBASE/SQL and other
el languages. The compilers
information managements subsystems.
VPLUS/V, which is a forms design and screen-handling tool for programmers.
are. You
Toolset/XL, which includes facilities for full screen editing, sym
and version management of source code. It pro
vides a high-productivity,integrated
bolic source-level debugging,
environment for application development.
Transact/XL, which is a pro cedural, high-level programming language for transaction
processing applications. It provides the functions of a high-level language, such as COBOL,
combined with a comprehensive set of p owerful verbs that can perform several functions in a
single call.
Self-adjusting System Tables
Most system tables in MPE/iX are self-adjusting. MPE/iX con
tables to t the workload. Usually, the system manager can do this without sh
tinuously monitors and adjusts
utting down the
system.
On-line Diagnostics for Peripherals
Hewlett-Packard Customer Engineers (CEs) are equipped with on-line diagnostic to ols for
many HP peripheral devices. A CE can remotely run diagnostics without sh
utting down the
system.
Disc Failure Tolerance
MPE/iX allows any system disc not critical to the functioning of the op erating system to go
o-line without aecting the system. Users cannot access les on o-line discs.
Automatic Power Fail Recovery
MPE/iX and the 900 Series hardware provide automatic power fail recovery. When a p ower
failure starts, the system initiates a power failure pro cedure to preserve the op erating
environment before the complete loss of power. A battery pack ensures the validity of main
memory for a minimum of 15 minutes. If p ower is restored within 15 minutes, the system
automatically resumes pro cessing from the p oint at which the power failure occurred, and jobs
continue from the pointofinterrupt.
OVERVIEW 1-9
MPE/iX Transaction Management F
acility
The MPE/iX Transaction ManagementFacility provides the following functions for
transaction-oriented applications:
Automatic transaction lo cking
Automatic transaction logging
Automatic rollback recovery from"soft"failures
Semi-automatic rollforward recovery from"hard"failures
These functions are described in detail in the subsections b elo
w.
Transaction Locking
A transaction is a series of data updates that m
consistency; either all or none of the updates in the series m
transaction may appear to b e a single c
manychanges to records in sev
eral les or data sets.
hange. However, internal to the system, it ma
For example, if you enter a customer order on the system with a simple command, it ma
ust be entirely completed to obtain logical
ust be done. T
o the user, a
y require
y
internally require updating several les containing data on orders, customers, and inventory
requirements. The multiple changes, all of which are required for logical consistency, form one
transaction.
The MPE/iX Transaction ManagementFacility ensures data consistency and integrityby
providing automatic transaction lo cking. Transaction lo cking meets two criteria:
Only one transaction at a time is allowed to update a given portion of data.
All changes that are part of a transaction must be completed b efore the changes are
committed to disc (permanently recorded). When a transaction is abnormally terminated
before it is completed, the changes made up to that point are not committed.
MPE/iX transaction lo cking is based on page-level protection of the system architecture and
does not require signicant CPU overhead.
Transaction Logging and Recovery
The Transaction ManagementFacility automatically generates and maintains a transaction log
le that records all transaction updates. Maintaining a log le facilitates recovery from the
abnormal end of transactions and system failures. In these cases, les can be restored to a
consistent state by copying the contents of the log le into the data le. This"undoes"the
actions of partially committed transactions.
System failures are either hard or soft. When a soft failure occurs, data is not altered or lost,
but some incomplete transactions may exist. In this case, the Recovery Manager portion of
the Transaction ManagementFacility is automatically invoked to perform recovery of the
data le when the system is restarted. Files are restored to their original state by copying the
"
before image"of data from the log le for incomplete transactions. This is called rollback
recovery. Recovery from a soft failure is ecient and takes a maximum of only a few minutes.
Rollback recovery is automatically performed for abnormally ended transactions.
When a hard failure occurs (for example, a disc media failure), data is lost. At system
restart, you must mount a backup tap e and issue the MPE/iX command
:RECOVER
. The
1-10 OVERVIEW
Transaction ManagementFacility returns data to a consisten
committed transactions in the log le to the c
called"rollforward recovery.
"
heckpoint presented by the backup tape. This is
t state by reapplying all
Transaction logging requires little CPU o
verhead b ecause it is designed as an in
tegral part of
the MPE/iX File System, utilizing the addressing and protection features of HP Precision
Architecture (HP-PA).
Simplifying a Program
The Transaction ManagementFacility simplies development and maintenance of
transaction-oriented applications by:
Maintaining recovery routines, so a programmer does not ha
ve to develop and maintain
custom ones.
Simplifying the programming task of ensuring data in
tegrity and increasing its eciency
.
Providing locking and logging, thus requiring the programmer to mark only the beginning
and end of transactions.

DEBUG

DEBUG is a low-level assembly language debugger, requiring some knowledge and familiarity
in the following areas to utilize:
Assembly code
Procedure calling conventions
Parameter passing conventions
HP3000 and HP Precision Architecture (HP-PA)
Hewlett-Packard oers two source level, symbolic debuggers, SYMBOLIC DEBUG/XL and
Toolset/XL, whichyou can use if you do not require assembly language debugger features.
DEBUG is an intrinsic procedure, providing privileged and non-privileged users with an
interactive debugging facility for checking out their operating environments. Using DEBUG, it
is possible to:
Set, delete, and list breakpoints in a program. The program executes until a breakpoint
is reached, then stops and passes control to the user. When you set breakp oints, you can
specify a list of commands that will automatically b e executed when the breakp oint is hit.
Single step (multiple steps) through a program.
Display and/or mo dify the contents of memory locations. A full set of addressing modes is
oered, including:
- absolute CM memory
- code segment relative
- data segment relative
- S relative
- Q relative
- DB relative
- HP-PA virtual addresses
- HP-PA real memory addresses
OVERVIEW 1-11
Display a symbolic procedure stac
(NM) and Compatibility Mo de (CM) calls. Y
k trace, optionally displaying interleaved Native Mode
ou can also temp orarily set the curren
environment back to the environment that existed at an
t debug
y marker in the stack.
Calculate the value of expressions to determine the correct v
point in a program. V
alues can b e custom formatted in sev
alues of variables at a given
eral bases.
Use full screen displays (windows) that allowyou to inspect registers, program code, the
current stack frame, and the top of stac
important data blo c
ks to dynamically monitor c
Display on-line help for all commands, predened functions, and en
Create and reference user-dened v
k. Groups of custom user windo
hanging values.
ariables.
ws can b e aimed at
vironmentvariables.
Dene powerful, parameterized macros. You can invoke macros as new commands to
perform sequences of commands or as functions within expressions that return single v
alues.
Dene aliases for command and macro names.
Execute commands from a le, record all user input to a logle, and record all DEBUG
output to a listle.

MPE/iX User Interface

MPE/iX has a user interface that includes a command language, on-line HELP facility
,
user-dened commands (UDCs), and command les.
The MPE/iX command language is processed by the Command Interpreter. It contains all
necessary commands to direct and control the system.
You can enter identical MPE/iX commands during a session or through a job; MPE/iX has no
separate control language for jobs. You can also issue MPE/iX commands in a command le.
Actions MPE/iX commands can p erform include:
Initiate and terminate jobs and sessions.
Run system programs and utilities.
Compile, link, load, run, and debug programs.
Create, maintain, and delete les.
Display le information.
Display job, session, or device status.
Transmit messages.
Establish communication with lo cal and remote computers.
Control and manage system resources.
If the command interpreter (CI) detects an error in command syntax in interactivemode
(during a session), it provides a descriptive error message specifying the erroneous parameter
and prompts you to correctly reenter the command. If it detects a syntax error while running,
it lists the error on the output device and halts the job.
1-12 OVERVIEW
Loading...
+ 162 hidden pages