Digital PDFs
Documents
Guest
Register
Log In
DEC-XV-UDDTA-A-D
May 1975
72 pages
Original
21MB
view
download
Document:
DDT XVM
Utility Manual
Order Number:
DEC-XV-UDDTA-A-D
Revision:
Pages:
72
Original Filename:
http://bitsavers.org/pdf/dec/pdp15/XVM/DEC-XV-UDDTA-A-D-DDT_XVM_UTILITY_MANUAL.pdf
OCR Text
DDT XVM UTILITY MANUAL DEC-XV-UDDTA-A-D DDT XVM UTILITY MANUAL DEC-XV-UDDTA-A-D digital equipment corporation • maynard. massachusetts First Printing, December 1975 The information in this document is subject to change without notice and should not be construed as a commitment by Digital Equipment Corporation. Digital Equipment Corporation assumes no responsibility for any errors that may appear in this document. The software described in this document is furnished under a license and may be used or copied only in accordance with the terms of such license. Digital Equipment Corporation assumes no responsibility for the use or reliability of its software on equipment that is not supplied by DIGITAL. Copyright (S) 1975 by Digital Equipment Corporation The postage prepaid READER'S COMMENTS form on the last page of this document requests the user's critical evaluation to assist us in preparing future documentation. The following are trademarks of Digital Equipment Corporation: DIGITAL DEC PDP DECUS UNIBUS COMPUTER LABS COMTEX DDT DECCOMM DECsystem-lO DECtape DIBOL EDUSYSTEM FLIP CHIP FOCAL INDAC LAB-8 MASSBUS OMNIBUS OS/8 PHA RSTS RSX TYPESET-8 TYPESET-10 TYPESET-ll 1/76-15 - -" CONTENTS Page PREFACE CHAPTER CHAPTER CHAPTER CHAPTER vii 1 INTRODUCTION 1.1 1.2 1.3 GENERAL INFORMATION OPERA.TION CONVENTIONS AND SPECIAL SYMBOLS 2 BASIC DDT 2.1 2.2 2.2.1 2.2.2 2.2.3 2.3 2.3.1 2.3.2 2.4 2.5 2.6 2.7 2.8 2.8.1 2.8.2 2.8.3 2.8.4 2.8.5 2.9 2.10 2.11 LOADING DDT AND USER PROGRAMS EXAM.INING STORAGE WORDS Opening a Location "Last-Opened-Register Pointer" Closing/Reopening Locations TYPE-OUT MODES Address Modes Instruction Modes RETYPE COMMANDS MODIFYING STORAGE WORDS INPUT MODES SEQUENCING BREAKPOINTS Setting Breakpoints Breakpoint Restrictions Breakpoint Type-Out ReaSSigning and Removing Breakpoints Proceeding After a Break STARTING A PROGRAM STOPPING A PROGRAM ERRORS 3 DDT LANGUAGE AND SYNTAX 3.1 3.2 3.2.1 3.2.2 3.2.3 3.2.4 3.2.5 3.2.6 3.2.7 COMMAND STRUCTURE ARGUMENTS Syllables The Symbol Table Expressions Symbolic Instruction Mode Octal Number Mode Transfer Vector Mode ASCII Text (Output Only) 4 DEBUGGING WITH DDT 4.1 4.2 4.3 4.3.1 4.3.2 4.3.3 4.3.4 LOADING A PROGRAM STARTING A PROGRAM REGISTER EXN1INATION AND MODIFICATION Type-Out Mode Commands Special Symbols and Concepts Register Examination Commands Expression Retype Commands iii 1-1 1-1 1-2 2-1 2-2 2-2 2-3 2-3 2-3 2-4 2-4 2-5 2-6 2-6 2-6 2-7 2-7 2-8 2-8 2-9 2-9 2-9 2-9 2-9 3-1 3-2 3-2 3-3 3-!'i 3-6 3-8 3-8 3-9 4-1 4-1 4-2 4-2 4-2 4-6 4-7 contents (Cont. ) Page 4.3.5 4.4 4.5 4.6 4.6.1 4.6.2 4.6.3 4.6.4 4.6.5 4.6.6 4.7 4.7.1 4.7.2 4.7.3 4.7.4 4.7.5 4.7.6 4.7.7 4.8 Register Modification Commands DEFINING A SYMBOL SEARCH OPERATIONS BREAKPOINTS Definition Setting Breakpoints Breakpoint Restrictions Flow of Control at Breakpoints What Happens on a Break The Execute Command MISCELLANEOUS FEATURES Operate Link and AC Make Subprogram Current (Header Command) Initialize Memory Loading DDT without a Program Restarting DDT Typing Mistakes Protect Mode Commands ERROR RECOVERY 4-7 4-9 4-10 4-13 4-13 4-13 4-15 4-16 4-19 4-21 4-23 4-23 4-23 4-23 4-23 4-24 4-24 4-24 4-24 APPENDIX A SUMMARY OF DDT COMMAtmS A-l APPENDIX B MNEMONIC INSTRUCTION TABLE B-1 APPENDIX C DDT MEMORY LOAD MAPS C-l Index Index-l TABLES TABLE 1-1 Symbols Used in Text and Examples iv 1-2 -, - , -- , LIST OF ALL XVM MANUALS The following is a list of all XVM manuals and their DEC numbers, including the latest version available. Within this manual, other XVM manuals are referenced by title only. Refer to this list for the DEC numbers of these referenced manuals. BOSS XVM USER'S MANUAL DEC-XV-OBUAA-A-D CHAIN XVM/EXECUTE XVM UTILITY MANUAL DEC-XV-UCHNA-A-D DDT XVM UTILITY MANUAL DEC-XV-UDDTA-A-D EDIT/EDITVP/EDITVT XVM UTILITY MANUAL DEC-XV-UETUA-A-D 8TRAN XVM UTILITY MANUAL DEC-XV-UTRNA-A-D FOCAL XVM LANGUAGE MANUAL DEC-XV-LFLGA-A-D FORTRAN IV XVM LANGUAGE MANUAL DEC-XV-LF4MA-A-D FORTRAN IV XVM OPERATING ENVIRONMENT MANUAL DEC-XV-LF4EA-A-D LINKING LOADER XVM UTILITY MANUAL DEC-XV-ULLUA-A-D MACII XVM ASSEMBLER LANGUAGE MANUAL DEC-XV-LMLAA-A-D MACRO XVM ASSEMBLER LANGUAGE MANUAL DEC-XV-LMALA-A-D MTDUMP XVM UTILITY MANUAL DEC-XV-UMTUA-A-D PATCH XVM UTILITY MANUAL DEC-XV-UPUMA-A-D PIP XVM UTILITY MANUAL DEC-XV-UPPUA-A-D SGEN XVM UTILITY MANUAL DEC-XV-USUTA-A-D SRCCOM XVM UTILITY MANUAL UPDATE XVM UTILITY MANUAL VP15A XVM GRAPHICS SOFTWARE MANUAL DEC-XV-USRCA-A-D DEC-XV-UUPDA-A-D DEC-XV-GVPAA-A-D VTI5 XVM GRAPHICS SOFTWARE MANUAL DEC-XV-GVTAA-A-D XVM/DOS KEYBOARD COMMAND GUIDE XVM/DOS READER'S GUIDE AND MASTER INDEX DEC-XV-ODKBA-A-D DEC-XV-ODGIA-A-D XVM/DOS SYSTEM MANUAL DEC-XV-ODSAA-A-D XVM/DOS USERS MANUAL DEC-XV-ODMAA-A-D XVM/DOS VIA SYSTEM INSTALLATION GUIDE DEC-XV-ODSIA-A-D XVM/RSX SYSTEM ~illNUAL DEC-XV-IRSMA-A-D XVM UNICHANNEL SOFTWARE MANUAL DEC-XV-XUSMA-A-D v PREFACE DDT XVM (DDT), which stands for Dynamic Debugging Technique , is an online interactive debugging program in the XVM!DOS software system. In the preparation of this manual, it was assumed that the reader is familiar with XVM!DOS e.g., its Monitor and Utility Programs. Useful manuals to read in conjunction with this one are: XVM!DOS Users Manual FORTRAN IV XVM Language Manual FORTRAN IV XVM Operating Environment Manual MACRO XVM Assembler Language Manual Linking Loader XVM Utility Manual vii CHAPTER 1 INTRODUCTION 1.1 GENERAL INFORMATION DDT XVM (Dynamic Debugging Technique) (DDT) is a conversational system program which is available in XVM/DOS. It provides both MACRO and FORTRAN programmers (see Appendix D) with a convenient means for debugging and closely monitoring the operation of their programs. DDT commands entered via the console terminal permit the user to: 1) start a program, 2) suspend its execution at predetermined points, 3) examine the status of memory words, and 4) make additions and corrections using either symbolic or octal code. Under most circumstances the user will be able to stop a "runaway" program. DDT always resides in core with the programs to be debugged, and may be considered as being both a program supervisor and a binary editor. The type of the input infor- mation required by DDT or output (printed) from DDT requires the user to be familiar with machine language programming. The format of DDT console terminal input and output is similar to the format used by the MACRO assembler. 1. 2 OPERATION When the appropriate request is typed to the Monitor, DDT is loaded into memory below the bootstrap by the Linking Loader. Upon command the Loader relocates and loads the user's main program and subprograms (including symbol table if requested), all requested user library subroutines, all requested I/O device handlers, and all requested FORTRAN Object Time System routines. After loading has been accomplished, the Loader transfers control to DDT. DDT uses the Monitor to communicate with I/O device handlers and to trap errors during program execution. While DDT is running, Program Interrupt and Automatic Priority Interrupt are enabled, as well as XVM addressing mode, if requested. 1-1 Introduction The user converses with DDT via the console terminal. Console terminal I/O is done almost exclusively one character at a time in Image alphanumeric mode. This enables the DDT language to contain simple, concise commands. 1.3 CONVENTIONS AND SPECIAL SYHBOLS Table 1-1 lists special symbols which are used throughout this manual to represent console terminal Keyboard Operators. NOTE In examples simulating TTY entry/ response operations, the character or text to be entered by the user is underlined (e.g., xxx) to distinguish it from printed output. --Table 1-1. Symbols Used in Text and Examples TEXT SYHBOL TELETYPE 1 ECHO KEY(S) TO BE ACTUATED ) Non-Print RETURN Carriage-Return and Line Feed Non-Print SPACE Bar Carriage is advanced one character space Non-Print LINE FEED Platen is advanced to next line Non-Print CTRL and I/TAB Hoves carriage to next tab location (normally 8 spaces) 1\ or SHIFT and Control entry defined within programs t t t plus a character (e. g. , t T) Char --- $ OPERATION INITIATED N/ CTRL and Character Key CTRL & T Initiates a program or system control operation defined within the system $ ALTHODE Terminator whose use is defined within the system program [ [ Use defined within program ] ] [ or SHIFT and K/VT ] or SHIFT and \ \ tT Use defined within program M RUBOUT or SHIFT and L/FORM Character Rubout ITeletype is a registered trademark of the Teletype Corporation. 1-2 ....." CFAPTER 2 BASIC DDT This section introduces the main features of DDT to the beginning user. Many programs can be successfully debugged using only the basic commands described below. More detailed descriptions of the basic com- mands and other less frequently used commands are given in later sections. To simplify the information presented in this section it is assumed that only the main program of the user's system is to be tested, even though subprograms and library programs may also have been loaded and linked to the main program. This assumption avoids having to describe, at this point, how symbols in one program are differentiated from identical symbols in another program. 2.1 LOADING DDT AND USER PROGRAMS In XVM/DOS, the Keyboard command DDT (or DDTNS) calls the Linking Loader as well as DDT (DDTNS prevents loading of the user symbol table in order to save memory) . The first response to the terminal is: BANK MODE ON: PAGE MODE ON: LOADER XVM Vnxnnn or > BLOADER XVM Vnxnnn > Typing a command string to the Loader, e.g., >P+MAIN,SUBR1,SUBR2(V then loads the user program. For detailed instructions, read the Linking Loader XVM Utility Manual. 2-1 Basic DDT When loading is complete, DDT takes control and types: PAGE MODE ON: BANK MODE ON: DDT XVM Vnxnnn or > BDDT XVM Vnxnnn > to indicate its readiness to accept DDT commands. NOTE NS is printed before DDT if the symbol table could not be loaded into available core. In XVM/DOS, .DAT slots -4 (user programs), -5 (user external library, if any), and -1 (system device for loading of DDT and system library routines) must be assigned to appropriate devices for proper loading. 2.2 EXAMINING STORAGE WORDS To examine the contents of a core word location, the user must "open" the desired location, receive printout of its contents, and, when finished, 2.2.1 "close" the location. Openinq a Location To open a storage word, the user must type its address terminated immediately by a slash (/). EXAMPLE: To open location ADR+l, type: ADR+1/ DDT responds to an "open" entry by performing a tab operation, printing the contents of the addressed location and performing a second tab. EXAMPLE: Entry Response >ADR+1/ -lLAC~TEMP-5 -l NOTE The above examples assume that the program's symbol table is available to the user; if not, the user must enter the location address in an OCTAL form. 2-2 Basic DDT 2.2.2 "Last-Opened-Register Pointer" Once a location is opened, DDT sets its address into a special pointer register termed the "Last-Opened-Register-pointer". The pointer is represented in DDT by a period (.) 7 thus when location ADR+l is opened the pointer (.) is set to its address (Le., 2.2.3 .=ADR+l). Closing/Reopening Locations Opened registers are closed by entering a carriage-return (.-J). EXAMPLE: >ADR+l/ -/ LACL....ITEMP-S-/ ..J The last-closed register may be reopened at any time by using the "Last-Opened-Register Pointer" (.). The pointer symbol is typed fol- lowed immediately by a slash (/). EY.AMPLE: DDT responds to a "reopen" entry by reopening the register whose address is stored in the pointer location and printing its contents. 2.3 EXAMPLE: If ADR+l was the last opened register, the reopen procedure would be: Entry Response d -I LACL....ITEMP-S-I TYPE-OUT MODES The examples of 2.2 show DDT typing out the contents of a register in symbolic form (i.e., a symbolic instruction with an address field relative to a symbol). by DDT. This is the type-out mode initially assumed All numeric quantities are printed in octal. The symbolic mode is useful if the user expects the opened register to contain a machine instruction. However, that register might be inter- preted instead, as octal data, as a transfer vector 1 , or as symbolic text. Additional commands to DDT are available which specify the form IThe term transfer vector means a word which contains an address pointing to some other location in memory. Transfer vectors are used with indirect address machine instructions because memory reference instructions cannot directly access more than 4K (in page mode) or 8K (in bank mode) of memory. 2-3 Basic DDT in which data is to be interpreted and printed. These mode commands may be typed whenever control is in DDT and it is waiting for typed input. 2.3.1 Address Modes There are three address mode commands: Typed Symbols Meaning Print addresses in symbolic form relative to a symbol with the closest value, e.g., ADR+l (Default). Print addresses as absolute octal numbers (18-bi t value). Print addresses as octal numbers relative to the lowest location in the program. F signifies "floating" addresses, which correspond to the unrelocated values one sees in an assembly listing. These addresses are printed as a pound sign (#), representing the program's load address, a plus sign (+), and an octal constant. For example, 2.3.2 Instruction Modes Four instruction mode commands specify the form in which the contents of opened memory words are printed. Command Meaning Print symbolic instructions; if the instruction is a memory reference instruction, the address field will be printed according to the current address mode (Default). Interpret words as transfer vectors. Print the 15-bit value as an address in the form dictated by the current address mode. If the higher order three bits are non-zero, precede the address by the six digit octal value of these three bits concatenated with a plus sign. Print words as octal quantities. mode has no effect. The current address Interpret data as packed 5/7 ASCII (lOPS ASCII) text. When a register is opened for examination, the contents of both that register and the following register are printed as five ASCII characters. Interpret data as SIXBIT Text. $$R Interpret data as RAD50 Text. 2-4 Basic DDT EXAMPLE: Assume that registers ADR and ADR+l _____ contain, respectively, 206613 and 155102 octal. >~ > R/ LAC TEMP > ADR/ LAC #+42 > ADR/ -+I LAC 6613 > ADR/ ~ LAC TEMP > ADR/ 206613 > ADR/ ~ 200000+TEMP > ADR/ ~ #+42 > ADR/ ! XYZ! ;j --I -+I -+I ~ ~ ~ -.j --l $F J $A3 $R $0) $V) $F) $T) ~ Since #+42 is equivalent to the 15-bit value 6613, the relocation factor (#) is 6613-42 2.4 = 6551. RETYPE COMMANDS Often, while examininq reqisters in the prevailinq tvpe-out mode, the user finds data which should be interpreted in a different mode. DDT permits the user to request that the data be retyped in another form, without changing the setting of the current mode. There are four retype commands which, if no expression is typed immediately preceding these commands, use as their argument the value of the last expression typed out by DDT. Retype Command Meaning Retype the value as an octal number Retype the value as a symbolic instruction Retype the value as a transfer vector ? Retype the value of the contents of locations . and .+1 interpreted as a 5/7 ASCII text string. $? $$? Retype the value in SIXBIT. Retype the value in RAD50. EXAMPLE Assume that TEMP is absolute location 6613. Entry Response >$R) >$0 J >ADR/ -.j 226613 Entry/Response -I ~LAC* TEMP or >ADR/ ~226613 -I .l.220000+XYZ or -1226613 or -.j ~ %XYZ% >~=OOOOOO 2-5 Basic DDT 2.5 MODIFYING STORAGE WORDS Once a word has been opened, its contents may be changed by typing the desired new contents immediately following the type-out produced by DDT. A carriage return terminator commands DDT to make the indicated modification and to "close" the word. ABC-2/ -+j-JMP BEG -.o\JMP For example, BEG+2) After being closed, register ABC-2 contains JMP BEG+2. If the regis- ter had been closed without typing a modification expression, it would retain its old contents. NOTE DDT does not permit the user to modify all core locations in order to prevent him from inadvertently modifying the Monitor or DDT itself. Should the user attempt to do so, DDT will respond by typing a question mark. When a user types an expression to DDT, as in the preceding example, the expression should follow the same format as is recognized by the MACRO assembler. However, instruction and address fields cannot be separated by a tab (-l) as allowed in MACRO. 2.6 INPUT MODES There are no input mode commands. Type-out modes are necessary since DDT cannot guess which form the user considers most appropriate. Where DDT expects an address quantity, user-typed expressions, such as, ~, are evaluated by DDT and taken as 1S-bit values. There is no provision for typing in data to be interpreted as 5/7 ASCII text. 2.7 SEQUENCING Once a register has been opened and (optionally) modified, it is sometimes convenient to be able to open some other register without having to close the current register and type the address of the new register followed by a slash. (a) DDT contains sequencing commands which modify the open register if an expression was typed, that register, and (c) open a new register. commands are listed below: 2-6 (b) close A few of these sequencing Basic DDT Command Meaning + Opens the next sequential register t Opens the preceding register. Opens the register in the same memory bank or page as directly addressed by the address partl of the last expression typed in or out. EXAMPLE: The following illustrates the usefulness of these commands. Opens registers ADR, ADR+l and ADR+2 ADR/ ~ ADR+l ->i ADR+2 -+f ~ TV+ 1 TV ->t -+t LACL-ITEMP+l DAC L-I rEMP 2 JMS*·L-I TV CAL * L-I ARG-l 0 DACL-INTX CAL* ~ARG-lO ! ! l 7 Opens register addressed i· ~by contents of ADR+2 $Y/ :i: S UBR1-{i. Retype the value of the lastopened register as a Transfer Vector and open the next register .<-_ _~ 2.8 Open the register preceding the last opened register BREAKPOINTS One useful function of DDT is its ability to start execution of the user's program and, if one of several pre-set control points in the program is reached, to suspend execution and "break" to DDT control. Such control points are calleo "breakpoints". ized by the command: 2.8.1 Breakpoints are symbol- ~B. Setting Breakpoints DDT allows up to four breakpoints, which are entered as numbers 1, 2, 3, and 4. I The indirect bit and the index bit (if in page mode) are ignored. 2-7 Basic DDT EXAMPLE: To set a breakpoint at location ADR, the user types ADR$B (no number assigned) or 2iADR$B (#2 assigned) When no breakpoint number is given, DDT chooses, if available, a breakpoint not in use and assigns its number to the entry. When the command is given to start execution of the user's program, DDT replaces the contents of the assigned break registers with the instruction JMS* 17, where register 17 is an auto index register which contains a return pointer to DDT. DDT can be made, if necessary, to use some other autoindex register. 2.8.2 Breakpoint Restrictions Because breakpoint registers are modified so that control can return to DDT, they should not be set on registers whose contents are programmodified or which are used as literals. The user should refrain from placing breakpoints on CAL and XCT instructions until the implications discussed in Section 4 are understood. 2.8.3 Breakpoint Type-Out When a breakpoint is reached during program execution, control is returned to DDT, which a) restores the original contents of all breakpoint registers, b) prints the number of the breakpoint causing the break, and c) prints the value of the contents of the Accumulator at the time of the break. DDT automatically saves and restores the contents of all registers when a break occurs and when resuming program execution. The user may examine and modify the saved contents of AC and Link by opening registers A# and L#, respectively, e.g., >A#/ >L#l -I 777777 -I ..., 000001 -+j NOTE The instruction replaced by the breakpoint instruction is not executed when the break occurs. It is executed only when execution proceeds after a break (see 2.8.5). 2-8 Basic DDT 2.8.4 Reassigning and Removing Breakpoints Breakpoints may be reassigned or removed as follows: a) To reassign a breakpoint, simply type in a new assignment statement using the new address; DDT automatically deletes the previous assignment. b) To remove all breakpoints, type: O$B c) To remove a specific breakpoint, for instance, breakpoint 3, type: 3;0$B 2.8.5 Proceeding After a Break After a break occurs, program execution may be resumed by typing: $p The instruction which is located at the breakpoint is simulated by DDT (except CAL and XCT) and execution proceeds from the register following the breakpoint. 2.9 STARTING A PROGRAM The command ADR$G will cause DDT to give control to the user's program and to GO to location ADR. If no argument is specified, the command $G will go to the starting address of the program. 2.10 STOPPING A PROGRAM In spite of the fact that the user may have judiciously set breakpoints in a program, execution may never reach those points if, for instance, the program enters an infinite loop. The user may break out of such a loop and return control to DDT by typing the character CTRL T (tT). 2.11 ERRORS If a typinq mistake is made by the user and DDT has not taken action, typing either RUB OUT or CTRL U will erase the entire input and allow it to be retyped. 2-9 Basic DDT If control is returned to DDT, causinq it to print DDT and version number, an illegal action was specified by the program either by having a breakpoint in a routine operating with interrupt off or by obtaining a Monitor error. If an error of this type occurs, the user program must be restarted from the beginning. If a user enters an undefined symbol as part of a command string, DDT will type the letter U and will ignore the entire string. When- ever the user attempts to perform an illegal command, DDT responds by typing a question mark (?). 2-10 CHAPTER 3 DDT LANGUAGE AND SYNTAX This section describes the rules governing the formation of DDT commands and of expressions, which are used as arguments for these commands. 3.1 COMMAND STRUCTURE DDT commands take none, one, or two arguments, depending on the specific command. When two arguments are required, they are separated by a semicolon or by an open (left) parenthesis. mand's arguments always precede the command characters. A com- The command may be either a single control character (such as t, =, or I), or the character ALTMODE (echoed as $) followed by another character, such as, $A, $T, or $S. The following examples illustrate the forms which DDT commands may take: Isingle argument commands Ino argument $B /both args missing [two required for B] arg$B /arg 1 missing arg; $B larg 2 missing arg;arg$B /both args Note that the $B command is shown four times. arguments. It requires two In the absence of either or both arguments, DDT supplies a predefined value as a default argument for each missing argument. The default arguments used depend on the specific command which they accompany. If DDT cannot recognize a command string, it will type a ? and ignore the string. 3-1 DDT Language and Syntax Appendix A contains a detailed list of the commands which are recognized by DDT. 3.2 ARGUMENTS Arguments to DDT commands are, in general, symbolic expressions which consist of syllables (symbols or numbers) separated by operators. 3.2.1 Syllables A syllable may consist of one to six characters from the radix 50 octal character set: a) b) c) d) A thru Z 0 thru 9 period (.) % and # The special characters single and double quote (' and ") may occur anywhere within a symbol. on. Their significance is explained further Syllables are delimited by any non-radix-50 character. A symbol must contain at least one non-octal character; otherwise, it is taken as an octal number instead of a symbol. Since DDT inter- prets all numeric input, and outputs all numeric output, in octal radix, the digits 8 and 9 are treated as an extension of the alphabet. In a symbol of more than six characters, all characters beyond the sixth are ignored. In a number of more than six octal digits, the last six digits are retained and those digits preceding the last six are discarded. The following illustrates symbols and numbers: ITEM INTERPRETATION TYPE 8 is not an octal digit. 8 A symbol %1. # A symbol % and # are radix 50 characters. IA A symbol Symbols need not begin with a letter. 123456A A symbol Although the A is discarded because it is the 7th-character, its presence declares the character string to be a symbol. 3-2 DDT Language and Syntax INTERPRETATION 3.2.2 123456Z A symbol Same symbol as 123456A since only the first six characters are retained. 7 A number Same as 000007. 1234567 A number Same as 234567 since the 1 is discarded. The Symbol Table In order to evaluate symbols within an expression, DDT must find the symbol and its definition in a symbol table (see memory map in Appendix C). This symbol table has two parts: one part contains the definitions of standard machine instruction mnemonics (e.g., LAC=200000, ADD=300000), the definitions of special DDT symbols (e.g., A# [the saved accumulator], L# [the saved Link], etc.), and any definitions of symbols created by the user in commands to DDT. This part of the symbol table resides in the area of memory occupied by DDT. The second part of the symbol table resides in lower core and is built there by the Linking Loader. It consists of several groups of internal symbol definitions, one group for each user subprogram loaded. A "header" at the beginning of each group gives the subprogram's file name and its load address (relocation factor). (If the command $DDTNS is given to the Monitor, the Loader will store the headers in the symbol table, but not the internal symbols. This is done to save memory space.) Subprograms may have internal symbols which are also used as internal symbols in other subprograms. Thus, the same symbol may appear sev- eral times in the DDT symbol table, each time with a different value. The following explains how DDT, in the face of multiple-symbol definitions, decides which value to assign to a symbol when it appears in a user-typed expression. Normally, DDT searches the entire symbol table for the symbol and its 18-bit value and takes the first match it finds. bol table in the following order: (2) the special DDT symbols, time, (1) DDT scans the sym- the instruction mnemonics, (3) the user symbols defined at run- (4) the symbols for the "current subprogram", and (5) the sym- bols in all other subprograms. 3-3 DDT Language and Syntax Initially, the current subprogram is defined as the main program (the first to be loaded - the first to appear in the Loader's command string). The concept is that one normally debugs one subprogram at a time; therefore, it is natural that when the user types a symbol 5YM, he is referring to SYM as defined in the subprogram on which he is currently working and not as defined in other subprograms. The user can, by using the header command ($H), define any subprogram as being "current" thus controlling the manner in which a symbol is defined by DDT. The special character single quote ('), which may appear anywhere within a symbol, declares the symbol to be a file name. The value of such a flagged symbol is the relocation factor for the subprogram with that file name. In such a case, DDT only searches for a header with a matching symbol. The special character double quote ("), which may appear anywhere within a symbol, declares that symbol to be an address tag. Speci- fically, it declares the symbol not to be an instruction; thus, DDT will bypass the instruction mnemonic table when searchil'tg for the value of such a symbol. This provision is made because it is legal, in the MACRO assembly language, to define address tags which have the same mnemonics as instructions, e.g., -/JMP-/JMP, where the secone JMP is an address. So, for example, if the user wishes to examine a register labelled JMP, he types the following to DDT: Both ' and" are flags (not to be confused as being symbol constitu- ents) much as the character # in MACRO may be located anywhere within a symbol to declare it to be a variable. Within an expression, any symbol following a space is treated as if it contained the double quote (") flag, that is, treated as an address tag. Thus, for ex- ample, in JMP 3+ADR the search for symbol ADR bypasses the instruction- mnemonic table. The special characters ' and" are ignored when they appear within octal numbers. 3-4 DDT Language and Syntax NOTE Symbols defined in a MACRO program by the use of (as in SYM=lOO) are not passed on to DDT in the user's symbol table. The user should be aware that FORTRAN IV passes local symbols to DDT which are identical to global symbols. In each case these local ad- dresses contain transfer vectors which are equal in value to the corresponding global symbol. These transfer vectors exist as long lists toward the end of FORTRAN programs and are used in the same way that MACRO uses external global transfer vectors. The preceding text discussed evaluation of symbols typed by the user. When DDT prints out expressions (for example, the contents of an opened register) ,it must perform the inverse process of taking a numeric value and converting it into symbolic form, usually involving a symbol table search. The output form is determined by the pre- vailing type-out modes and is discussed below. 3.2.3 Expressions Expressions consist of one or more syllables separated by operators and terminated by a character which is neither a legal syllable constituent nor an operator. When calculating the value of a user-typed expression, DDT evaluates the expression from left to right, combining values according to the intervening operators. ASCII text, which can be output by DDT, cannot be input by the user and is, therefore, not considered as a form of input expression. An expression may, of course, consist of only one syllable. DDT assumes, when evaluating an input expression, that the expression is preceded by 0+. This implies that the value of the first argument in a two-argument command is zero when the argument separator is typed with no preceding argument, e.g., jADR$B is equivalent to OiADR$B If the argument separator is missing, DDT supplies a default argument. The following operators define the ways syllable values may be combined. 3-5 DDT Language and Syntax OPERATOR + MEANING Add the two values in two's complement arithmetic (overflow is ignored) Add the two values in two's complement; but, from now until the end of the expression, do not change the instruction part of the accumulated value (bits o through 5). * Add the two values in two's complement and "exclusive or" the result with 20000 (the indirect bit) . (Overflow is ignored). Negate the following value if this is a unary minus. Otherwise, subtract the following value from the preceding value in two's complement. (Overflow is ignored. ) Form the "AND" of the two values bit by corresponding bit. & Form the "exclusive or" of the two values bit by corresponding bit. Form the ''inclusive or" of the two values bit by corresponding bit. The following subheadings describe input and output expression according to the various type-out modes. Note, however, that the pre- vailing type-out modes have no bearing on user-typed expressions. 3.2.4 Symbolic Instruction Mode To obtain the relocated value of any instruction in the current program as loaded by DDT, the user may type an expression identical in most respects with the original MACRO instruction. If all the symbols are defined in the original program, new instructions may be formed. Tab, however, may not be used to separate OP code from address field (space is used exclusively). The following are legal instructions, provided that the addresses are defined: l. JMPL-IJMP (JMP is an address in the current program) 2. DACJ+AD (Although AD evaluates to 18 bits, only 13 bits are used because of the space) 3. CLA!CLL 4. EAE+1002 (DDT does not contain EAE mnemonics) 5. IOT+314 (DDT does not contain lOT mnemonics) 6. IAWL....I-l (Same as LAW 17777) 3-6 DDT Language and syntax 7. XCT *L-I AD 8. LAC L-I C, X 9. CAL '-A 77 5 Indexed instruction (Once AAC, AXS, or AXR is encountered, the remainder of the expression will not alter the value of bit 0 through 8.) On output if DDT is in symbolic mode, the following prc.cedure is used to output an expression representing an 18 bit computer word: the instructions are broken down into categories appropriate to their OP codes. 1. If the OP code (bits 0-3) is 00 (CAL), the instruction is output as an octal number with leading 0 suppression (e.g., 775) • 2. If the OP code is 74 and bit 4 is off, the instruction is output as an inclusive ORed microcoded operate instruction (740000 types out as NOP, 754000 as CLA!CLL). 3. If the OP code is 76 (74 and bit 4 is on), the instruction is output as LAW L-rN, where N is an octal number representing the two's complement of the instruction (e.g., LAW~-l for 777777). 4. If the OP code is 64, the instruction is output as EAE+N, where N is an octal number representing bits 4-17 of the instruction (e.g., EAE + 1002 for LACQ). If the DDT symbol table contains an exact match, that match will be output. 5. OP code 70 must be broken down further (an exact match in the DDT symbol table will be output as in 4). If the instruction is an AAC, AXS, or AXR instruction, the corresponding mnemonic followed by space would be output, followed by bits 9-17 as a signed octal number. Otherwise, the number would be output as IOT+N, where N is an octal number representing bits 4-17 of the instruction, (e.g., IOT+314 for IORS and AXS~l for 725%%1). 6. The remaining OP codes are memory reference instructions. The corresponding instruction mnemonic is output. If the indirect bit is set, a * is output following the mnemonic. Then a space is typed, followed by the address referred to directly by the instruction, typed in the current address mode. The bank bits for the address are the same as the bank bits of "point" (the address of the last opened register), unless an auto-index register is referred to indirectly (e.g., LAC*L-I1%). If the index bit is set, the address is followed by ,X. The following are examples of memory reference instructions printed by DDT: 3-7 DDT Language and Syntax 3.2.5 1. JMPL...IJMP (JMP is an address in the current program) 2. DACL...IAD+1 (Relative address mode) 3. XCT*L...IAD 4. LACL...IAB,X (Indexed address) 5. DACL...I21253 (Last opened register is in bank 1; absolute address mode; same as 041253) 6. DACL...I#+2 (Floating address mode; address relative to beginning of current program [#] ) Octal Number Mode The conventions for numerical input were explained in 3.2.1. On output, octal numbers without leading-zero suppression are used to represent instructions in octal mode, 3.2.6 (e.g., 060¢1¢ for DAC*L...I1¢). Transfer Vector Mode In this mode, bits ~-2 of the word to be output are ignored if they are zero. If bits ~-2 are non-zero, they are printed as an 18-bit octal number preceding the address, e.g., LABELl -+\W~~~il+ALPHA-+\ If the address mode is relative, the symbol table is searched according to the current header for the address which is nearest in value to the value of bits 3-17 of the word to be output. within 1il~ If its value is octal of the word to be output, this address symbol is typed followed by either + or - and the difference as an octal number. Since the same symbol in the symbol table may represent more than one address, care must be taken on input of addresses. Since transfer vectors in FORTRAN are defined locally and globally with the same symbol, the following seemingly legal attempt to restore the value of a location fails: The contents of local symbol TAN now contains, not the global address of the beginning of the tangent routine, but the address of the transfer vector TAN (its own address). On input, local symbols of the cur- rent subprogram always take precedence over globals. address mode, the 18-bit address is output in octal. 3-8 In absolute DDT Language and Syntax In floating address mode, the address is output as relative to the symbol #, which represents the first address of the subprogram loaded into the area of memory containing "point" (the last opened register) . In symbolic address mode, the address may be printed as in floating mode, if a symbol within symbol table. 1~~ octal of the address is not found in the Likewise, an address to be printed in floating mode will be printed in absolute mode, if it is less than the current value of #. 3.2.7 ASCII Text (Output Only) The locations ~ and .+1 are interpreted as ASCII 5/7 packed data if typed in this mode (e.g., ABCDE is output for 3-9 4~6~5~, 342212). CHAPTER 4 DEBUGGING WITH DDT All DDT commands and features are described in this section. Refer- ences to earlier sections are made to avoid redundancy. 4.1 LOADING A PROGRAM See SECTION 2.1. 4.2 STARTING A PROGRAM When the Linking Loader has loaded DDT and the user's programs and gives control to DDT, DDT sets the value of the special symbol SA# (start address) equal to the starting address of the main program. To command DDT to start the user's program at a given location, type: K$G where K is an expression whose IS-bit value is the address to which DDT will Go. In the absence of ~, the default argument SA# (start address) is used. there, type: If K is missing, To first change the value of SA# and then go (i.e., i$G), SA# will not change. enter his program any place between P#' and C#. 4.3.2E.) The user may (See Section Any other address will be rejected and DDT will type a question mark. The following two points should be remembered when reading the subsequent section on the "proceed count" and "proceeding after breakpoint": 4-1 Debugging with DDT 1. The $G command always sets the proceed count to 1. 2. The $p (proceed) command will also start the program when~here has been no breakpoint break from which to proceed. If a started program seems to be malfunctioning and the user wants to go back to DDT, then typing tT (CTRL T) will cause the Monitor to give control to DDT, which will give the go ahead signal ( » . 4.3 REGISTER EXAMINATION AND MODIFICATION 4.3.1 Type-Out Mode Commands 'I'he type-out mode commands (see section 2.3 and also Appendix A, Sections B and C) dictate the form in which DDT will print instructions and addresses, unless specifically overridden by the command being executed. When first loaded, DDT assumes $S (symbolic instruction mode) and $R (relative symbolic address mode). The commands to set the type-out modes do not take arguments; if arguments are supplied, they will be ignored. If a supplied argument contains an undefined symbol, DDT will type: -I> u to indicate that the preceding symbol is undefined and that the command was ignored. The undefined symbol is encountered, in this case, before DDT has a chance to determine that the command requires no argument. This is because DDT does not buffer the command text but, instead, interprets it as it comes in, character by character. This pertains to all command input to DDT. When the type-out mode command has been accepted and executed, DDT will respond by performing a carriage-return, line-feed and typing: > Whenever DDT is expecting command input, the type-out modes may be changed without affecting other DDT operations, e.g., an open register remains open. 4.3.2 Special Symbols and Concepts Register examination and modification requires the user to carefully coordinate certain basic concepts. 4-2 Debugging with DDT A. The single character "pointer" (.) usually represents the address of the last register to have been opened. "Pointer" is often used as a default argument to DDT commands. Under the following conditions, the value of "pointer" will be modified as indicated: 1. Immediately after a breakpoint is reached and control is returned to DDT, the value of "pointer" will be the address of the register whose contents are typed out after the break (a feature to be discussed later). 2. After tT (CTRL T) has been typed and control has returned to DDT, the value of "pointer" is the address of the instruction that was to have been executed. The user may determine at what location program execution was suspended simply by typing: or which are two forms of retype commands. The user may restart the program at the pointer where it was interrupted by typing: $p provided that the program was not interrupted while control was in the Monitor. Device handlers are not loaded with the user program units or DDT. 3. When DDT is started or restarted it prints: DDT XVM Vnxnnn > At this time the value of "pointer" is set from the value of the starting address, SA#, which is initially the starting address of the main program. 4. After one of the search commands (discussed below) has been executed, the value of "pointer" is set to the address of the last register typed out during the search. If no register was typed out, the value of "pointer" is not changed. B. The "current location", which is represented by the symbol. in MACRO programs, differs at times from the value of "pointer" used by DDT. The current location does not have a special symbol associated with it. When a register is opened for examination by any command, except $Z, the current location and the value of "pointer" are the aadress just opened. The values of "pointer" and the current location will differ when the sequencing command 1! is used (see below). C. The areas of memory occupied by each user subprogram, including the main program, are defined by the "header" file names which appear in the symbol table built by the Loader and which contain the relocation factors (load addresses) of each subprogram. The free memory space "'Thich exists immediately above the Loader-built 4-3 Debugging with DDT symbol table (see memory map in Appendix C) is treated as a pseudoprogram to which DDT has assigned the file name P#' (recall that the ' declares the symbol to be a file name). ~his symbol represents the first location (relocation factor) of the patch file area (free core). This area is used to insert additional code at runtime. D. The special symbol # represents the first location of the subprogram which occupies the area of memory containing the address "point". The one exception, which does not change the value of #, is when "point" has been modified following the execution of a search command. The sub-program containing the address "point" will be referred to as the current subprogram. The implications of this are best explained by example, using some of the basic commands described in section 2. Each line in the example is numbered and the comments are keyed to these line numbers: Example 1 2 3 4 5 6 7 8 9 >g) >PRGA'=003000 ~ ) >PRGB'=004000 ~ ~ >PRGB'/ -to\LAC #+100-1 -#=004000 >.=004000--1 ~BEGIN ~ >PRGA' / --I DAC #+3 ~ #=003000 >.=003000-\.......:...START >BEGIN/ ....jLAC #+100 #=004000 T 7" >.=004000~ In line 1 the command sets the address mode to floating number) . (#+ In line 2, the value of the file name PRGA' is 3000 (program PRGA starts at location 3000). In line 3, the value of PRGB' is 4000 starts at location 4000). (program PRGB On line 4, the register whose address is the same as the value of PRGB' (register 4000) is opened and its contents are printed as a symbolic instruction with a floating address (#+100). The value of # and. at this point is 4000, which means that the current program is PRGB and that its relocation factor (#) is 4000. Therefor~he LAC instruction, if executed, would load the accumulator with the contents of location 4100. On line 5, . is retyped as the symbol BEGIN. Therefore, PRGB has a local symbol called BEGLJ which refers to the first location in that program. Assume for the moment that PRGA and PRGB do not use any identical symbols. 4-4 Debugging with DDT On line 6, PRGA' is opened. This changes the value of . to the value of PRGA' and makes PRGA' the current program. Since ~ is now located in PRGA and no longer in PRGB, the value of # is changed to 3000, the relocation factor of PRGA. On line 7, . is retyped as the symbol START, a local symbol in PRGA:On line 8, the register BEGIN is opened. If BEGIN had been defined locally in PRGA, the value of # would not have changed (since . would still have been located in PRGA). Since BEGIN Is located in PRGB, PRGB is made the current program and! is changed accordingly. When searching the symbol table for the value of a symbol, DDT searches the local symbols of the current program before those of other programs and uses the first match it finds. E. DDT will not allow core outside a specified range to be modified by command 1 . The area that may be modified includes the auto-index registers, the core area between the symbols P#' and e# and the core area between TP# and the top of core. TP# is the address of the first location above the bootstrap. P#' is the address of the lowest register in the patch area. e# is an address within DDT which contains the two's complement value of the "proceed count". Immediately below e# are other special DDT addresses, such as, A# (the address of the saved AC). All the special DDT addresses preceding and including C# may be modifiec. by command to DDT. The core between the patch area and these special DDT registers is where the user's programs are loaded. A breakpoint may be placed anyvvhere in a user program or in the patch area, but is may not be placed at an auto-index register nor within DDT. In systems with XVM mode enabled, uninitialized COMMON blocks are loaded starting at TP# and going up in memory, if there is room. F. If a register is opened which is below the patch area, the current program will not change since no file name exists for registers below P#'. The user may, however, define a file name with a value less than P#' for the purpose of examining lower core. G. The special symbol Q#, which is often used as a default argument to DDT commands, assumes the value of the contents of the most recently opened register or the value of the argument to the last intervening retype command. ISee section 4.7.7 for exceptions. 4-5 Debugging with DDT Example: >LOCI ~ ~ >./ 123456 123457 123456 Register LOC is opened and contains 123456. Note that at this point the value of Q# is 123456. Then the contents of register LOC is increased by +1, utilizing Q# to represent its current contents. 4.3.3 Register Examination Commands The basic register examination command is where ~ L. Typing the command KI, is an expression, will open register K and print its contents in the current modes. equivalent to The default argument is "point" (i.e., L is L) . If L is replaced by 1, printout is temporarily forced into octal mode. (If 1 is preceded by ALTMODE (1), then octal becomes the permanent instruction mode.) If I is replaced by 1, printout is temporarily forced into symbolic mode. (If 1 is preceded by ALTMODE, then symbolic becomes the per- manent mode.) If L is replaced by ~, printing of register contents is omitted until the next occurrence of a carriage return command. (This mode, called "type-in mode'.', allows for rapid code insertion.) If any register examination command is followed by?), an attempt was made to open a nonexistent register. Examples: >~PR-l! JMP* SUBR >. [ 623115 >~L JMP* SUBR >. $ [ >~:T 623115 623115 >.:.1. >. < JMP* SUBR i- ADR ADR+l > T (print in current modes) (force octal) (modes haven't changed) (permanent mode change) (mode now octal) (force symbolic) (contents are not printed out until .; encountered) "2 4-6 Debugging with DDT 4.3.4 Expression Retype Commands Alternative representations of the contents of a register or of an expression may be obtained by using retype commands (see Section 2.4). Where K is an expression, K= means retype K in octal K+- means retype K in symbolic K: means retype K as a transfer vector K? means retype the contents of "point" and the following register as 5/7 ASCII text (!5. unused) . In each case above, the value of Q# is set to the value of K. The default argument, if K is missing, is the current value of Q#. Retype commands force a temporary mode change; they do not alter the setting of the type-out modes. 4.3.5 Register Modification Commands The basic register closing and modifying command is carriage return ( )). If !<) is typed when a register is open, then the value of K (expression) becomes the contents of the open register and the register is closed (!5. becomes the value of Q#). ister is closed without modification. If!5. is omitted, the reg- If no register is open, none is modified and K becomes the value of Q#. will type >. The command ~ also turns off type-in mode, the tempo- Upon completion, DDT rary mode which allows the user to insert code without having to wait for DDT to print the contents of each register. In addition to ) -2 there are "sequencing commands", which behave like in that, if given an argument !5., !5. replaces the old contents of the open register (assuming one is open) and then that register is closed. Then a new register is opened. low, with the exception of current register. ~, For every command listed be- the newly opened register becomes the The significance of this will be explained in the example. K~ (Line Feed). Modify the open register, close it and then open the next register in sequence. Kt Modify the open register, close it and then open the register preceding the one just closed. 4-7 Debugging with DDT Modify the open register, close it and then open the register whose address is contained in the address part of K. K is assumed to be a memory reference instruction. The address part (12 or 13 bits, page or bank mode, respectively) is taken, and that address (in the same memory page or bank as the now closed register) is opened. If K is missing from the command, the address part of the contents of the closed register is taken. In other words, the argument to $Y is always Q#. This command is identical to $Y with the exception that the newly opened register-is not made current (the current register and the value of . now differ) . $Z is useful for examining literals without breaking program sequence; that is, subsequent use of + or t will refer to the current register, not the one opened by g. This command is similar to iY. It modifies the open register, closes it and then, treating K as a IS-bit transfer vector, opens that address. If DDT types a question mark after any of these commands, either the command was not properly received (unlikely) or an attempt was made to alter a location outside the allowable range (autoindex registers 1 and P#' through C# and TP# through the top of core) . In either case, the command is ignored. Example >LOC/ LOC+l LOC+2 ~ i~W - I :\ ~AC LIT12$Z DAC TMP ~+ JMS* TV ~ ~Y DAC ARG- 77-.1 :- S UBRI -+j $J ~o SUBRl+l~ CLL!CLA -IT -I T - >SUBRl+l~ CLL!CLA ~~TL!CLA) SUBRl+2-.1 SAD XYZ-2 -I t Note that the addresses opened by the commands $Y, printed by DDT. g and $J are not Note that $Y after JMS* TV opened register TV and printed its contents as if i t were an instruction. This did not look right, so _ was typed to request reprint as a transfer vector. The use of $Y or $Z following indexed and indirect instructions, such as, Isee Section 4.7.7. 4-8 Debugging with DDT will not perform the indexing nor indirection to determine the address of the next register to be examined. would be opened. In this example, register TAB If the user wishes to effectively iDsert code in his program, he must, in general, modify two registers in his program: one to JMP* through a transfer vector and the other to the transfer vector point to patch space in free core (which might not be in the same core bank or page as the user's program). Patch space begins at the register P~' goes as high as the address stored in register 103 (.SCOM+3). and The user should be aware that making patches in locations higher than the value in 103 will overlay the user's program. Besides the method of opening and modifying registers there are special instructions available for initializing memory between limits to a constant and for updating the values of special DDT registers. These commands will be discussed under later headings. 4.4 DEFINING A SYMBOL In addition to the symbols passed on to DDT by the Linking Loader, the user has the option of defining additional symbols at run time. These "DDT-time" symbols are added to the end of DDT's symbol table (see Appendix C) . The symbol S, which must be a unique symbol, is given the value of the expression E. (~) is equivalent to o (S) • ~ The symbol S is given the value of "point". Only these "DDT-time" symbols may be redefined. Symbols may be deleted as follows: (no argument) will Kill (delete) all DDT-time symbols. will Kill all the user's load-time symbols. This would only be done, presumably, to increase the available patch space (p#' will be suitably redefined). If the user attempts to define any symbol which is not a DDT-time symbol, DDT will ignore the command and type an X. If he attempts to define a symbol when the DDT-time symbol table is full, DDT will ignore the command and type an 0 (Overflow). 4-9 Debugging with DDT 4.5 SEARCH OPERATIONS There are three search commands, each of which searches inclusively between a lower core limit and an upper core limit for words or parts of words which have or do not have a specified value. The search com- mands use as arguments the values in three special DDT registers: M# search mask LO# lower limit search address HI# upper limit search address Each of these registers may >M#/ LO# R# -..j --I -..j be individually modified, e.g., 777777 012252 025611 7700004l4000 414400 ) > Notice that these registers appear sequentially in memory. (The symbol R# is equal to HI# and will be printed instead of HI#.) The contents of LO# and HI# may be modified directly by command: where A and B are expressions. the value in HI# to B. free core patch area) This sets the value in LO# to A and The default arguments are P#' and L# (beginning of (the address of the saved value of the Link within DDT). A# (the saved AC) is the first register in DDT and L# is the second. LO# is initially set to P#' and HI# to L#. The initial contents of the mask, M#, is 777777 (all ones). The first command is the Word Search: searches through every core register between the limits set in registers LO# and HI#, inclusively, for words whose values match the value of ~ (an expression) in those bit positions specified by l's in the corresponding bits in the mask argument ~. For example, to search for all words between locations 100 and 200, equal in value to JMP BEG, type: 4-10 Debugging with DDT 100;200$L 777177 ;JMP BEG$W Of course, if LO# already contains 100, HI# contains 200, and M# contains 777777, the user need only type: JMP BEG$W Specifying a mask in the $W command does not cause the contents of M# to be modified. To search for all words between locations 100 and 200 whose Op code parts contain JMP, type: 100;200$L 740000iJMP$W Note that the mask is set so that only the high order 4 bits (the Op-code bits) are tested for a match. To print out the contents of registers 100 through 120, type: 100;120$L Oi$W Zero is used as a mask so that there is no possibility of a mismatch. The second argument is immaterial and was, therefore, not given. The default arguments for MiK$W are the contents of M# (if M missing) and 0 (if K missing) . The second command is the Not Word Search: MiK$N It is identical to $W except that the search is for words which differ from rather than match K in the masked bit position. For example, to print all registers between locations 100 and 200 whose contents are non-O, type: 100;200$L $N 4-11 Debugging with DDT (Note that 0 is the default value of K. It is assumed, In this ex- ample, that M# contains 777777). The third command is the Effective Address Search: MiK$E The default arguments for M and K are, as above, the contents of M# and 0, respectively. $E searches core between the limits specified by LO# and HI# for all memory reference instructions which directly or indirectly reference the address ! (an expression), testing for a match only in those bit positions specified by l's in the mask. (Bits 0-2 are always disregarded.) The following example gives a good indication of the usefulness of this command. It is desired to know all the registers between loca- tions 1000 and 2000 which reference auto-index registers: 1000;2000$L 777770; 10$E To search for all references to ADR+l, provided that the mask and limits contain the desired values, one need only type: ADR+l$E The contents of the hardware index register are saved in and restorec from XR#, and an effective address search which encounters indexed instructions will use the value in XR# as the index. During any of the three search operations whenever a condition is met (match or no match), DDT prints the octal address of the memory word which satisfies the search constraints, prints a tab, prints the contents of that memory location in the prevailing type-out modes and types a carriage return. limit is exceeded. The search then continues until the upper At the end of the search, the value of "point" is set to the address of the last register printed in the search map (the current register remains unchanged). if no printout occurred. 4-12 "Point" remains unchanged Debugging with DDT 4. 6 BREAKPOINTS 4.6.1 Definition A "breakpoint" is a pre-selected point in a program where the flow of the program is broken to allow the user to perform DDT functions. Whenever it is about to give control to the user's program, DDT saves the instruction at each breakpoint and replaces it with a JMS* 17 inl struction. DDT also stores a return pointer to itself in auto-index register 17. Thus, whenever a breakpoint is reached, control is trans- ferred to DDT to allow the user to examine and alter registers, search, etc. When the user signals DDT to continue execution of his program ($P), the instruction that was originally at the breakpoint location is simulated and then DDT transfers control to the register following the breakpoint. The user's program must not modify the auto-index register that DDT uses for breakpoint returns. Up to four breakpoints may be set to facilitate debugging when there is uncertainty as to which path a program will follow. 4.6.2 Setting Breakpoints Initially, all four breakpoints are cleared (unassigned). The general form of the breakpoint command is: NiA$B where N is a breakpoint number (1 to 4) and ~ is an expression evaluated to a lS-bit address. N This causes DDT to assign (set) breakpoint at location A (provided that the value of A is non-O; see below). For example, to set breakpoint 2 at location ADR, type: 2iADR$B It is possible to reset a breakpoint to some other address without first deassigning that breakpoint, e.g., if breakpoint 2 had been set at location XYZ, the preceding command (2iADR$B) would supersede the earlier (XYZ) assignment. lA command exists to tell DDT to use some other auto-index register for breakpoints (discussed later). 4-13 Debugging with DDT If the argument A is missing, the default argument is "point". example: For ADR/ ~ LAC TMP ~ 3; $B This sets breakpoint 1. at location ADR because "point" has the value of register ADR. (3;$B is equivalent to 3;.$B.) If the user does not care which breakpoint number is used when assigning a breakpoint, he can, simply by leaving out the first argument ~, request DDT to assign an unused breakpoint number. For instance, as- suming all four breakpoints are available, to set a breakpoint at location ~, type: X$B DDT, finding breakpoint 1 unused, then types a 1 to indicate which number it selected, i.e., If all four breakpoints are already in use, DDT types a question mark: X$B? and ignores the command. If register X is outside the legal range of registers which may have breakpoints (p#' to C#),l DDT types: X$Bl? indicating breakpoint 1 is free but X is illegal, and then ignores the command. In addition to assigning and reassigning breakpoints, the user may remove (clear) them. This is signified by a value of 0 for the argu- ment A. The input removes breakpoint N (1 to 4). If N is absent, the input removes all breakpoints. 1 See Section 4.7.7. 4-14 Debugging with DDT When a breakpoint is set at a given location, the contents of that location are not changed, e.g., >&. -I LAC >X/ -I LAC TMP TMP -I $B The swapping of the contents of X with a JMS* 17 occurs only when DDT gives control to the user program. 4.6.3 Breakpoint Restrictions It has already been mentioned that DDT will not allow breakpoints to be set at locations outside the range P#' to c#.l The user must not set a breakpoint at locations containing: a) instructions which are program modified b) instructions which are used as constants (operands of other instructions). This is because the actual instruction in a breakpoint location is changed by DDT, prior to program execution, to a JMS* 17 (or some other autoindex register). If a breakpoint is set on a CAL or XCT instruction and a break at such a location occurs, DDT remembers this fact. If the command is then given to proceed with program execution where it left off, the breakpoint is removed and replaced by the original CAL or XCT. This is done because DDT cannot simulate the CAL (which has a variable number of arguments following it) out of place. The XCT cannot be simulated out of place since XCT can execute a CAL instruction. How- ever, should control return to DDT via some other breakpoint, the breakpoint on the CAL or XCT will then be reinstated. Should the user wish to place a breakpoint on a CAL instruction, the following practice will always ensure that the breakpoint remains set on the CAL. Example: CAL 3 12 LAC BUFF (set breakpoint 1) (set breakpoint 2) lSee section 4.7.7. 4-15 Debuggina with DDT The CAL used above is the macro expansion of the Monitor call: .WAIT 3 Placing a second breakpoint on the register immediately following the CAL and its arguments (the return point) at the CAL will always be reinstated. ensures that the breakpoint An additional feature in the breakpoint logic, which is explained later, allows the user to specify breakpoint 2 (above) so that it never causes a break (breaks and then immediately continues). This makes breakpoint 2 "transparent" or "invisible" . 4.6.4 Flow of Control at Breakpoints When execution of the user's program reaches a breakpoint, control is returned to DDT. At this point, DDT executes what is called a "con- ditional break instruction." If this instruction does not cause a skip (e.g., NOP), which is the usual case, then DDT decrements the "proceed count". If this causes the proceed count to be equal to zero, a break occurs. If not, DDT will simUlate the instruction which was replaced at the breakpoint (by a JMS* 17) and then return control to the user's program at the address following the breakpoint register. In other words, the break does not take place. There is only one proceed count for all four breakpoints. As the name suggests, the proceed count is a value specified by the user indicating how many times breakpoints are to be reached before a break is to occur. It is particularly suited for specifying the number of times a loop should be executed. The proceed count will be discussed later on. If the conditional break instruction causes one register to be skipped (e.g., SKP or SPA with the AC positive) the program continues without a break and without decrementing the proceed count. This is the "invisible" breakpoint discussed in section 4.6.3. If the conditional break instruction causes two registers to be skipped (explained below) DDT will always break, without altering the proceed count. Each breakpoint ~ has its own conditional break instruction, which the user may examine and modify directly by opening register I#+N (N = 1 to 4). Initially, when a breakpoint is set with the $B com4-16 Debugging with DDT mand, the contents of the associated conditional break instruction register, 1#+N, is set to NOP. NOP does not skip, so the break will be determined by decrementing the proceed count. After the $B com- mand, one may modify 1#+N to contain any instruction one likes (e.g., CLA!SNL or LAC* 10 or JMS* V#+N). The first of these will decrement the proceed count only when the Link is zero and continue otherwise. The second always decrements the proceed count but, in addition, effectively inserts one instruction prior to the breakpoint. The third allows the user to call one of his own subroutines when the breakpoint is reached. The subroutine, when it returns, can decide whether to skip two, skip one, or not skip, simply by incrementing its entry point twice, once, or not at all. V#+N, shown in the last of the three examples, is a register for breakpoint ~ set aside by DDT specifically to be used to store the transfer vector for a conditional break instruction which needs to make an indrect memory reference. So, for example, if the user wants to call subroutine TEST, when breakpoint 2 is reached, he types: 1#+2< ~ JMS* V#+2$Z) ~ TEST~) (Recall that when opening a register using < as a command, DDT does not type out the contents of that register.) The user is warned not to insert JMP .+3 in a conditional break register, expecting a double skip. "Point" will not have the correct value to be able to do this. One may set the conditional break instruction directly, without having to open 1#+N, by using the command: where N = 1, 2, 3 or 4 to indicate the breakpoint number. This com- mand also takes a second argument, but it is immaterial to this discussion. $N (with argument ~ missing) sets 1#+N to NOP (no skip) O;$N sets 1#+N to SKP (skip 1) l;$N sets 1#+N to skip 2 locations 4-17 Debugging with DDT Only the last bit in argument X is used to determine what is placed in I#+N. The effective flow chart for the break/no break decision is as follows: EXECUTE CONDITIONAL BREAK INSTRUCTION: XCT I#+N 1 SINGLE SKIP o 2 NOSKIP DOUBLE SKIP $p COMMAND (PROCEED) CONTINUE USER PROGRAM Flow Chart, Break/No Break Decision 4-18 Debugging with DDT 4.6.5 What Happens on a Break When a break occurs, DDT makes three checks: a) If the break comes from a location not known to be a breakpoint (if the user's program accidentally executes a JMS* 17), DDT reinitia~izes itself and types: DDT XVM Vnxnnn > It is not possible to proceed from such a breakpoint. b) If the break comes from a known breakpoint but PI (program interrupt) is disabled, the same action as above will take place. Therefore, breakpoints should not be placed in routines which operate with PI off. c) Also, if API is active when the break occurs, DDT will type the contents of the API status register: AP I -to! 4 XXX XX One may not proceed from such a breakpoint. Any other command is valid, including a command to delete this breakpoint. If a valid break occurs, DDT will type the breakpoint number N followed by a tab and the contents of a register (specified by the address in R#+N) in the prevailing typeout modes, e.g., 1 R#+N (N -to! 7 7 6 4 0 3) = 1 to 4) is a special register associated with breakpoint N (as are I#+N and V#+N). Initially, when a breakpoint is set with the $B command, R#+N contains the address of A# (the stored AC). There- fore, if the user does not alter R#+N, the contents of the AC will be printed ~hen a break occurs. The user may change the address in R#+N in either of two ways: one is to open and modify the register,e.g., 4-19 Debugging with DDT the second is by using the command: A;B$N The first argument ~, changes the contents of I#+N (N = 1 to 4) as Argument ~ specifies the address whose discussed in section 4.6.4. contents are to be printed when a break occurs at breakpoint N. This address is stored in R#+N. For example, 0;4004$1 will set the conditional break instruction in 1#+1 to skip a location when executed. Since this means a break will never occur, the second argument is unimportant. 1;4004$1 will set 1#+1 so that a break will always occur and print: 1 ~ contents of 4004 The default argument for ~ is A#. If 0 is stored in R#+N, when the break takes place only the breakpoint number will be typed. When breaks occur, DDT saves the contents of the AC, Link, MQ, Index Register, and Limit Register in the special DDT locations addressed by the symbols A#, L#, MQ#, X#, and LR#, respectively. Once DDT has stopped typing after a break, the user is free to type commands. Typically he would examine certain program registers, perform searches, set and reset breakpoints and make program corrections. Then he may continue program execution at the point where the break occurred by typing: This command places the value of the expression !i in the proceed count (the default value is 1) and proceeds by simulating the instruction at the breakpoint (the one saved and replaced by JMS* 17) and 4-20 Debugging with DDT gives control to the user program at the location immediately following the breakpoint. If control returns to DDT because the user types tT (CTRL T), ~ may be used to continue program execution from where it was interrupted. Normally, when no breakpoint has been reached, the $p command will not be accepted since there is no address from which to proceed. However, after DDT has initially been loaded or restarted and has printed: DDT XVM Vnxnnn > the command $p (as $G) starts the user program at the location specified in SA# (the start address). Recall that the $G command always sets the proceed count to 1. For convenience, the symbols Bl#, B2#, B3#, and B4# are defined as (If breakpoint ~ is not set, BN# the addresses of the breakpoints. will be defined as 0). DDT never uses these symbols on output, but the user may use them on input to DDT. If breakpoint 1 is set at register 4000, which contains instruction CLA, then the following commands yield the indicated results: Bl#/ -I CLA Bl#=004000 As already mentioned, DDT initially assumes the use of auto-index register 17 for breakpoint returns. The command: where A is an expression which must evaluate to 10 thru 17, commands DDT to use auto index register A for its breakpoint return. For example: 11$0 will change the breakpoint instruction to JMS* 11. of the argument A is 17 4.6.6 The default value (iQ is equivalent to 17$0). The Execute Command Built into the DDT breakpoint processor is the facility to allow execution of single instructions. By giving the command: 4-21 Debugging with DDT I$X the user may execute the instruction I (an expression). For example, CLA!CLL$X LACL-ISUM$X The first example will clear registers A# and L# (the saved AC and DDT will type ? and ignore the command if an attempt Link in DDT). is made to execute a CAL instruction, an XCT instruction or an EAE instruction which requires a memory reference to pick up an argument (e.g., MUL). The default instruction, in the absence of !, is the instruction at location npointn executed as if it were located at npoint". The reason for this is that if it is a memory reference instruction, it must be executed in the proper memory bank. If the executed instruction causes a skip, DDT indicates this by typing an extra carriage return. to return to after a break. However, it does not alter the address For example, assume that breakpoint 1 was set as indicated in the following code and that a break at that location has occurred: LAC (1 DAC TMP (breakpoint 1 set here) TAD ADR A B The break occurs after LAC (1 has been executed and before DAC TMP is executed. If the user now types: SKP$X $p program execution returns to location B after the DAC TMP is simulated. The SKP does not cause a skip. One may execute a call to a subroutine: JMS SUBR$X provided that SUBR does not expect to pick up arguments following the JMS nor skip more than one location on return. 4-22 Debugging with DDT 4.7 MISCELLANEOUS FEATURES 4.7.1 Operate Link and AC The command: will set the Link (L#) from bit 17 of the value of the expression M and the AC (A#) from the value of N. The default values of both arguments are ~, so that $U will clear the Link and AC (equivalent to CLA!CLL$X) . 4.7.2 Make Subprogram Current (Header Command) The header command is used primarily to make a particular subprogram current, thus giving preference to its local symbols when DDT performs a symbol table search. The argument ~ The form is: is usually a filename (e.g., PRG1'), but it may be any unique address symbol. This command makes address tion, sets the value of "point" equal to ~ ~ the current loca- and makes the program con- taining that address the current program. 4.7.3 Initialize Memory The command where N is an expression, will change the contents of all memory words between the limits in LO# and HI# to the value of argument is 4.7.4 N. The default ~. Loading DDT without a Program DDT can be used to create programs on-line and it is not necessary to load any user programs when DDT is called in. This is done by typing tT (CTRL T) when the Linking Loader has typed: LOADER XVM Vnxnnn or BLOADER XVM Vnxnnn > > 4-23 Debugging with DDT When DDT is started, core has been cleared between P#' and C#, and no load-time nor DDT-time symbols exist. 4.7.5 Restarting nDT The use of tT (CTRL T) to interrupt a user program and return control to DDT has been previously explained. tT may also be used to abort a search operation which is in progress. 4.7.6 Typing Mistakes If the user discovers that he has made a typing error while inputting a command, he may type tv (CTRL V) or rubout, both of which are echoed as @, to delete the entire command. 4.7.7 Protect Mode Commands In order to avoid serious errors, a subroutine in DDT is used to validate addresses before certain commands are executed. The following commands are protected: (~) a. Proceed following a iT b. Go c. All register modifying commands d. Breakpoint (~) (~) Except for references to the autoindex registers in register modification commands and addresses within the range TP# and the top of core, addresses used by these protected commands must fall within the range P#' to C#. This restriction prevents the user from altering the Moni- tor, DDT's symbol table, DDT itself, or the bootstrap. The following two commands affect the protect mode: Disables the protection feature, thereby allowing the user to modify and transfer to any location in core. DDT will not check for nonexistent memory references. ~ 4.8 Reenables the protection feature. ERROR RECOVERY sections 2.11, 4.7.5 and 4.7.6 explain how to correct typing errors and how to stop a runaway program. 4-24 Debugging with DDT The following DDT-generated error messages are not fatal: U (undefined symbol) X (illegal symbol definition) a (DDT-time symbol table overflow) ? (general error message) API (breakpoint reached with API level active) Commands which cause these errors are ignored. The "API" error mes- sage signifies that one may not proceed from such a break. Errors which are caught by the Monitor (IOPSXX) mayor may not be fatal. After unrecoverable lOPS errors, control can then return to DDT if the user types CTRL T (tT). If an error is trapped by the FORTRAN Object Time System (OTS) , which prints .OTS XX, it will exit to the Monitor. at that point. 4-25 No recovery is possible APPENDIX A SUMMARY OF DDT COMMANDS A. EXPRESSION OPERATORS logical inclusive or. & "+ Logical and. Logical exclusive or. Two's complement sum. Two's complement (unary minus) or subtract. (space) Two's complement sum, but prohibit change of top 6 bits in this and remaining operations in the expression. * B. C. Two's complement sum and exclusive or indirect bit to value. (20000) INSTRUCTION MODE COMMANDS $S (Symbolic) Print symbolic instructions. $0 (Octal) Print instruction as six unsigned octal digits. $V (Vector) Print bits 3-17 as a transfer vector in the current address mode. If bits 0-2 are nonzero, precede the address printout with these bits as a 6-digit octal number whose rightmost 5 digits are zero. $T (Text) $$R (Text) Consider registers "point" and "point-pIus-one" as 5/7 packed ASCII and print the corresponding five characters. Consider the register "point" to be RAD50 and display the 3 characters. $$S (Text) Consider the register "point" to be SIXBIT and display the 3 characters. ADDRESS MODE COMMANDS (Relevant to instruction modes $S and $V and also to tag printouts) . D. $R (Relative) Print addresses relative to the nearest tagged (labelled) location. $A (Absolute) Print addresses as absolute 18-bit octal numbers. $F (Floating) Print addresses relative to #. # is the relocation constant for the current program. SPECIAL ADDRESSES IN AND ABOVE DDT A# Where the AC is stored on breaks. A-I Summary of DDT Commands E. L# Where the link is stored (bit 17) on breaks. MQ# Where the MQ is stored on breaks. LR# Where the limit register is stored on breaks. X# Where the index register is stored on breaks. M# LO# Where the default mask for searches is stored. Where the lower limit address of search operations is stored. HI# Where the upper limit address of search operations is stored. R#+N Where the register to be printed on breaking at breakpoint N is stored. I#+N Contains the instruction to be executed on reacing breakpoint N. V#+N Reserved for the transfer vector possibly used by the instruction in I#+N. C# Contains the 2's complement of the proceed count. TP# Address of the first word of core memory above the bootstrap. Contents of TP# are undefined. SPECIAL ADDRESSES IN USER'S PROGRAM (NOT SEARCHED ON OUTPUT) # Address of the first word in the current program (same as P#' when patch area is current). Address of the last opened register. F. P#' Address of the first word in the patch area (Pseudo file name) SA# Address of the starting location of the first program loaded (originally). B1# Address of breakpoint 1 instruction. B2# Address of breakpoint 2 instruction. B3# Address of breakpoint 3 instruction. B4# Address of breakpoint 4 instruction. CONTENTS OF SPECIAL USER LOCATIONS Q# G. Represents the contents of the most recently opened storage word (never used on output) or value of last intervening retype command argument. DEFINING A SYMBOL E (S) symbol S given value E (expression). S) Symbol S defined as ~; same as ~). $K O$K Kill DDT-time user defined symbols. Kill load-time user symbols. A-2 Summary of DDT Commands H. STARTING A PROGRAM AD$G $G ;AD$G I. J. Start at address AD (expression) • start at address SA#. Set SA#=AD and start there. BREAKPOINT COMMANDS K$B Put lowest available breakpoint at a(:1.dl~ess I< (must be non-zero; default: .) DDT types breakpoint number after the B. O$B Remove all breakpoints. N;K$B Set breakpoint N (default: non-zero; default: .). N;O$B Remove breakpoint N (Default: M;K$N Type out register K (default: A#) when breaking at breakpoint N (1 to 4) (N is part of command and may not be omitted). If ML is missing, normal procedure will be followed at breakpoint. If M bit 17 is ~, breakpoint will never break. If M bit 17 i~ 1, breakpoint will always break. 4) at address K (must be 4). E$O Use auto-index register E (10-17; default: breakpoint instructions. 17) for M$P Proceed from breakpoint and put M (default: proceed count. 1) in REGISTER EXAMINATION AND MODIFICATION ~ Close any open register, depositing its argument in that register. If no argument is given, the register is unchanged. / Close any open register and open another. If an argument is given, it is taken as the 18-bit address of the next register to be opened and made current. If not, the register "point" is opened. LINE FEED t Behaves like~except that it opens the register following the current register and makes the new register current. Behaves like ~ except that it opens the register preceding the current register and makes the new register current. $Y Behaves like ~ except that Q# is taken as the 12 (page mode) or 13 (bank mode) bit address of a location which is opened and made current. $J Behaves like ) except that Q# is taken as the 15 bit address of a location which is opened and made current. A-3 Summary of DDT Commands $Z Behaves like $Y except that the new open register is not made current. [ Behaves like /, but forces the printout to be in numeric mode. ] Behaves like /, but forces the printout to be in symbolic mode. < Behaves like / except that the printing of register contents is omitted until is used to close a register (type-in mode) . I ' = K. Print argument (default: Q#) as an octal number. Behaves like = but causes symbolic printouts. Behaves like vectors. = but retypes expressions as transfer ? Prints out contents of packed ASCII text. $? Prints out contents of . as SIXBIT ASCII. $$? Prints out contents of and .+1 interpreted as 5/7 as RAD5.0. WORD SEARCHES MiN$L Set the contents of LO# to M (default: N (default: L#). MiD$W Search from address in LO# through address in HI# (? if lower than address in LO#) for words which are the same as D (default: .0) in all bits that are 1 in M (default: contents of M#) . MiD$N Search as in $W, but print unequal words. MiD$E Search as in $W and $N for memory reference instructions effectively addressing (directly or indirectly) an address which is identical to D (default; .0) in every bit which is 1 in M (default: contents of M#). L. p#') and HI# to OTHER DDT COMMANDS I$X tu RUBOUT C$H MiN$U N$M tT Execute instructions I (default: if located at address "point"). contents of "point" as Wipe out current command. Same as {U. Make the address C (e.g., FILE') current, but do not open it. (Default: SA#). Update contents of L# to M (default: of A# to N (default: .0). .0) and the contents Initialize memory from address in LO# through address in HI# to N (default: .0). Interrupt -- transfer control to DDT. Used to stop a runaway program or to abort a long search operation. A-4 Summary of nDT Commands Enable Protect mode. $0 r-~. N. Disable Protect mode. Allow modifications of and transfer to any location in core. ERROR MRSSAGES ? General error indication. Command ignored. x symbol definition command attempted to redefine a nonDDT-time symbol. Conmand ignored. u Symbol just used is undefined. API A breakpoint has been reached with API active (cannot proceed) . o Symbol table capacity has been exceeded by symbol definition command. Command ignored. Command ignored. SPECIAL DDT SYMBOLS First argument delimiter for commands with two arguments. Same a.s ; when used with symbol definition commands. $ ALTr-10DE Indicates that the following symbol is a command (used primarily with letters and numbers, which ordinarily comprise expression syllables) . Same as S and echoes as ~. Indicates that the command has been performed by DDT. Same as ». Incticates that the preceding symbol is a file name (must be used with file names for correct operation) . Indicates that the preceding symbol is an ado.ress (omit searching the instruction mnemonic symbol table). * Sets the indirect bit of an argument (20000). ,X Sets the index bit of an argument (10000). Same as ,X. A-5 - ', APPENDIX B MNEMONIC INSTRUCTION TABLE MEMORY REFERENCE CAL DAC JMS DZM LAC XOR ADD TAD XCT ISZ AND SAD JMP OPERATE CLASS 000000 040000 100000 140000 200000 240000 300000 340000 400000 440000 500000 540000 600000 NOP OPR CMA CML RAL RAR IAC SMA SZA SNL SKP SPA SNA SZL RTL RTR SWHA CLL STL RCL RCR CLA CLC GLK LAW EAE GROUP EAE 640000 INPUT/OUTPUT IOT 700000 740000* 740000 740001 740002 740010 740020 740030 740100 740200 740400 741000 741100 741200 741010 742010 742020 742030 744000 744002 744010 744020 750000 750001 750010 760000 INDEX CLASS * DDT interprets 740000 as NOP. PAX PAL AAC PXA AXS PXL PLA PLX CLX CLLR AXR 721000 722000 723000 724000 725000 726000 730000 731000 735000 736000 737000 B-1 -, APPENDIX C DDT MEMORY LOAD MAPS Areas Which the User May Modify Order For Symbol Table Search Top of Core f Free * . SCOM+ 7 7;if Core .SCOM+76" I Uninitialized* Common Block · · · Common Blocks r DDT TP#~ Common Block • SCOM+{J Bootstrap DDT D~T Run-time Symbols DDT Special Symbols continue here Instruction Mnemonics Starts here, unless instructions bypassed Symbol Tabte C#~ DDT Special Registers f"'-.. A# Hain Program subprogram 1 User Programs · · · Subprogram N 1 j Free Core ! I Load-Time symbols * .SCOM+3 J Patch Area .SCOM+~~ Eli ' Subprogram N Symbols · · · Symbols subprogram 1 Main Program The area above the bootstrap is loaded with uninitialized COMMON blocks if XVM mode is ON. Free core above the bootstrap should not be used as a patch area, although it can be used to store additional data. The area above the bootstrap should not be used for any purpose if XVM mode is OFF. Symbols Final Search Here Main Program Has Initial Precedence (Current Program) Resident Monitor Auto I ndex Registers Auto Index Registers C-l INDEX AC operation, 4-23 Addition operator, 3-6 Addresses, A-I Address modes, 2-4 commands, A-I search, 4-12 Address tag, 3-4 Arguments, 3-1, 3-2 missing separator, 3-5 ASCII text, 2-4, 3-9 Bootstrap, 4-24 Breakpoint, 2-7, 4-13 commands, A-3 control, 4-16 number, 2-8 reassignment or removal, 2-9 restrictions, 2-8, 4-15 resume program execution, 2-9 typeout, 2-8 Break procedure, 4-19 Defining a symbol, 4-9, A-2 Double quote (n) character, 3-4 EAE group instructions, B-1 Effective address search, 4-12 Error messages, A-5 Error recovery, 4-24 Errors, typing, 2-9 Exclusive OR operator, 3-6 Execute command, 4-21 Expression operators, A-I Expression retype commands, 4-7 Expressions, 3-5 Floating address mode, 3-9 Format, I/O, 1-1 FORTRAN IV local symbols, 3-5 Global symbols, 3-5 Carriage return (-' 1, 2-3 Changing storage words, 2-6 Closing and reopening locations, 2-3 Commands, execute, 4-21 expression retype, 4-7 header, 4-23 protect mode, 4-24 register examination, 4-6 register modification, 4-7 search, 4-10 sequencing, 4-7 summary, A-I typeout mode, 4-2 Command structure, 3-1 Concepts, 4-2 CTRL U, 2-9 Current location, 4-3 DAT slot assignments, 2-2 Header, 3-3 command, 4-23 Image alphanumeric mode, 1-2 Inclusive OR operator, 3-6 Index instructions, B-1 Initialize memory, 4-23 Input mode commands, 2-6 Input/output format, 1-1 instructions, B-1 Instruction modes, 2-4 commands, A-I Internal symbols, 3-3 Language, 3-1 Last-opened-register-pointer, 2-3 INDEX-l Linking Loader, 1-1, 3-3 Link operation, 4-23 Loading DDT without a program, 4-23 Loading instructions, 2-1 Machine instruction mnemonics, 3-3 Mask, 4-10 Memory initialization, 4-23 Memory load maps, C-l Memory reference instruction, 2-4, 4-22, B-1 Mnemonic instruction table, B-1 Modifying storage words, 2-6 Not-Word search, 4-11 Number (#) symbol, 4-4 Numerical input, 3-2 Numerical output, 3-8 Octal mode, 3-8, 4-6 Opening a location, 2-2 Operate instructions, B-1 Operators, 3-6 Operators, expression, A-l Parenthesis usage, 3-1 Period or point (.) usage, 2-3, 4-3 Pound (#) symbol, 4-4 Proceed count, 4-2, 4-16 Proceeding after a break, 2-9 Protect mode commands, 4-24 Searches, word, A-4 Semicolon (i) usage, 3-1 Sequencing, 2-6, 4-7 Setting breakpoints, 2-7, 4-13 Single instructions, 4-21 Single quote (') character, 3-4 Special symbols, 4-2 Starting a program, 2-9, 4-1, A-3 Stopping a program, 2-9 Storage word modification, 2-6 Subtraction operator, 3-6 Summary of commands, A-I Syllables, 3-2 Symbol definition, 4-9, A-2 Symbolic instruction mode, 2-3, 3-6, 4-2, 4-6 Symbols, 3-2 DDT, A-5 internal, 3-3 used in text, 1-2 Symbol table, 3-3, 4-5 Symbol, undefined, 4-2 Syntax, 3-1 Tabbing, 2-2 Transfer vectors, 2-4, 3-5, 3-8 2's complement arithmetic, 3-6 Typing mistake, 2-9, 4-24 Type-in mode, 4-6 Type-out modes, 2-3 commands, 4-2 Unary minus operator, 3-6 Undefined symbol, 4-2 User locations, A-2 Word search, 4-10, A-4 Reassign a breakpoint, 2-9 Register examination commands, 4-6, A-3 Register modification commands, 4-7 Relative symbolic address mode, 4-2 Relocation factor, 3-3, 3-4 Remove breakpoints, 2-9 Reopening registers, 2-3 Restarting DDT, 4-24 Restrictions, breakpoint, 4-15 Retype commands, 2-5, 4-7 RUBOUT, 2-9 Search commands, 4-10 Search mask, 4-10 INDEX-2 DDT XV~1 Utili ty Nanual DEC-XV-UDDTA-A-D READER'S COMMENTS NOTE: This form is for document comments only. Problems with software should be reported on a Software Problem Repcrt (SPR) form. Did you find errors in this manual? If so, specify by page. Did you find this manual understandable, usable, and well-organized? Please make suggestions for improvement. Is there sufficient documentation on associated system programs required for use of the software described in this manual? If not, what material is missing and where should it be placed? Please indicate the type of user/reader that you most nearly represent. o Assembly language programmer o Higher-level language programmer o Occasional programmer (experienced) o User with little programming experience o Student programmer o Non-programmer interested in computer concepts and capabilities Name Date ___________________________ Organization _______________________________________________________________ Street ___________________________________________________________________ City ___________________________ State _____________ zip Code ______________ or Country If you require a written reply, please check here. o -------------------------------------------------------------Fold lIere------------------------------------------------------------ ------------------------------------~----------- Do Not Tear - Fold lIere and Staple ----------------------------------------------- FIRST CLASS PERMIT NO. 33 MAYNARD, MASS, BUSI\1ESS REPLY MAIL NO POSTAGE STAMP NECESSARY IF MAILED IN THE UNITED STATES Postage will be paid by: Software Communications P. O. Box F Maynard, Massachusetts 01754 digital equipment corporation PRINTED IN U.S.A.
Home
Privacy and Data
Site structure and layout ©2025 Majenko Technologies