HPlogo MPE/iX System Utilities Reference > Chapter 21 SLPATCH

Operation

MPE documents

Complete PDF
Table of Contents
Index

To invoke SLPATCH enter:

   SLPATCH

or

   RUN SLPATCH.PUB.SYS

SLPATCH responds with the following and displays ? to prompt you for the SL file name you wish to work on. Enter the file name in the form: filename[.groupname[.acctname]], and use all uppercase letters. For example:

   SLPATCH A.43.11 (C) HEWLETT-PACKARD CO., 1976
   SL FILE? SL.PUB.HITECH

When SLPATCH accepts the name of the segmented library file, it displays another ? to prompt you for a segment name and a command. SLPATCH continues to display this prompt, awaiting another command, until you exit the utility. To terminate SLPATCH, enter EXIT at the ? prompt.

D


This command displays the contents of an SL segment. To invoke this command enter:

   ?[ segname,] D, segdisplace[, numwords]

Parameters

segnameThe name of the segment you want to display, obtained from an SLCREF (SL Cross-Reference) listing. This parameter must be specified the first time the segment is accessed, but may be omitted in subsequent commands.
segdisplaceThe segment displacement.
numwordsThe number of words of the SL to display. The default is one.

M


This command modifies the contents of an SL segment. To invoke this command enter:

   ? [segname,] M, segdisplace [,numwords]

Parameters

segnameThe name of the segment you want to modify, obtained from an SLCREF (SL Cross-Reference) listing. This parameter must be specified the first time the segment is accessed, but may be omitted in subsequent commands.
segdisplaceThe segment displacement.
numwordsThe number of words SL modifies. The default is one.

The contents of each word to be modified is displayed, followed by a comma. To retain the old value, enter * and press Return. To enter a new value, type the number (in octal) and press Return. If you only press Return, you will be prompted to enter * or a number.


NOTE: To find the segment displacement, add the instruction offset (generally found in the compiler listing) to the starting address of the procedure (supplied by the PMAP option of the PREP command).

For information regarding the offsets of instructions in program files, refer to compiler options for the programming language in which the code was written.

SLPATCH Example


Invoke SLPATCH and enter the SL name. For example, if the name of the segmented library file is SL.PUB.HITECH, you enter:

   SLPATCH

   SLPATCH A.43.11 (C) HEWLETT-PACKARD CO., 1976
   SL FILE? SL.PUB.HITECH

Next, display 4 words, beginning with word 0 of segment SDMCOMM:

   ? SDMCOMM,D,0,4
   025001
   051404
   041605
   021040

Display 3 words, beginning with word 5 in the same segment. Notice the segment name need not be entered again:

   ? D,0,3
   023113
   040415
   050641

Change the contents of the first word of SDMCOMM segment and terminate SLPATCH:

   ? M,0,1

   025001,025002
   ? EXIT

Additional Information


For more information on segmented libraries refer to the MPE Segmenter Reference Manual.




Chapter 21 SLPATCH


Chapter 22 SOMPATCH