Google
 

Trailing-Edge - PDP-10 Archives - decuslib10-03 - 43,50312/mantis.rnd
There are no other files named mantis.rnd in the archive.
.SPACING 1
.PAPER SIZE 58 70
.LEFT MARGIN 5
#
.SKIP 10
.CENTER
^^MANTIS\\
.SKIP 2
.CENTER
^AN ^INTERACTIVE ^^FORTRAN \\^DEBUGGER
.SKIP 2
.CENTER
^VERSION 4
.SKIP 5
.LEFT MARGIN 20
^USER ^DOCUMENTATION: ^CHRISTINE ^MINOR
.SKIP 1
^IMPLEMENTATION: ^LOREN ^SALMONSON
.SKIP 1
^DATE: 15 - ^MAY - 1973
.SKIP 1
^FILE: ^^MANTIS.RNO\\
.SKIP 1
^EDITION: 1
.LEFT MARGIN 5
.SKIP 5
^THIS DOCUMENT PRESENTS A USER-ORIENTED DESCRIPTION OF ^^MANTIS\\, THE
INTERACTIVE ^^FORTRAN\\ ^DEBUGGER DEVELOPED AT THE ^UNIVERSITY OF ^OREGON
AND DESIGNED BY ^LOREN ^SALMONSON AND ^BOB ^HEILMAN.
.SKIP 2
^THE FOLLOWING ^^DEC\\SYSTEM-10 SOFTWARE MUST BE MODIFIED TO RUN
^^MANTIS\\, ^VERSION 4:  ^^FORTRAN\\ ^COMPILER, ^VERSION 26; ^^FORTRAN\\
^LIBRARY, ^VERSION 32; ^LINKING ^LOADER, ^VERSION 56;
AND ^CONCISE ^COMMAND ^LANGUAGE, ^VERSION 21.
.SKIP 2
^THE ^UNIVERSITY OF ^OREGON INTENDS TO DISTRIBUTE ^^MANTIS\\ JOINTLY
WITH ^DIGITAL ^EQUIPMENT ^CORPORATION AND WORK WITH THEM ON ITS
MAINTENANCE.
.BREAK
.NUMBER 0
.PAGE
.LEFT MARGIN 5
.CENTER
^^MANTIS\\
.SKIP 2
.CENTER
^TABLE OF ^CONTENTS
.SKIP 3
1.0#####^^INTRODUCTION\\
.BLANK
1.1#####^EXAMPLE
.BLANK
1.2#####^FUNDAMENTAL ^CONCEPTS
.BLANK
1.2.1###^^MANTIS\\ ^COMMAND ^SYNTAX
.BLANK
1.2.2###^THE ^CURRENT ^PROGRAM
.BLANK
1.2.3###^REFERENCING A ^^FORTRAN\\ ^STATEMENT
.BLANK
1.2.4###^REFERENCING A ^VARIABLE
.SKIP 2
2.0#####^^MANTIS COMMANDS\\
.BLANK
2.1#####^BREAK ^COMMANDS
.BLANK
2.1.1###^A^T ^COMMAND
.BLANK
2.1.2###^^ON CALL\\ ^COMMAND
.BLANK
2.1.3###^^BEFORE RETURN FROM\\ ^COMMAND
.BLANK
2.1.4###^O^N ^COMMAND
.BLANK
2.2#####^^KILL\\ ^COMMAND
.BLANK
2.3#####^ELEMENTARY ^ACTION ^COMMANDS
.BLANK
2.3.1###^G^O ^COMMAND
.BLANK
2.3.2###^^STOP\\ ^COMMAND
.BLANK
2.3.3###^^OUTPUT\\ ^COMMAND FOR ^SCALARS AND ^ARRAY ^ELEMENTS
.BLANK
2.3.4###^VALUE ^CHANGE ^COMMAND FOR ^SCALARS AND ^ARRAY ^ELEMENTS
.BLANK
2.3.5###^^EXIT\\ ^COMMAND
.BLANK
2.4#####^FORMING ^COMMAND ^STRINGS
.SKIP 2
3.0#####^^RUNNING A PROGRAM WITH MANTIS\\
.SKIP 2
4.0#####^^ADVANCED COMMANDS\\
.BLANK
4.1#####^MONITORING ^COMMANDS
.BLANK
4.1.1###^^HISTORY\\ ^COMMAND
.BLANK
4.1.2###^^TRACE\\ ^COMMAND
.BLANK
4.1.3###^^SUBCHECK\\ ^COMMAND
.BLANK
4.1.4###^STATEMENT ^LOCATION ^QUERY
.BLANK
4.2#####^INPUT/^OUTPUT ^DEVICE ^CONTROL ^COMMANDS
.BLANK
4.2.1###^^USE\\ ^COMMAND
.BLANK
4.2.2###^MAGNETIC ^TAPE OR ^DISK ^FILE ^CONTROL ^COMMANDS
.LEFT MARGIN 16
.BLANK
^^BACKSPACE
.BLANK
ENDFILE
.BLANK
REWIND
.BLANK
SKIPRECORD
.BLANK
UNLOAD
.BLANK
RELEASE\\
.LEFT MARGIN 5
.BLANK
4.3#####^MORE ^ACTION ^COMMANDS
.BLANK
4.3.1###^^OUTPUT\\ AND ^VALUE ^CHANGE FOR ^ARRAYS AND ^SUBROUTINE
.BREAK
########^ARGUMENTS
.BLANK
4.3.2###^^TYPE\\ ^COMMAND
.BLANK
4.3.3###^^RESTART\\ ^COMMAND
.BLANK
4.3.4###^^RETRY\\ ^COMMAND
.SKIP 2
5.0#####^^MANTIS RECOVERY FROM COMMON FORTRAN ERRORS\\
.BLANK
5.1#####^OVERFLOW, ^UNDERFLOW AND ^DIVIDE ^CHECK ^ERRORS
.BLANK
5.2#####^ILLEGAL ^MEMORY ^REFERENCE ^ERROR
.BLANK
5.3#####^ILLEGAL ^CHARACTER IN ^INPUT
.BLANK
5.4#####^INFINITE ^LOOPS
.SKIP 2
^A.0#####^^MANTIS COMMAND SUMMARY AND TELETYPE CRIB SHEET\\
.BLANK
^A.1#####^COMMAND ^SYNTAX
.BLANK
^A.2#####^REFERENCING ^^FORTRAN\\ ^STATEMENTS AND ^VARIABLES
.BLANK
^A.3#####^BREAK ^COMMANDS
.BLANK
^A.4#####^^KILL\\ ^COMMAND
.BLANK
^A.5#####^ACTION ^COMMANDS
.BLANK
^A.5.1###^ACTION ^COMMANDS ^WHICH ^MAY ^APPEAR IN ^COMMAND ^STRINGS
.BLANK
^A.5.2###^ACTION ^COMMANDS ^WHICH ^CANNOT ^APPEAR IN ^COMMAND ^STRINGS
.BLANK
^A.6#####^MONITORING ^COMMANDS
.BLANK
^A.7#####^INPUT/^OUTPUT ^DEVICE ^CONTROL ^COMMANDS
.BLANK
^A.8#####^MAGNETIC ^TAPE OR ^DISK ^FILE ^CONTROL ^COMMANDS
.SKIP 2
^B.0#####^^MANTIS DIAGNOSTICS\\
.BLANK
^B.1#####^^MANTIS\\ ^COMMAND ^ERROR ^MESSAGES
.BLANK
^B.2#####^PROGRAM ^EXECUTION ^MESSAGES
.SKIP 2
^C.0#####^^EXAMPLES\\
.SKIP 2
#########^^INDEX\\
.TITLE ^^MANTIS\\ ^CHAPTER 1
.PAGE
.SKIP 3
.INDEX ^^INTRODUCTION\\
1.0 ^^INTRODUCTION\\
.INDEX ^^MANTIS\\ ^USEFULNESS
.SKIP 2
^^MANTIS \\IS AN INTERACTIVE ^^FORTRAN\\ DEBUGGER.  ^IT CAN BE USED TO
GENERATE THE KIND OF DEBUGGING INFORMATION WHICH COULD OTHERWISE BE
OBTAINED ONLY AT CONSIDERABLE PROGRAMMING COST THROUGH THE INSERTION
OF ADDITIONAL ^FORTRAN STATEMENTS AT STRATEGIC PLACES IN A PROGRAM.
^^MANTIS\\ COMMANDS ARE ENTERED FROM A USER'S TELETYPE DURING EXECUTION OF A
PROGRAM TO BE DEBUGGED; THEY ARE ^&NOT\& INSERTED IN THE ^^FORTRAN\\
SOURCE FILE.  ^^MANTIS\\ ALLOWS A USER TO:
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
1.###^SET AN EXECUTION BREAK POINT AT ANY EXECUTABLE STATEMENT, INCLUDING CALLS
AND RETURNS FROM SUBPROGRAMS;
.SKIP 2
.INDENT -5
2.###^SELECTIVELY EXECUTE PORTIONS OF A PROGRAM;
.SKIP 2
.INDENT -5
3.###^EXAMINE AND CHANGE VALUES OF SCALAR VARIABLES AND ARRAYS;
.SKIP 2
.INDENT -5
4.###^DISPLAY AND CHANGE SUBROUTINE ARGUMENTS WHEN A SUBROUTINE IS CALLED AND
BEFORE RETURN FROM IT;
.SKIP 2
.INDENT -5
5.###^TRACE THE FLOW OF PROGRAM EXECUTION;
.SKIP 2
.INDENT -5
6.###^PERFORM SUBSCRIPT CHECKING; AND
.SKIP 2
.INDENT -5
7.###^HALT EXECUTION WHEN ANY SPECIFIED ARRAY OR SCALAR CHANGES VALUE OR
WHEN THE VALUE MEETS A GIVEN CONDITION.
.SKIP 2
.INDEX ^PROGRAMS ^EXPLICITLY ^COMPILED WITH ^^MANTIS\\
.LEFT MARGIN 5
^DEBUGGING MAY BE DONE ONLY ON SOURCE PROGRAMS EXPLICITLY COMPILED WITH
^^MANTIS\\.  (SEE ^CHAPTER 3)
.INDEX ^FILES ^COMPILED WITH ^^MANTIS\\
.SKIP 3
.INDEX ^EXAMPLE
.INDEX ^KEYWORDS, ^^MANTIS\\
1.1  ^EXAMPLE
.SKIP 2
^THE FOLLOWING EXAMPLE SHOWS A ^^FORTRAN \\SOURCE PROGRAM AND THE EXECUTION
OF THAT PROGRAM WITH ^^MANTIS\\.  ^A DESCRIPTION OF ^^MANTIS\\ COMMANDS ILLUSTRATED
HERE WILL BE FOUND IN ^CHAPTER 2.
.LEFT MARGIN 0
.PAPER SIZE 58 75
.SKIP 3
&.^^TYPE SAMP.F4\\
.SKIP 2
.NOFILL
.TAB STOPS 10 30
	^J=0	^TYPE THE SAMPLE PROGRAM .^^SAMP.F4\\
	^^SUM\\=0.0
10	^J=^J+1
	^^ACCEPT\\ 50,^X
50	^^FORMAT (F)
	SUM=SUM+X
	IF (X.NE.0.0) GO TO 10
	AVE=SUM/J
	TYPE 51,AVE
51	FORMAT (' AVERAGE =',F6.2)
	STOP
	END\\
.TAB STOPS 10 25
.SKIP 2
.INDEX ^KEYWORDS, ^^MANTIS\\
.INDEX ^^DEBUG\\
&.DEBUG SAMP.F4\\	A.  ^^DEBUG\\ ^^SAMP.F4\\ WITH ^^MANTIS\\. 
^&^^FORTRAN:  SAMP.F4\&
^&LOADING\&
.SKIP 2
^&MANTIS V3\&
^&CURRENT PROGRAM IS MAIN
READY\\\&
&*^^STOP AT 10+4\\	B.  ^ENTER A COMMAND TO STOP EXECUTION AT THE 4TH
   		 ###^&EXECUTABLE\& STATEMENT AFTER THE STATEMENT 
		####LABEL 10.
^&^^STORED\\\&		C.  ^^MANTIS\\ DISPLAYS ^&^^STORED\\\& TO INDICATE ACCEPTANCE
   		 ###OF COMMAND IN B.
.SKIP 2
&*^G^O		D.  ^TELLS ^^MANTIS\\ TO BEGIN PROGRAM EXECUTION.
10.0		E.  ^VALUES FOR ^X ARE ENTERED.
20.0
30.0
0.0
.SKIP 2
^&<10>+  4\&		F.  ^^MANTIS\\ TELLS USER WHERE IT HAS STOPPED
   		### EXECUTION. (SEE B)
&* ^^OUTPUT J\\	G.  ^OUTPUTS CURRENT VALUE OF VARIABLE ^J.
.SKIP 2
^&###########4\&
&*^J=3		H.  ^J SHOULD BE 3, NOT 4, SO IT IS CHANGED.
.SKIP 2
&*^G^O		I.  ^CONTINUE EXECUTION FROM WHERE IT STOPPED AT
   		 ###THE FOURTH EXECUTABLE STATEMENT AFTER LABEL
		### 10.
.SKIP 2
.INDEX ^KEYWORDS, ^^MANTIS\\
^^AVERAGE=20.00\\
.TAB STOPS 10 28
.SKIP 2
^&^^EXIT CALLED AT MAIN/  10+  6\&\\	J.  ^THE ^^STOP\\ STATEMENT HAS BEEN REACHED.
    		 ####^^MANTIS\\ INFORMS USER.
&*^^EXIT\\			K.  ^THE ^^EXIT\\ COMMAND RETURNS CONTROL TO THE
    		 ####MONITOR WHICH THEN OUTPUTS THE
   		 ####END-OF-EXECUTION MESSAGES.
.SKIP 2
^&^^EXECUTION TIME:##########0.42 SEC.\\\&
^&^^TOTAL ELAPSED TIME:######57.10 SEC.\\\&
^&^^NO EXECUTION ERRORS DETECTED\\\&
.SKIP 2
^&^^EXIT\\\&
.SKIP 2
&.
.FILL
.SKIP 3
^NOTE: ^UNDERLINED INFORMATION WAS TYPED EITHER BY ^^MANTIS\\ OR THE
MONITOR.
.PAPER SIZE 58 70
.SKIP 3
.LEFT MARGIN 5
1.2 ^FUNDAMENTAL ^CONCEPTS
.SKIP 2
^BEFORE A USER TACKLES INDIVIDUAL ^^MANTIS\\ COMMANDS, HE SHOULD BE
FAMILIAR WITH THE GENERAL COMMAND FORMATS, UNDERSTAND WHAT THE 'CURRENT'
PROGRAM IS, AND KNOW HOW TO REFERENCE STATEMENTS AND VARIABLES IN AN
EXECUTING PROGRAM.
.SKIP 2
.INDEX ^COMMAND ^SYNTAX
1.2.1  ^^MANTIS\\ ^COMMAND ^SYNTAX - ^^MANTIS \\PROMPTS FOR COMMANDS
WITH THE CHARACTER '*'. ^A ^^MANTIS\\ COMMAND IS ENTERED IMMEDIATELY
AFTER THE '*' AND IS TERMINATED BY A CARRIAGE
RETURN (DENOTED BY '@' IN EXAMPLES FOR THIS SECTION).
.SKIP 2
^BLANKS ARE SIGNIFICANT IN ^^MANTIS\\ COMMANDS.
^AT LEAST ONE BLANK MUST SEPARATE THE COMMAND KEYWORD(S)
FROM THE REST OF THE COMMAND.
.SKIP 2
.INDENT 5
^^AT 35\\#####^&NOT\&#####^A^T35
.SKIP 2
.INDEX ^SIMPLE ^COMMANDS
.INDEX ^COMMAND ^STRINGS
^^MANTIS\\ COMMANDS APPEAR IN ONE OF TWO FORMATS: AS SIMPLE COMMANDS
OR AS COMMAND STRINGS.
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
1.###^SIMPLE COMMANDS.  ^ANY ^^MANTIS\\ COMMAND MAY APPEAR AS
A SIMPLE COMMAND, PRECEDED BY THE ^^MANTIS\\ PROMPT '*' AND FOLLOWED BY A CARRIAGE RETURN '@'.(1)
.FOOTNOTE 4
.SKIP 1
.LEFT MARGIN 5
-------------------
.BREAK
(1) ^SEE ^CHAPTER 2 AND ^CHAPTER 4 FOR DESCRIPTIONS OF THESE COMMAND TYPES.
!

.SKIP 2
.LEFT MARGIN 15
&*^^STOP AT\\ 15  @########^THIS IS A ^BREAK COMMAND
.BLANK
&*^^KILL AT\\ 15  @########^THIS IS A ^KILL ^COMMAND
.BLANK
&*^^VAR\\ = 5.432  @#######^THIS IS AN ACTION COMMAND
.BLANK
&*^^SUBCHECK IARRAY\\  @###^THIS IS A ^MONITORING COMMAND
.BLANK
&*^^USE OUT\\  @#########^THIS IS AN ^INPUT/^OUTPUT ^DEVICE 
#####################^COMMAND
.SKIP 2
.INDENT -5
2.###^COMMAND ^STRINGS - ^A COMMAND STRING IS A SET OF
SIMPLE ^^MANTIS\\ COMMANDS WHICH HAVE BEEN GROUPED TOGETHER TO MAKE ONE
LARGE COMMAND.  ^A STRING CONTAINS TWO OR MORE SIMPLE COMMANDS, THE FIRST
OF WHICH ^&MUST\& BE ONE OF THE BREAK COMMANDS.
^A SEMICOLON (;) SEPARATES EACH SIMPLE COMMAND FROM THE
ONE PRECEDING IT IN A COMMAND STRING.
.INDEX ^BREAK ^COMMANDS
.SKIP 2
^A COMMAND STRING MAY BE CONTINUED TO THE NEXT LINE IF A SEMICOLON
PRECEDES THE CARRIAGE RETURN.  ^THE SEMI-COLON MAY APPEAR ONLY
^&BETWEEN\& SIMPLE COMMANDS, NEVER WITHIN THEM.
.SKIP 2
.INDENT 4
.INDEX ^ACTION ^COMMANDS
.INDEX ^^KILL\\
.INDENT 4
&*^BREAK ^COMMAND ; ^ACTION/^^KILL\\ COMMAND ; @ (2)
.FOOTNOTE 4
.SKIP 1
.LEFT MARGIN 5
-------------------
.BREAK
(2)  ^THE ONLY ACTION COMMANDS THAT MAY BE USED HERE ARE ^^OUTPUT\\, ^VALUE ^CHANGE, ^G^O, AND ^^STOP\\.
!
.SKIP 1
.INDENT 4
&*^ACTION/^^KILL\\ ^COMMAND ; ^ACTION/^^KILL\\ ^COMMAND ... @
.LEFT MARGIN 15
.INDEX ^COMMENTS
.SKIP 2
^USER-ORIENTED COMMENTS MAY BE INSERTED EITHER ON SEPARATE LINES OR ON
THE SAME LINE AS A ^^MANTIS\\ COMMAND.  ^IF ON A SEPARATE LINE, ONE
SEMICOLON PRECEDES THE COMMENT; IF ON THE SAME LINE, TWO SEMICOLONS
MUST PRECEDE THE COMMENT. ^A CARRIAGE RETURN ENDS THE COMMENT.
.SKIP 2
&* ; ^^THIS COMMENT IS ON A SEPARATE LINE\\##@
.BLANK
&* ^^OUTPUT XYZ ;; HERE'S A COMMENT ON THE SAME LINE\\##@
.BLANK
&* @
.LEFT MARGIN 5
.SKIP 2
.INDEX ^CURRENT ^PROGRAM
.INDEX ^ROUTINES
1.2.2  ^THE ^CURRENT ^PROGRAM - ^AS A PROGRAM EXECUTES, CONTROL
PASSES IN AND OUT OF THE VARIOUS ROUTINES (MAIN PROGRAM AND SUBPROGRAMS)
WHICH MAKE UP THAT PROGRAM.  ^THE CURRENT PROGRAM, AT ANY MOMENT DURING
EXECUTION, IS THE ^^MANTIS\\-CONTROLLED ROUTINE BEING EXECUTED.
 ^SINCE ^^MANTIS\\ IGNORES ROUTINES IN FILES COMPILED WITHOUT ^^MANTIS\\,
NO SUCH ROUTINE CAN BE A CURRENT PROGRAM.  ^WHILE A ROUTINE COMPILED WITHOUT
^^MANTIS\\ IS EXECUTED, THE LAST ^^MANTIS\\-CONTROLLED ROUTINE TO BE
ENTERED REMAINS THE CURRENT PROGRAM.

.SKIP 2
^WHEN A ROUTINE REFERENCE IS OMITTED, THE CURRENT PROGRAM IS ASSUMED.
^FOR EXAMPLE, IF THE CURRENT PROGRAM IS SUBROUTINE ^^SUBA\\,
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
^A^T 99####  REFERS TO THE STATEMENT LABELED 99 IN SUBROUTINE ^^SUBA\\, WHEREAS
.BLANK
.INDENT -5
^A^T ^^SUBB\\/33#####  REFERS TO THE STATEMENT LABELED 33 IN SUBROUTINE ^^SUBB\\.
.SKIP 2
.LEFT MARGIN 5
.INDEX ^REFERENCING A ^^FORTRAN\\ ^STATEMENT
1.2.3  ^REFERENCING A ^^FORTRAN\\ ^STATEMENT - ^A ^^FORTRAN\\ SOURCE STATEMENT
MAY BE REFERENCED IF
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
1.###^IT IS LOCATED IN A ROUTINE WHICH WAS COMPILED WITH ^^MANTIS\\ (^SEE
^CHAPTER 3); AND
.SKIP 2
.INDENT -5
.INDEX ^EXECUTABLE ^STATEMENT
2.###^IT IS AN ^&EXECUTABLE\& STATEMENT.
.BLANK
^^GO TO, IF, DO\\, ASSIGNMENT, ^^CALL, TYPE\\ AND ^^ACCEPT\\ ARE
SOME EXECUTABLE ^^FORTRAN\\ STATEMENTS.  ^STATEMENTS LIKE ^^FORMAT, SUBROUTINE,
DIMENSION,\\  ^^DATA\\ AND ^TYPE ^DECLARATIONS ARE ^&NOT\& EXECUTABLE AND CANNOT BE REFERENCED.
.LEFT MARGIN 5
.SKIP 2
^^A CONTINUE\\ STMT IS EXECUTABLE IF AND ONLY IF IT IS THE LAST STATEMENT
IN THE RANGE OF A ^D^O STATEMENT.  ^^A CONTINUE\\ STMT IS NOT EXECUTABLE IF
IT IS USED ONLY AS A TARGET FOR TRANSFERS (^^GOTO)\\.
.SKIP 2
.INDEX ^FORMAT FOR A ^STATEMENT ^REFERENCE
.INDEX ^STATEMENT-^REFERENCE
^THE GENERAL FORMAT FOR A STATEMENT REFERENCE IS
.INDENT 5
.SKIP 2
.INDEX ^STATEMENT LABEL
ROUTINE-NAME/STATEMENT LABEL  &+N
.SKIP 2
^THE ROUTINE-NAME INDICATES WHICH ROUTINE IS TO BE REFERENCED.  ^IF
OMITTED, THE CURRENT PROGRAM IS ASSUMED.  ^TO REFERENCE THE MAIN
PROGRAM (WHEN NOT THE CURRENT PROGRAM), USE THE ROUTINE-NAME ^^MAIN\\.
.INDEX ^MAIN ^PROGRAM
.SKIP 2
^THE STATEMENT LABEL MUST BE THE NUMERIC LABEL ^&FROM AN EXECUTABLE STATEMENT.\&
^THE LABEL MAY BE OMITTED IF BOTH A ROUTINE-NAME AND &+N ARE GIVEN.
.SKIP 2
'&+N' IS AN INTEGER CONSTANT WHICH PROVIDES A WAY TO REFERENCE STATEMENTS
WITHOUT LABEL NUMBERS BY COUNTING FROM A NUMBERED STATEMENT.
^IF NO STATEMENT LABEL IS GIVEN, +N COUNTS
EXECUTABLE STATEMENTS FROM THE BEGINNING OF THE INDICATED
ROUTINE DOWN TO THE REFERENCED STATEMENT.  ^IF THE STATEMENT TO
BE REFERENCED HAS A LABEL, &+N IS UNNECESSARY.
.SKIP 2
^EXAMPLES:
.SKIP 2
.LEFT MARGIN 20
.INDENT -10
^A/240-1###REFERS TO THE FIRST EXECUTABLE STATEMENT PRIOR TO LABEL
240 IN SUBROUTINE ^A.
.INDENT -10
55+2######REFERS TO THE SECOND EXECUTABLE STATEMENT PAST LABEL 55 
IN THE CURRENT PROGRAM.
.INDENT -10
^^MAIN\\/+3###REFERS TO THE THIRD EXECUTABLE STATEMENT IN THE MAIN
PROGRAM.
.INDENT -10
^B/180#####REFERS TO THE STATEMENT LABELED 180 IN SUBROUTINE ^B.
.LEFT MARGIN 5
.SKIP 2
^WHEN EXECUTION REACHES  A STATEMENT WHICH HAS BEEN REFERENCED, ITS LOCATION AS
DISPLAYED BY ^^MANTIS\\ IS
.LEFT MARGIN 10
.SKIP 2
STATEMENT LABEL &+N
.LEFT MARGIN 5
.SKIP 2
^NOTE: ^^MANTIS\\ PICKS THE CLOSEST STATEMENT LABEL WITH WHICH TO
SPECIFY A STATEMENT LOCATION, E.G., IF THE USER MADE REFERENCE
TO THE STATEMENT AT
.SKIP 2
.INDENT 5
^^MAIN\\/20 + 5
.SKIP 2
^^MANTIS \\WOULD DISPLAY
.SKIP 2
.INDENT 5
^^MAIN\\/30 - 3
.SKIP 2
WHEN EXECUTION REACHED THE STATEMENT BECAUSE LABEL 30 WAS CLOSER.
.SKIP 2
.INDEX ^REFERENCING A ^VARIABLE
.INDEX ^VARIABLES, REFERENCING OF
1.2.4  ^REFERENCING A ^VARIABLE - ^A VARIABLE MAY BE A SCALAR, AN ARRAY
ELEMENT, OR AN ENTIRE ARRAY.  ^A VARIABLE MAY BE REFERENCED ONLY IN ROUTINES
(MAIN PROGRAM OR SUBROUTINES) WHICH HAVE BEEN COMPILED WITH ^^MANTIS\\ 
^&AND\& IN WHICH THE VARIABLE APPEARS ^&IN AN EXECUTABLE STATEMENT\&.
.SKIP 2
.INDEX ^ARRAY ^REFERENCES
.SKIP 2
^THE GENERAL FORMAT FOR A VARIABLE REFERENCE IS
.SKIP 2
.INDENT 5
ROUTINE-NAME/VARIABLE
.SKIP 2
^JUST AS IN A STATEMENT REFERENCE, THE ROUTINE-NAME INDICATES WHICH ROUTINE
IS TO BE REFERENCED.
.SKIP 2
^EXAMPLES:
.SKIP 2
.LEFT MARGIN 25
.INDENT -15
^^SUBA/IVAR\\######REFERS TO THE SCALAR VARIABLE ^^IVAR\\ IN 
SUBROUTINE ^^SUBA\\.
.SKIP 1
.INDENT -15
^^MAIN/SAMPLE\\(3)#REFERS TO THE THIRD ELEMENT OF THE ARRAY
^^SAMPLE\\ IN THE MAIN PROGRAM.
.SKIP 1
.INDENT -15
^^TEST\\ (1, 1, 1)#REFERS TO THE FIRST ELEMENT IN THE ARRAY
^^TEST\\ IN THE CURRENT PROGRAM.
.SKIP 2
.LEFT MARGIN 5
^ARRAY REFERENCES REQUIRE SUBSCRIPTS.  ^TO REFERENCE SINGLE ARRAY ELEMENTS,
USE CONSTANT SUBSCRIPTS (FOR EXAMPLE: ^Y(4), ^^TEST\\(1,5)).  ^TO 
REFERENCE MORE THAN ONE ELEMENT, USE THE '*' NOTATION.(3)
.FOOTNOTE 3
.LEFT MARGIN 5
.SKIP 1
-------------------
.BREAK
(3) '*' NOTATION CANNOT BE USED IN ^BREAK COMMANDS OR COMMAND STRINGS.
!

.SKIP 2
.LEFT MARGIN 10
^Y(*)############REFERS TO THE WHOLE ARRAY ^Y
.BREAK
################IN THE CURRENT PROGRAM.

.BLANK
^^TEST\\(1,*)#######REFERS TO THE FIRST ROW OF ARRAY ^^TEST\\
.BREAK
################IN THE CURRENT PROGRAM.
.BLANK
^^MAIN/TEST\\(*,2)##REFERS TO THE SECOND COLUMN OF ARRAY ^^TEST\\
.BREAK
################IN THE MAIN PROGRAM.
.SKIP 2
.LEFT MARGIN 5
.INDEX ^EXECUTABLE ^STATEMENT
.INDEX ^EXECUTION ^BREAK, DEPENDING ON A ^VARIABLE
^USERS CAN INSTRUCT ^^MANTIS\\ TO CHANGE THE VALUE OF ANY VARIABLE USED IN
AN EXECUTABLE STATEMENT.  ^^MANTIS\\ CAN ALSO BE USED TO  SET AN EXECUTION
BREAK DEPENDING ON A VARIABLE'S VALUE(S).  (^SEE ^SECTION 2.1.4, '^THE ^O^N ^COMMAND')
.SKIP 2
^NOTE:  ^EXECUTION BREAKS CAN ONLY BE SET ON VARIABLES WHICH APPEAR IN 
INPUT LISTS OR TO THE LEFT OF AN EQUAL (=) SIGN.
.TITLE ^^MANTIS\\ ^CHAPTER 2
.PAGE
.SKIP 3
2.0  ^^MANTIS COMMANDS\\
.SKIP 2
.INDEX ^^MANTIS\\ ^COMMANDS
^THERE ARE FIVE TYPES OF ^^MANTIS\\ COMMANDS.  ^THESE ARE:
.LEFT MARGIN 15
.INDEX ^BREAK ^COMMANDS
.SKIP 2
.INDENT -5
1.###^BREAK ^COMMANDS
.BLANK
^BREAK COMMANDS SET BREAKPOINTS IN A PROGRAM TO BE DEBUGGED.  ^WHEN
ONE OF THESE BREAKPOINTS IS REACHED DURING PROGRAM EXECUTION, ^^MANTIS\\
REGAINS CONTROL AND DISPLAYS A MESSAGE.  ^IF THE COMMAND INCLUDES
  '^^STOP\\', ^^MANTIS\\ ALSO SUSPENDS PROGRAM EXECUTION SO THE USER MAY ENTER MORE
^^MANTIS\\ COMMANDS BEFORE PROGRAM EXECUTION CONTINUES.  ^^MANTIS\\ COMMANDS
MAY BE ENTERED WHEN ^^MANTIS \\ TAKES CONTROL AT THE
BEGINNING OF EXECUTION  AND AT BREAKPOINTS
SET BY BREAK COMMANDS.
.SKIP 2
^THE FOUR BREAK COMMANDS ARE:
.SKIP 2
.INDEX ^^AT\\
.INDEX ^^ON CALL\\ ^COMMAND
.INDEX ^^BEFORE RETURN FROM\\ ^COMMAND
.INDEX ^^ON\\ ^COMMAND
.LEFT MARGIN 20
^^AT\\
.BLANK
^^ON CALL\\
.BLANK
^^BEFORE RETURN\\
.BLANK
^^ON\\
.SKIP 2
.LEFT MARGIN 15
^IN THE ^SECTION 1.1 EXAMPLE, (B) IS A BREAK COMMAND AND (F) IS THE MESSAGE 
^^MANTIS\\ OUTPUTS WHEN IT REACHES THE BREAKPOINT.
.LEFT MARGIN 15
.SKIP 2
.INDENT -5
.INDEX ^^KILL\\
2.###^^KILL\\ COMMAND.
.SKIP 2
^BREAK COMMANDS REMAIN IN EFFECT DURING PROGRAM EXECUTION UNTIL THEY ARE
EXPLICITLY DELETED.  ^THE ^^KILL\\ COMMAND IS USED TO DELETE UNWANTED
BREAK COMMANDS.
.INDEX ^DELETE ^UNWANTED ^BREAK ^COMMANDS
.SKIP 2
.INDENT -5
.INDEX ^ACTION ^COMMANDS
3.###^ACTION COMMANDS.
.SKIP 2
^ACTION COMMANDS START OR STOP PROGRAM EXECUTION AND CHANGE OR OUTPUT
VARIABLE VALUES.  ^AFTER THE USER HAS ENTERED ONE OR MORE
BREAK COMMANDS, HE BEGINS PROGRAM EXECUTION WITH THE ^^MANTIS\\ ACTION
COMMAND, ^G^O.  (^SEE THE ^SECTION 1.1 EXAMPLE, ITEM (D))
.SKIP 2
^THE FOLLOWING ARE ACTION COMMANDS:
.SKIP 2
.TAB STOPS 40
.TEST PAGE 5
.LEFT MARGIN 20
.NOFILL
^^GO	TYPE
STOP	RESTART
OUTPUT	RETRY\\
^VALUE ^CHANGE	
^^EXIT\\
.FILL
.LEFT MARGIN 15
.SKIP 2
^COMMANDS IN THE LEFT COLUMN ARE EXPLAINED IN ^CHAPTER 2.
.BLANK
^COMMANDS IN THE RIGHT COLUMN ARE EXPLAINED IN ^CHAPTER 4.
.SKIP 2
.INDENT -5
4.###^MONITORING COMMANDS.
.SKIP 2
.INDEX ^MONITORING ^COMMANDS
^MONITORING COMMANDS PROVIDE A RECORD OF THE EXECUTION FLOW OF A PROGRAM AND
CHECK ARRAY SUBSCRIPTS TO INSURE THAT THEY STAY IN BOUNDS.
.SKIP 2
^THERE ARE FOUR MONITORING COMMANDS:
.SKIP 2
.LEFT MARGIN 20
.INDEX ^^HISTORY\\ ^COMMAND
.INDEX ^^TRACE\\ ^COMMAND
.INDEX ^^SUBCHECK\\ ^COMMAND
.INDEX ^STATEMENT ^LOCATION ^QUERY
^^HISTORY
.BLANK
TRACE
.BLANK
SUBCHECK\\
.BLANK
^STATEMENT ^LOCATION ^QUERY
.SKIP 2
.LEFT MARGIN 15
^THESE COMMANDS ARE DISCUSSED IN ^SECTION 4.1.
.SKIP 2
.INDEX ^INPUT/^OUTPUT ^DEVICE ^CONTROL ^COMMANDS
.INDENT -5
5.###^INPUT/^OUTPUT DEVICE ^CONTROL COMMANDS.
.INDEX ^DEVICE ^CONTROL ^COMMAND
.SKIP 2
^ONE OF THESE COMMANDS (^^USE\\) DETERMINES WHETHER ^^MANTIS\\ OUTPUT
GOES TO DISK OR THE USER TELETYPE.  ^THE OTHERS POSITION MAGNETIC TAPES
OR DISK FILES USED FOR ^I/^O IN THE ^^FORTRAN \\PROGRAM BEING DEBUGGED.
.SKIP 2
^THE FOLLOWING ARE ^I/^O COMMANDS:
.SKIP 2
.LEFT MARGIN 20
.TEST PAGE 14
.INDEX ^^USE\\ ^COMMAND
^^USE\\
.BLANK
.INDEX ^^BACKSPACE\\
.INDEX ^^ENDFILE\\
.INDEX ^^REWIND\\
.INDEX ^^SKIPRECORD\\
.INDEX ^^UNLOAD\\
.INDEX ^^RELEASE\\
^^BACKSPACE\\
.BLANK
^^ENDFILE\\
.BLANK
^^REWIND\\
.BLANK
^^SKIPRECORD\\
.BLANK
^^UNLOAD\\
.BLANK
^^RELEASE\\
.SKIP 2
.LEFT MARGIN 15
^I/^O COMMANDS ARE COVERED IN ^SECTION 4.2.
.SKIP 3
.LEFT MARGIN 5
2.1 ^BREAK ^COMMANDS
.INDEX ^BREAK ^COMMANDS
.INDEX ^BREAKPOINT ON ^EXECUTABLE ^STATEMENT
.SKIP 2
^BREAK COMMANDS SET  BREAKPOINTS AT EXECUTABLE STATEMENTS.  ^DURING
PROGRAM EXECUTION, ^^MANTIS\\ REGAINS CONTROL AT EACH BREAKPOINT.
^^MANTIS\\ COMMANDS MAY BE ENTERED ONLY AT THE BEGINNING OF
EXECUTION OR AT A BREAKPOINT.  ^DESCRIPTIONS OF THE FOUR BREAK COMMANDS
FOLLOW.
.SKIP 2
^NOTE: ^OPTIONAL INFORMATION APPEARS WITHIN BRACKETS.
.SKIP 2
2.1.1  ^^AT\\ ^COMMAND - ^THE ^A^T COMMAND SETS A BREAKPOINT ON ANY
.INDEX ^^AT\\
^&EXECUTABLE\& ^^FORTRAN\\ STATEMENT WHICH APPEAR IN A ROUTINE
(MAIN PROGRAM OR SUBPROGRAM) COMPILED WITH ^^MANTIS\\.  ^WHEN
EXECUTION REACHES A BREAKPOINT AT AN EXECUTABLE ^^FORTRAN\\ STATEMENT, THE
LOCATION OF THAT STATEMENT IS DISPLAYED WITH REFERENCES TO THE CLOSEST
NUMBERED EXECUTABLE STATEMENT.
.SKIP 2
^FOR INSTANCE, IF IN THE FOLLOWING PROGRAM
.SKIP 2
.LEFT MARGIN 10
.TAB STOPS 15
.NOFILL
	^^DIMENSION VAR(5)\\
5	^^ACCEPT 10, VAR\\
10	^^FORMAT(5F)\\
	^^DO 15 I = 1,5\\
15	^^SUM = SUM + VAR(I)\\
	^^TYPE 20, SUM\\
20	^^FORMAT\\('# ^^SUM = ', F)\\
	^^STOP\\
	^^END\\
.LEFT MARGIN 5
.SKIP 2
.FILL
^WE WISH TO SET A BREAKPOINT AT
.INDENT 5
.SKIP 2
^^TYPE\\ 20, ^^SUM\\
.LEFT MARGIN 5
.SKIP 2
^WE USE EITHER OF THE FOLLOWING COMMANDS
.NOFILL
.SKIP 2
.LEFT MARGIN 10
.TAB STOPS 20 30
&*^A^T 5+3	(STATEMENT LABELED 5 PLUS THREE EXECUTABLE
	 STATEMENTS)
.BLANK
&*^A^T 15+1	(STATEMENT LABELED 15 PLUS ONE EXECUTABLE
	 STATEMENT)
.SKIP 2
.FILL
.LEFT MARGIN 5
^WHEN THE BREAKPOINT IS REACHED, ^^MANTIS \\DISPLAYS
.SKIP 2
.LEFT MARGIN 10
^&<15>+1\&
.SKIP 2
.LEFT MARGIN 5
BECAUSE THE ^^TYPE\\ STATEMENT IS CLOSEST TO THE STATEMENT LABELED 15.
.SKIP 2
^THE STATEMENT 10 ^^FORMAT\\ (5^F) IS IGNORED WHEN COUNTING
EXECUTABLE STATEMENTS BECAUSE IT IS NOT EXECUTABLE.
.SKIP 2
.INDENT 5
&*^A^T 5+4
.SKIP 2
WOULD REFERENCE THE ^^STOP\\ STATEMENT IN THE SAMPLE PROGRAM.
.SKIP 2
.INDENT 5
&*^A^T 20 - 1
.SKIP 2
IS ^&INVALID\& BECAUSE THE LABEL 20 IS ON A NON-EXECUTABLE STATEMENT.
.SKIP 2
^THE COMMAND FORMS ARE:
.LEFT MARGIN 15
.SKIP 2
.INDENT -5
.INDEX ^STATEMENT-^REFERENCE
1.###^A^T STATEMENT-REFERENCE , N(1)
.FOOTNOTE 2
.LEFT MARGIN 5
.SKIP 1
-------------------
.BREAK
(1) ^SEE ^SECTION 1.2.3 ON HOW TO REFERENCE A PROGRAM STATEMENT.
!
.SKIP 2
^THIS FORM DISPLAYS THE LOCATION OF THE ^^FORTRAN\\ STATEMENT REFERENCED IN THE
COMMAND EVERY NTH TIME IT IS EXECUTED BEGINNING WITH THE NTH TIME. 
^IF OMITTED, N IS ASSUMED TO HAVE A VALUE OF 1.
.SKIP 2
.INDENT -5
2.###^^STOP AT\\ STATEMENT-REFERENCE , N(1)
.SKIP 2
^FORM 2 DISPLAYS THE LOCATION OF THE ^^FORTRAN \\
STATEMENT REFERENCED ^&AND\& HALTS EXECUTION JUST PRIOR TO THAT 
STATEMENT EVERY NTH TIME IT IS TO BE EXECUTED.
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
^A^T 66
.SKIP 2
.TEST PAGE 4
^DISPLAYS ^&<66>\& ON THE USER'S TELETYPE 
(OR  A DISK FILE SPECIFIED IN A ^^USE\\ COMMAND
(^SECTION 4.2.1)) EACH TIME THE EXECUTABLE STATEMENT LABELED 66
IS ENCOUNTERED IN THE CURRENT PROGRAM.(2)
.FOOTNOTE 3
.LEFT MARGIN 5
.SKIP 1
-------------------
.BREAK
(2) ^SEE ^SECTION 1.2.2 FOR DEFINITION OF THE CURRENT PROGRAM.
!
.SKIP 2
.INDENT 5
^^STOP AT MAIN\\/160+1
.SKIP 2
DISPLAYS ^&<160>+1\& AND STOPS EXECUTION EACH TIME THE EXECUTABLE STATEMENT
FOLLOWING THE STATEMENT LABELED 160 IN THE MAIN PROGRAM IS REACHED.
.SKIP 2
.INDENT 5
^^STOP AT SUBR\\/54,3
.SKIP 2
DISPLAYS ^&<54>\& AND STOPS EXECUTION EVERY THIRD TIME (3RD, 6TH, 9TH,...)
THE STATEMENT LABELED 54 IN SUBROUTINE ^^SUBR\\ IS ENCOUNTERED.
.LEFT MARGIN 5
.SKIP 2
.INDEX ^^ON CALL\\ ^COMMAND
.INDEX ^BREAKPOINT ON ^SUBPROGRAM ^CALL
.INDEX ^FUNCTION ^CALL
2.1.2  ^^ON CALL\\ ^COMMAND - ^THE ^^ON CALL\\ COMMAND SETS AN EXECUTION
BREAK WHEN A SPECIFIED SUBPROGRAM IS CALLED (AT THE SUBROUTINE OR  
FUNCTION STATEMENT FOR THE SUBPROGRAM).  ^THE CALLED SUBPROGRAM
MUST HAVE BEEN COMPILED WITH ^^MANTIS\\.    ^WHEN EXECUTION REACHES AN
^^ON CALL\\ BREAKPOINT, THE PROGRAMMER MAY HALT EXECUTION, DISPLAY 
VARIABLES, AND CHANGE THE VALUES OF VARIABLES.  ^A VARIABLE MAY BE 
REFERENCED BY NAME OR BY ITS ARGUMENT NUMBER IN THE ^^SUBROUTINE\\ OR
^^FUNCTION\\ STATEMENT.  ^IF A VARIABLE IS  REFERENCED BY NAME, IT
MUST APPEAR IN AN ^&EXECUTABLE\& STATEMENT IN THE CALLED SUBPROGRAM (THE
CURRENT PROGRAM) OR IN SOME OTHER SPECIFIED ROUTINE.
.INDEX ^CURRENT ^PROGRAM
.INDEX ^SUBROUTINE ^CALL
(^SEE ^SECTION 1.2.4 FOR SPECIFYING A ROUTINE-NAME QUALIFIER FOR A VARIABLE.)
.SKIP 2
^IF A VARIABLE IS REFERENCED AS A SUBPROGRAM ARGUMENT, IT MAY
NOT BE AN ARRAY.  ^SEE ^SECTIONS 2.3.3, 2.3.4, AND 4.3.1 FOR INFORMATION
ON DISPLAYING AND CHANGING VALUES OF VARIABLES.
.SKIP 2
^TWO FORMS OF THE ^^ON CALL\\ COMMAND ARE ACCEPTED BY ^^MANTIS\\.
.LEFT MARGIN 15
.SKIP 2
.INDENT -5
1.###^^ON CALL\\ SUBPROGRAM-NAME
.SKIP 2
^DISPLAYS THE SUBPROGRAM-NAME AND THE POINT FROM WHICH IT WAS CALLED WHEN A ^^CALL\\ TO THAT SUBPROGRAM IS
REACHED, AND THEN CONTINUES EXECUTION.
.SKIP 2
.INDENT -5
2.###^^STOP ON CALL\\ SUBROUTINE-NAME
.SKIP 2
^DISPLAYS THE SUBROUTINE-NAME AND CALLING LOCATION ^&AND\& HALTS EXECUTION SO THAT THE
ARGUMENTS MAY BE EXAMINED.(3)
.FOOTNOTE 4
.SKIP 1
.LEFT MARGIN 5
-------------------
.BREAK
3) ^SEE  THE ACTION COMMANDS ^^OUTPUT\\ (^SECTION 2.3.3) AND ^VALUE
^CHANGE (^SECTION 2.3.4 AND ^SECTION 4.3.1) FOR VARIABLE DISPLAY
 AND CHANGE.
!
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
^^ON CALL SUBR\\
.SKIP 2
^DISPLAYS ^&^^SUBR CALLED FROM\\ STATEMENT-REFERENCE\& EACH TIME SUBROUTINE ^^SUBR\\ IS CALLED (ASSUMING ^^SUBR\\ WAS  COMPILED WITH ^^MANTIS\\).
.SKIP 2
.INDENT 5
^^STOP ON CALL FUNC\\
.SKIP 2
^DISPLAYS ^&^^FUNC CALLED FROM\\ STATEMENT-REFERENCE\& EACH TIME THE FUNCTION ^^FUNC\\ IS CALLED AND THEN
STOPS EXECUTION SO THE PROGRAMMER MAY ISSUE NEW ^^MANTIS \\COMMANDS.
.SKIP 2
.TEST PAGE 14
.INDEX ^^BEFORE RETURN FROM\\ ^COMMAND
.INDEX ^BREAKPOINT ON SUBPROGRAM ^^RETURN\\ OR ^^END\\
.INDEX ^^RETURN\\ ^STATEMENT ^BREAK
.INDEX ^^END\\ ^STATEMENT ^BREAK
.LEFT MARGIN 5
2.1.3  ^^BEFORE RETURN FROM\\ ^COMMAND - ^THE ^^BEFORE RETURN FROM\\
COMMAND SETS AN EXECUTION BREAKPOINT AT A ^^RETURN\\ (OR ^^END\\)
STATEMENT IN A SUBPROGRAM (^^SUBROUTINE\\
OR ^^FUNCTION\\).  ^THE SUBPROGRAM MUST HAVE BEEN COMPILED WITH ^^MANTIS\\.
^WHEN EXECUTION REACHES THE BREAKPOINT, THE MESSAGE ^&^^BEFORE RETURN\\\&
IS DISPLAYED.  ^THE COMMAND FORM IS:
.SKIP 2
.INDENT 5
[^^STOP\\] ^^BEFORE [RETURN FROM\\]  ###SUBROUTINE-NAME [,N]
.SKIP 2
^THE POSITIVE INTEGER 'N' SPECIFIES THAT ^^MANTIS \\WILL DISPLAY AND OPTIONALLY
STOP ONLY EVERY 'NTH' TIME A RETURN FROM THE
SPECIFIED SUBROUTINE IS ENCOUNTERED.  ^BOTH 'N' AND '^^STOP\\' ARE
OPTIONAL.
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
^^STOP\\ ^^BEFORE RETURN FROM SUBR\\
.SKIP 2
^DISPLAYS ^&^^BEFORE RETURN\\\& AND HALTS EXECUTION EACH TIME EXECUTION REACHES A
^^RETURN\\ (OR ^^END\\) STATEMENT IN SUBROUTINE ^^SUBR.\\
.SKIP 2
.INDENT 5
^^BEFORE RETURN FROM SUBR\\,2
.SKIP 2
^DISPLAYS ^&^^BEFORE RETURN\\\& EVERY SECOND TIME EXECUTION REACHES A ^^RETURN\\
STATEMENT IN SUBROUTINE ^^SUBR\\.
.SKIP 2
.INDEX ^^ON\\ ^COMMAND
.INDEX ^BREAK ON ^VARIABLE ^VALUE
.INDEX ^BREAK ON ^VARIABLE ^CHANGE OF ^VALUE
.INDEX ^VARIABLE
.INDEX ^EQUIVALENCED ^VARIABLES
.LEFT MARGIN 5
2.1.4  ^O^N ^COMMAND - ^THE ^O^N COMMAND SETS AN EXECUTION BREAK DEPENDING
ON THE VALUE, OR CHANGE OF VALUE, OF A VARIABLE.  ^THE VARIABLE MAY 
BE A SCALAR, ARRAY ELEMENT, OR AN ENTIRE ARRAY, AND IT MAY BE
^^EQUIVALENCED\\.   ^THE ^O^N COMMAND CAN BE USED ONLY TO CHECK 
VARIABLES WHICH APPEAR IN INPUT STATEMENTS (^^READ, ACCEPT, ENCODE, DECODE\\)
OR TO THE ^&LEFT\& OF THE '=' SIGN IN AN ASSIGNMENT STATEMENT.  ^THE
^O^N COMMAND DOES ^&NOT\& SET EXECUTION BREAKS ON THE CHANGING
OF SUBROUTINE ACTUAL ARGUMENTS.
.SKIP 2
^EACH ^O^N COMMAND TESTS VARIABLES IN ONLY ONE ROUTINE; HENCE, IN ORDER
TO MONITOR A VARIABLE WHICH APPEARS IN THREE SUBROUTINES, THREE ^O^N
COMMANDS WOULD BE NEEDED.  ^IF THE KEYWORD ^^STOP\\ IS PRESENT, AS PART
OF THE ^O^N COMMAND, EXECUTION HALTS AT THE BREAKPOINT SO NEW ^^MANTIS\\
COMMANDS MAY BE ENTERED.
.SKIP 2
^WHEN AN ^O^N BREAK CONDITION IS MET, ^^MANTIS\\ DISPLAYS THE VARIABLE
WHICH CAUSED THE BREAK AND THE LOCATION, WITH RESPECT TO THE CLOSEST
NUMBERED ^&EXECUTABLE\& STATEMENT, OF THE ^^FORTRAN \\STATEMENT IN WHICH THE
BREAK OCCURRED.
.INDENT 5
.SKIP 2
^&^A^T STATEMENT-REFERENCE\& ##########(4)
.FOOTNOTE 3
.LEFT MARGIN 5
.SKIP 1
-------------------
.BREAK
(4) ^SEE ^SECTION 1.2.3 FOR THE MEANING OF A STATEMENT REFERENCE.
!
.BLANK
.INDENT 5
^&^VARIABLE = CONSTANT\&
.SKIP 2
^IF AN ^O^N COMMAND CAUSES A BREAK ON AN INPUT STATEMENT (^^READ, ACCEPT,
ENCODE, DECODE\\), ^^MANTIS\\ WAITS UNTIL THE ENTIRE VARIABLE LIST IS INPUT
BEFORE DISPLAYING ITS MESSAGE AND HALTING EXECUTION.
.SKIP 2
^THE COMMAND HAS TWO FORMS:
.SKIP 1
.INDEX ^BREAK AT AN ^INPUT ^STATEMENT
.INDEX ^INPUT ^STATEMENT, BREAK AT
.INDEX ^BREAK ^COMMANDS, REVOKING
(^INFORMATION ENCLOSED IN BRACKETS IS OPTIONAL.)
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
1.###[^^STOP\\] ^O^N [ROUTINE-NAME/] VARIABLE [POSITION]
.BLANK
^AN EXECUTION BREAK OCCURS WHENEVER THE SPECIFIED VARIABLE HAS ITS VALUE
CHANGED AT THE INDICATED POSITION.
.SKIP 2
^IF '^^STOP\\' IS PRESENT, EXECUTION STOPS AT THE BREAKPOINT AFTER
^^MANTIS\\ DISPLAYS THE MESSAGE.
.SKIP 2
.INDENT 5
^&^A^T STATEMENT-REFERENCE\&
.BLANK
.INDENT 5
^&VARIABLE = CONSTANT\&
.SKIP 2
.INDEX ^CURRENT ^PROGRAM
^IF '^^ROUTINE-NAME/\\' IS OMITTED, BREAKPOINTS ARE SET ON THE VARIABLE IN
THE CURRENT PROGRAM.
.INDEX ^POSITION ^REFERENCE
.INDEX ^STATEMENT-^REFERENCE
.INDEX ^DELETE ^UNWANTED ^BREAK ^COMMANDS
.INDEX ^REVOKE ^BREAK ^COMMANDS
.SKIP 2
^THE POSITION MAY REFERENCE ONE EXECUTABLE STATEMENT BY
.SKIP 2
.INDENT 5
^A^T STATEMENT-REFERENCE
.SKIP 2
OR A RANGE OF STATEMENTS BY
.SKIP 2
^^BETWEEN\\ STATEMENT-REFERENCE ^^AND\\ STATEMENT-REFERENCE
.INDEX ^^BETWEEN...AND\\
.SKIP 2
^IF 'POSITION' IS OMITTED, THE VARIABLE IS CHECKED THROUGHOUT THE
SPECIFIED ROUTINE (DEFAULT IS THE CURRENT PROGRAM).  ^IF A 'POSITION'
IS IDENTIFIED, IT MUST AGREE IN ROUTINE-NAME WITH THE VARIABLE.  ^IT IS
SUFFICIENT TO INDICATE THE ROUTINE-NAME WITH THE VARIABLE. E.G.,
.SKIP 2
.INDENT 5
^^ON Y AT\\ 60
.SKIP 2
ASSUMES THAT BOTH THE VARIABLE ^Y AND THE LABEL 60 ARE IN THE CURRENT
PROGRAM.
.SKIP 2
.INDENT 5
^^ON MAIN/Y AT\\ 60
.SKIP 2
ASSUMES THAT LABEL 60 IS IN THE MAIN PROGRAM
.SKIP 2
.INDENT 5
^^ON Y AT SUBR\\/75
.SKIP 2
IS INVALID UNLESS THE CURRENT PROGRAM IS ^^SUBR\\ BECAUSE ^Y IS 
ASSUMED TO BE IN THE CURRENT PROGRAM.
.SKIP 2
.INDENT 5
^^ON MAIN/Y AT SUBR/\\75
.SKIP 2
IS ALWAYS INVALID.
.SKIP 2
^A VARIABLE IN AN ^O^N COMMAND ^&MUST\& APPEAR IN AN EXECUTABLE
STATEMENT.
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
^^STOP ON ARR\\
.SKIP 2
SETS A BREAK CONDITION AND HALTS EXECUTION WHEN ^&ANY\& ELEMENT OF
ARRAY ^^ARR\\ CHANGES VALUE IN THE CURRENT PROGRAM.  ^^MANTIS\\ DISPLAYS
.SKIP 2
.INDENT 5
^&^A^T STATEMENT-REFERENCE\&
.BLANK
.INDENT 5
^&^^ARR\\(2) = 34.4\&  (FOR EXAMPLE)
.SKIP 2
^IF SOME ELEMENTS OF ^^ARR\\ WERE CHANGED THROUGH INPUT,
THE SECOND MESSAGE LINE WOULD BE CHANGED TO
.SKIP 2
.INDENT 5
^&^^ARR\\##=#############\&
.SKIP 1
.CENTER
------------------------------------------------------
.SKIP 1
.INDENT 5
^^STOP ON Y AT\\ 60
.SKIP 2
DISPLAYS ^Y AND STOPS EXECUTION IF THE SCALAR ^Y CHANGES VALUE AT THE 
^&EXECUTABLE\& STATEMENT LABELED 60 IN THE CURRENT PROGRAM. (E.G., 60 ^Y=^X1+^Z).  ^IF ^Y DOES NOT CHANGE VALUE AT THE LABEL 60, NO MESSAGE IS OUTPUT
AND EXECUTION CONTINUES.  ^VALUE CHANGES FOR ^Y AT OTHER
STATEMENTS ARE NOT DISPLAYED.
.SKIP 2
.INDENT 5
^^ON SUBR/I(3) BETWEEN SUBR/+1 AND 25\\
.SKIP 2
DISPLAYS ARRAY ELEMENT ^I(3) WHEN ^I(3) CHANGES VALUE IN THE RANGE FROM THE FIRST EXECUTABLE
STATEMENT UP TO THE STATEMENT LABELED 25 IN SUBROUTINE ^^SUBR\\.
.SKIP 2
^SUCH A RANGE MIGHT BE,
.SKIP 2
.NOFILL
.TAB STOPS 25 30 35
		^^SUBROUTINE  SUBR (ITEST)\\
(+1)		^^TYPE .5
	5	^^FORMAT (' THIS IS SUBROUTINE SUBR.')\\
		^^I(3)=ITEST\\
(25)	25	^^J=I(3) *N\\
.FILL
.SKIP 1
.CENTER
------------------------------------------------------
.SKIP 1
^^STOP ON MAIN/ARR AT 77-2\\
.SKIP 2
DISPLAYS THE CHANGED ELEMENT OF ARRAY ^^ARR\\ WHENEVER ANY ELEMENT OF
^^ARR\\ CHANGES VALUE AT THE STATEMENT TWO BEFORE THE LABEL 77 IN THE
MAIN PROGRAM.
.TAB STOPS 20 30
.NOFILL
.SKIP 2
(^^MAIN/77-2\\)	^^ARR(I) = X*3
		I=I+1
	77	TYPE 10, ARR\\
.FILL
.SKIP 2
.INDENT -5
2.###[^^STOP] ON\\ [ROUTINE-NAME] VARIABLE [RELATION CONSTANT] [POSITION]
.INDEX ^POSITION ^REFERENCE
.SKIP 2
^AN EXECUTION BREAK OCCURS AT THE POSITION INDICATED WHEN THE CONDITION
'VARIABLE RELATION CONSTANT' IS TRUE.  ^THE RELATION IS ONE OF THE 
^^FORTRAN\\ OPERATORS (^^.EQ., .NE., .LT., .LE., .GT., .GE.).\\
^THE CONSTANT MAY BE A DECIMAL NUMBER WHICH AGREES IN TYPE WITH THE
VARIABLE, AN OCTAL NUMBER OR AN ^^ASCII\\ CHARACTER STRING (LITERAL).
.SKIP 2
^THE ROUTINE-NAME AND POSITION SPECIFICATIONS HAVE THE SAME FORM
AND RESTRICTIONS AS IN FORM (1) ABOVE.
.SKIP 2
^EXAMPLES: ^NOTICE THAT THE CONSTANT ALWAYS AGREES WITH THE VARIABLE
IN TYPE.
.SKIP 2
.INDENT 5
^^ON Y .LT. 0.0\\
.SKIP 2
SETS A BREAK CONDITION SO THAT IF ^Y BECOMES < 0.0 IN THE CURRENT PROGRAM, ^^MANTIS\\ OUTPUTS
.SKIP 2
.INDENT 5
^&^A^T STATEMENT-REFERENCE\&
.BLANK
.INDENT 5
^&^Y = CONSTANT\&
.SKIP 1
.CENTER
------------------------------------------------------
.SKIP 1
.INDENT 5
^^STOP ON SUBR/IARRAY .GT. 2\\
.SKIP 2
SETS A BREAK CONDITION ON ALL ELEMENTS OF ARRAY ^^IARRAY\\ IN THE
SUBROUTINE ^^SUBR\\.  ^IF ONLY ^^IARRAY\\(3) IS GREATER THAN 2, EXECUTION
WILL HALT AFTER ^^MANTIS\\ DISPLAYS
.SKIP 2
.INDENT 5
^&^A^T STATEMENT-REFERENCE\&
.BLANK
.INDENT 5
^&^^IARRAY\\(3) = CONSTANT\&
.SKIP 2
^IF MORE THAN ONE ELEMENT OF ^^IARRAY\\ IS MADE GREATER THAN 2 THROUGH INPUT, THE SECOND
LINE OF THE MESSAGE IS CHANGED TO
.SKIP 2
.INDENT 5
^^IARRAY =\\
.SKIP 1
.CENTER
------------------------------------------------------
.SKIP 1
.INDENT 5
^^ON ARR .LE. 30.5  AT 7\\
.SKIP 2
NOTIFIES THE USER IF ANY ELEMENT OF ARRAY ^^ARR\\ BECOMES LESS THAN  OR
EQUAL TO 30.5 AT LABEL 7 IN THE CURRENT PROGRAM.  ^^MANTIS\\ DISPLAYS
.SKIP 2
.TEST PAGE 9
.INDENT 5
^&^^AT 7\\\&
.BLANK
.INDENT 5
^&^^ARR(2)=24.0\&\\####(FOR EXAMPLE)
.SKIP 1
.CENTER
------------------------------------------------------
.SKIP 1
.INDENT 5
^^ON MAIN/I(3) .GT. 0 BETWEEN 50 AND 75\\
.SKIP 2
CHECKS IF ^I(3)>0 IN THE STATEMENT RANGE FROM LABEL 50 TO LABEL 75 
IN THE MAIN PROGRAM.
.SKIP 2
^IF THE RANGE WERE
.SKIP 2
.LEFT MARGIN 20
50#####^K=3
.BREAK
#######^I(^K)=^K
.BREAK
#.
.BREAK
#.
.BREAK
#.
.BREAK
75#####^^CONTINUE\\
.SKIP 2
.INDENT -5
^^MANTIS\\ WOULD DISPLAY
.SKIP 2
^&^^AT 50+1\\\&
.BLANK
^&^I(3)=3\&
.SKIP 1
.CENTER
--------------------------------------------------------
.SKIP 1
.INDENT -5
^^STOP ON FUNC/Y .NE. 3.0 AT 99\\
.SKIP 2
.LEFT MARGIN 15
STOPS EXECUTION IF ^Y IS NOT EQUAL TO 3.0 AT THE STATEMENT WITH
LABEL 99 IN FUNCTION ^^FUNC\\.
.SKIP 2
.INDENT -10
^EFFECTS OF AN ^O^N ^COMMAND
.SKIP 2
.LEFT MARGIN 15
.INDEX ^^ON\\ ^BREAK ON AN ^INPUT ^STATEMENT
.INDENT -5
1.###^^MANTIS\\ ALWAYS STOPS EXECUTION AT AN ^O^N BREAK ON AN
INPUT STATEMENT.  ^THE COMMANDS
.SKIP 2
.INDENT 5
^^ON Y  AT  54\\
.BLANK
.INDENT 5
^^STOP ON Y AT 54\\
.SKIP 2
BOTH HALT EXECUTION AT THE STATEMENT
.SKIP 2
.INDENT 5
54  ^^READ\\ (1, 3) ^X, ^Y
.SKIP 2
IN THE CURRENT PROGRAM.
.SKIP 2
.INDENT -5
2.###^IF THE ^O^N VARIABLE IS AN ARRAY,
^^MANTIS\\ DISPLAYS AND HALTS EXECUTION ON INPUT STATEMENTS REGARDLESS
OF THE ^O^N BREAK CONDITION.  ^THE COMMAND
.SKIP 2
.INDENT 5
^^ON  ARR  .LE.  0.0  AT 22\\
.SKIP 2
HALTS EXECUTION AT THE STATEMENT
.SKIP 2
.INDENT 5
22  ^^READ (1, 4) ARR\\
.SKIP 2
EVEN IF ALL ELEMENTS OF ^^ARR\\ ARE ^&GREATER THAN\& 0.0.
.SKIP 2
.INDENT -5
.INDEX ^^ON\\ ^COMMAND
3.###^IF THE SAME VARIABLE APPEARS IN TWO (OR MORE) ^O^N COMMANDS AND THE
STATEMENT RANGES TO BE CHECKED OVERLAP, ONLY THE MOST RECENT COMMAND
TAKES EFFECT.  ^ALL OTHERS ARE ERASED.  ^OF THE COMMANDS 
.SKIP 2
.INDENT 5
^^ON X  BETWEEN  34-1  AND 34+4\\
.BLANK
.INDENT 5
^^ON  X  AT 34\\
.SKIP 2
ONLY THE SECOND TAKES EFFECT.
.SKIP 2
^WHEN THE SAME VARIABLE APPEARS AND THE RANGES DO ^&NOT\& OVERLAP, BOTH 
COMMANDS WILL BE EXERCISED.
.SKIP 2
.INDENT -5
4.###^VARIABLES WHICH ARE ^^EQUIVALENCED\\ ARE TREATED (BY ^O^N
COMMANDS) AS THOUGH THEY WERE
DIFFERENT VARIABLES; HENCE, ^O^N COMMANDS CHECKING ^^EQUIVALENCE\\D VARIABLES
IN OVERLAPPING STATEMENT RANGES WILL ALL BE EXERCISED.  ^IF ^^TRY\\(5) AND 
^^COPY\\(5) ARE EQUIVALENCED AND THE FOLLOWING ^O^N COMMANDS ARE TYPED,
.INDEX ^EQUIVALENCED ^VARIABLES
.SKIP 2
.INDENT 5
^^STOP ON  COPY(3)  .LT.  100.0  AT 23\\
.BLANK
.INDENT 5
^^STOP  ON  TRY  BETWEEN  23 AND  60\\
.SKIP 2
BOTH WILL BE EXERCISED EVEN THOUGH ^^COPY\\ AND ^^TRY\\ REALLY REFER
TO THE SAME MEMORY LOCATIONS.
.INDEX ^BREAK AT AN ^ASSIGNMENT ^STATEMENT
.INDEX ^BREAK ^COMMANDS, REVOKING
.INDEX ^INPUT ^STATEMENT, BREAK AT
.INDEX ^BREAK AT AN ^INPUT ^STATEMENT
.INDEX ^ASSIGNMENT ^STATEMENT, BREAK AT
.SKIP 2
.INDENT -5
5.###^SINCE EQUIVALENCED VARIABLES REALLY REFERENCE THE SAME STORAGE
LOCATIONS, A COMMAND EFFECTING ONE VARIABLE WILL EFFECT THE OTHER, TOO.
.SKIP 2
.INDENT 5
^^STOP ON TRY\\
.SKIP 2
WILL CAUSE EXECUTION TO STOP IF EITHER ^^TRY\\ OR ^^COPY\\ CHANGES VALUE.
.SKIP 2
.INDENT -5
6.###^O^N BREAK COMMAND STRINGS - ^IF AN ^O^N COMMAND CAUSES A BREAK AT AN ASSIGNMENT STATEMENT, ANY 
ACTION OR ^^KILL\\ COMMANDS APPENDED TO THE ^O^N COMMANDS WILL BE
EXERCISED; HOWEVER, IF THE BREAK OCCURS AT AN INPUT STATEMENT (^^READ, ACCEPT, ENCODE, DECODE\\), APPENDED COMMANDS ARE IGNORED. (^SEE
^SECTION 1.2.1 AND 2.4 FOR INFORMATION ON COMMAND STRINGS.)
.SKIP 2
.INDENT -5
7.###^NOTE THAT CORE AND TIME OVERHEAD CAN BECOME HIGH UNLESS THE USER 
TAKES CARE TO RESTRICT THE STATEMENT RANGES CHECKED BY ^O^N COMMANDS.
^FOR INSTANCE, THE COMMAND
.SKIP 2
.INDENT 5
^^ON  MAIN/Y  BETWEEN  MAIN/+1  AND MAIN/+4\\
.SKIP 2
IS BETTER THAN
.SKIP 2
.INDENT 5
^^ON  MAIN/Y\\
.SKIP 2
BECAUSE IT CHECKS A FEW STATEMENTS IN THE MAIN PROGRAM INSTEAD OF THE WHOLE
MAIN PROGRAM.
.SKIP 2
.INDENT -5
8.###^AN ^O^N COMMAND WILL NOT DETECT A CHANGE DUE TO ^^NAMELIST\\ INPUT.
.SKIP 3
.LEFT MARGIN 5
2.2  ^^KILL\\ ^COMMAND
.INDEX ^REVOKE ^BREAK ^COMMANDS
.INDEX ^DELETE ^UNWANTED ^BREAK ^COMMANDS
.SKIP 2
.INDEX ^^KILL\\ ^COMMAND
^THE ^^KILL\\ COMMAND ERASES PREVIOUSLY ENTERED BREAK COMMAND STRINGS.
^ANY SINGLE BREAK COMMAND OR ALL PREVIOUS BREAK COMMANDS MAY BE
REVOKED BY ONE ^^KILL\\ COMMAND.  ^THE FORMS OF THE ^^KILL COMMAND ARE
.SKIP 2
.NOFILL
.TAB STOPS 20
.LEFT MARGIN 10
.INDEX ^^KILL\\
^^KILL\\
.BLANK
^^KILL\\	^A^T STATEMENT-REFERENCE
^^KILL\\	^^ON CALL\\ SUBROUTINE-NAME
^^KILL	BEFORE\\ SUBROUTINE-NAME
^^KILL\\	^O^N VARIABLE [POSITION]
.FILL
.SKIP 2
.LEFT MARGIN 5
^EXAMPLES:
.SKIP 2
.INDENT 5
^^KILL AT MAIN\\/700
.SKIP 2
ERASES THE BREAK POINT AT THE STATEMENT
.SKIP 2
.INDENT 5
700#####^J = 2*^K
.SKIP 2
IN THE MAIN PROGRAM.
.SKIP 2
.INDENT 5
^^KILL ON CALL SUBR\\
.SKIP 2
REVOKES THE BREAKPOINT ON THE ^^CALL\\S TO SUBROUTINE ^^SUBR\\.
.SKIP 2
.INDENT 5
^^KILL BEFORE SUBR\\
.SKIP 2
REVOKES THE BREAK BEFORE THE RETURN FROM SUBROUTINE ^^SUBR.\\
.SKIP 2
.INDENT 5
^^KILL ON Y\\
.SKIP 2
ERASES ALL BREAKS ON THE SCALAR VARIABLE ^Y.
.SKIP 2
.INDENT 5
^^KILL ON ARRAY AT 7\\
.SKIP 2
ERASES ONLY THE BREAKS ON ARRAY VARIABLE ^^ARRAY\\ AT THE STATEMENT 
LABELED 7.
.SKIP 2
.INDENT 5
^^KILL\\
.SKIP 2
ERASES ^&ALL\& BREAK COMMANDS.
.SKIP 2
.INDEX ^ACTION ^COMMANDS
2.3  ^ELEMENTARY ^ACTION ^COMMANDS
.SKIP 2
^FIVE OF THE ACTION COMMANDS (^^GO, STOP, OUTPUT,\\ ^VALUE ^CHANGE, AND
^^EXIT\\) WILL BE DISCUSSED HERE, AND THE REMAINING FOUR WILL BE INCLUDED 
IN ^SECTION 4.3.  ^^ARG\\:N AND ARRAY REFERENCING IN ^^OUTPUT\\ AND ^VALUE ^CHANGE
COMMANDS WILL ALSO BE DESCRIBED IN ^SECTION 4.3.
.INDEX ^^GO\\
.SKIP 2
2.3.1   ^G^O ^COMMAND - ^THE ^G^O COMMAND IS USED TO START OR RESUME
EXECUTION OF THE ^^FORTRAN \\PROGRAM.  ^THE COMMAND HAS TWO FORMS:
.SKIP 2
.INDENT 5
^G^O
.INDEX ^START ^EXECUTION
.SKIP 2
STARTS EXECUTION AT THE ENTRY POINT OR RESUMES EXECUTION FROM THE POINT
WHERE IT WAS LAST STOPPED.  (^TO STOP EXECUTION, SEE
^^STOP\\ COMMAND, ^SECTION 2.3.2).
.SKIP 2
.INDEX ^STATEMENT-^REFERENCE
.INDENT 5
^^GO\\ STATEMENT-REFERENCE
.SKIP 2
RESUMES EXECUTION AT THE EXECUTABLE STATEMENT INDICATED.
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
^G^O 10
.SKIP 2
.INDEX ^RESUME ^EXECUTION
RESUMES EXECUTION AT THE STATEMENT LABELED 10 IN THE CURRENT PROGRAM.
.SKIP 2
.INDENT 5
^^GO SUBR\\/450+2
.SKIP 2
RESUMES EXECUTION AT THE SECOND STATEMENT AFTER LABEL 450 IN 
SUBROUTINE ^^SUBR\\.
.SKIP 2
.INDEX ^^STOP\\ ^COMMAND
.INDEX ^HALT ^EXECUTION
.INDEX ^INTERRUPTING ^EXECUTION
.INDEX ^RETURN ^CONTROL TO ^^MANTIS\\
2.3.2  ^^STOP\\ ^COMMAND - ^THE ^^STOP\\ COMMAND HALTS EXECUTION AND
RETURNS CONTROL TO ^^MANTIS\\ SO THAT MORE COMMANDS MAY BE 
ENTERED.  ^THE ^^STOP\\ COMMAND ALLOWS A PROGRAMMER TO STOP HIS PROGRAM
AT WILL, OUTPUT OR CHANGE VARIABLE VALUES, SET MORE BREAKS, AND
THEN CONTINUE EXECUTION WITH A ^G^O COMMAND.  ^^STOP\\ APPEARED EARLIER
AS A KEYWORD IN BREAK COMMANDS.  ^IT MAY ALSO APPEAR AS A SEPARATE 
COMMAND (AFTER A BREAK COMMAND) IN A COMMAND STRING.
.SKIP 2
^FOR EXAMPLE, THE COMMANDS
.SKIP 2
.INDENT 5
^^AT MAIN/7 ; STOP\\
.BLANK
.INDENT 5
^^STOP AT MAIN\\/7
.SKIP 2
HAVE THE SAME EFFECT.  ^BOTH DISPLAY ^&<7>\& AND HALT EXECUTION
AT THE STATEMENT LABELED 7 IN THE MAIN PROGRAM.
.SKIP 2
.INDEX ^SCALARS
.INDEX ^ARRAY ^ELEMENTS
.INDEX ^^OUTPUT\\
2.3.3  ^^OUTPUT\\ ^COMMAND FOR ^SCALARS AND ^ARRAY ^ELEMENTS - ^THE
^^OUTPUT\\ COMMAND DISPLAYS THE VALUES OF A LIST OF VARIABLES.  ^A
VARIABLE MAY BE A SCALAR, A SINGLE ARRAY ELEMENT OR AN ENTIRE ARRAY. 
^SINCE ARRAYS REQUIRE SPECIAL NOTATION, ^^OUTPUT\\ OF ARRAYS WILL BE COVERED
IN ^SECTION 4.3.1.  ^IF THE VARIABLE IS AN ARRAY ELEMENT, THE
SUBSCRIPT MUST BE AN INTEGER CONSTANT.  ^THE ^^OUTPUT\\ COMMAND HAS
THREE FORMS:
.SKIP 2
.INDENT 5
^^OUTPUT\\ VARIABLE-LIST
.SKIP 2
DISPLAYS VARIABLES AS DECIMAL NUMBERS--INTEGER VARIABLES AS INTEGERS
AND REAL VARIABLES AS REAL NUMBERS.
.SKIP 2
.INDENT 5
.INDEX ^^IN TEXT\\
^^OUTPUT\\ VARIABLE ^^IN TEXT\\ , VARIABLE ^^IN TEXT\\,##...
.SKIP 2
DISPLAYS THE LIST OF VARIABLES AS ^^ASCII\\ CHARACTER STRINGS.
.SKIP 2
.INDENT 5
.INDEX ^^IN OCTAL\\
^^OUTPUT\\ VARIABLE ^^IN OCTAL\\ , VARIABLE ^^IN OCTAL\\,##...
.SKIP 2
DISPLAYS THE LIST OF VARIABLES AS OCTAL NUMBERS.
.SKIP 2
^ANY NUMBER OF SCALARS AND ARRAY ELEMENTS MAY BE IN THE VARIABLE-LIST.
^EACH VARIABLE IN THE LIST REFERENCES ONLY ONE SCALAR OR ARRAY ELEMENT.
.SKIP 2
^EXAMPLES:  ^ASSUME ^J AND ^K^K TO BE INTEGER SCALARS AND ^^ARR\\1 TO BE A
REAL ARRAY.
.SKIP 2
.INDENT 5
^^OUTPUT J, ARR1(1)\\
.SKIP 2
DISPLAYS ^J AS AN INTEGER AND ^^ARR\\1(1) AS A REAL NUMBER.
.SKIP 2
.INDENT 5
^^OUTPUT SUBR/J IN TEXT\\, ^^SUBR/KK IN TEXT\\
.SKIP 2
DISPLAYS ^J AND ^K^K IN SUBROUTINE ^^SUBR\\ AS ^^ASCII\\ CHARACTERS.  ^NOTE: IF THE ROUTINE
QUALIFIER (^^SUBR\\) HAD BEEN OMITTED FOR EITHER VARIABLE, THAT VARIABLE
WOULD HAVE BEEN ASSUMED TO BE IN THE CURRENT PROGRAM.
.SKIP 2
.INDENT 5
^^OUTPUT ARR1(5) IN OCTAL\\
.SKIP 2
DISPLAYS ^^ARR\\1(5) AS AN OCTAL NUMBER.
.SKIP 2
^THE FOLLOWING COMMAND IS INVALID BECAUSE THE SUBSCRIPT IS NOT A CONSTANT.
.SKIP 2
.INDENT 5
^^OUTPUT ARR1(L)\\
.SKIP 2
^TO DISPLAY THE ^LTH VALUE OF ARRAY ^^ARR1\\,
.SKIP 2
.LEFT MARGIN 10
&*^^OUTPUT L\\
.BLANK
^&^L = 5\&
.BLANK
&*^^OUTPUT ARR1(5)\\
.BLANK
^&^^ARR\\1(5) = 2.3\&
.LEFT MARGIN 5
.SKIP 2
^TWO FORMS OF THE ^^OUTPUT\\ COMMAND CAN BE  USED AT THE STATEMENT
^^SUBROUTINE SUBA (Y, Z, X)\\.
.SKIP 2
.LEFT MARGIN 10
^^OUTPUT Y\\
.BLANK
###OR
.BLANK
^^OUTPUT ARG:1\\
.LEFT MARGIN 5
.SKIP 2
^MORE WILL BE SAID ABOUT AN ^^ARG:\\N REFERENCE IN ^SECTION 4.3.1.
.SKIP 2
.INDEX ^EXECUTABLE ^STATEMENT
^IF AN ATTEMPT IS MADE TO ^^OUTPUT\\ A VARIABLE WHICH DOES ^&NOT\& APPEAR
IN AN EXECUTABLE STATEMENT IN THE SPECIFIED ROUTINE (OR CURRENT PROGRAM
IF NONE IS SPECIFIED), ^^MANTIS\\ REPLIES WITH THE ERROR MESSAGE,
.SKIP 2
.INDENT 5
^&?^^NAME UNDEFINED\\\&
.SKIP 2
.INDEX ^VALUE ^CHANGE ^COMMAND
.INDEX ^SCALARS
.INDEX ^ARRAY ^ELEMENTS
2.3.4  ^VALUE ^CHANGE ^COMMAND FOR ^SCALARS AND ^ARRAY ^ELEMENTS - ^THE
^VALUE ^CHANGE COMMAND IS SIMILAR TO A ^^FORTRAN\\ ASSIGNMENT STATEMENT.
^IT CAN BE USED TO CHANGE THE VALUE OF ANY VARIABLE (SCALAR, ARRAY ELEMENT,
OR ARRAY) WHICH HAS APPEARED IN AN ^&EXECUTABLE\& STATEMENT IN A ROUTINE
BEING DEBUGGED WITH ^^MANTIS\\.  ^ARRAY ELEMENTS MUST HAVE INTEGER
CONSTANT SUBSCRIPTS.  ^VALUE CHANGES FOR ENTIRE ARRAYS AND SUBROUTINE
ARGUMENTS (^^ARG\\:N) REQUIRE SPECIAL
NOTATION AND WILL BE COVERED IN ^SECTION 4.3.1.
.SKIP 2
^THE ^VALUE ^CHANGE COMMAND HAS THE FOLLOWING FORM:
.SKIP 2
.INDENT 5
ROUTINE-NAME/VARIABLE = CONSTANT
.SKIP 2
.INDEX ^CURRENT ^PROGRAM
^THE VARIABLE IS EXPECTED TO BE IN THE CURRENT PROGRAM UNLESS A ROUTINE-NAME IS
GIVEN TO LOCATE THE VARIABLE IN ANOTHER PROGRAM.  ^THE CONSTANT
MAY BE ANY LEGAL ^^FORTRAN\\ CONSTANT.  ^AN INTEGER CONSTANT IS CONVERTED TO
A REAL NUMBER IF THE VARIABLE IS REAL; HOWEVER, A REAL CONSTANT
ASSIGNED TO AN INTEGER VARIABLE CAUSES THE ERROR MESSAGE
.SKIP 2
.INDENT 5
^&?^^SYNTAX ERROR\\\&
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
^^MAIN/JUMP(2) = 1000\\
.SKIP 2
^THE ARRAY ELEMENT ^^JUMP\\(2) IN THE MAIN PROGRAM IS ASSIGNED THE VALUE
1000.
.SKIP 2
^THE ^^MANTIS\\ COMMAND
.SKIP 2
.INDENT 5
^^SUBA/DOUBLE\\ = 5432.9^D34
.SKIP 2
CHANGES THE DOUBLE PRECISION SCALAR ^^DOUBLE\\ IN SUBROUTINE ^^SUBA\\ AS
INDICATED.
.SKIP 2
.INDENT 5
^^OCTAL\\ = "777
.SKIP 2
^ASSIGNS THE OCTAL CONSTANT 777 TO THE SCALAR ^^OCTAL\\ IN THE CURRENT
PROGRAM.
.SKIP 2
.LEFT MARGIN 10
^^LOGIC\\(1) = ^T
.BLANK
^^LOGIC\\(2) = ^F
.LEFT MARGIN 5
.SKIP 2
^ASSIGNS THE LOGICAL CONSTANT ^T (TRUE) TO ARRAY ELEMENT ^^LOGIC\\(1)
AND THE CONSTANT ^F (FALSE) TO ^^LOGIC\\(2) IN THE CURRENT PROGRAM.
.SKIP 2
^IF A VALUE CHANGE COMMAND REFERENCES A VARIABLE WHICH HAS NOT APPEARED
IN AN EXECUTABLE STATEMENT IN THE ROUTINE SPECIFIED (OR THE CURRENT PROGRAM
IF NONE IS SPECIFIED), ^^MANTIS\\ RESPONDS WITH AN ERROR MESSAGE:
.SKIP 2
.INDENT 5
^&?^^NAME UNDEFINED\\\&
.SKIP 2
^IT MAY APPEAR THAT THE VALUE OF THE INDEX VARIABLE OF AN
INNERMOST ^D^O LOOP CAN BE CHANGED WHILE EXECUTION IS IN THE
LOOP, BUT THE NEW VALUE MAY NOT BE USED BY THE PROGRAM
IF EXECUTION IS RESUMED.
.SKIP 2
.INDEX ^^EXIT\\ ^COMMAND
2.3.5  ^^EXIT\\ ^COMMAND - ^THE ^^EXIT\\ COMMAND IS USED TO EXIT
EXECUTION, NORMALLY AT THE END OF THE MAIN PROGRAM OR AT ANY OTHER POINT
IN PROGRAM EXECUTION WHEN THE USER FEELS HE HAS FOUND HIS ERROR(S) AND NO LONGER
NEEDS TO CONTINUE EXECUTION.
.SKIP 2
^WHEN EXECUTION REACHES THE TERMINATING ^^STOP\\ OR ^^RETURN\\ STATEMENT
IN THE MAIN PROGRAM, ^^MANTIS\\ OUTPUTS AN ^^EXIT\\ MESSAGE.  ^IF THE 
MAIN PROGRAM WAS COMPILED WITH ^^MANTIS\\, THE ^^EXIT\\ LOCATION IS GIVEN.
^AT THIS POINT, THE USER MAY ^^RESTART\\ HIS PROGRAM (^SECTION
4.3.3), GO BACK TO A PREVIOUS STATEMENT (^SECTION 2.3.1), OR ^^EXIT\\
HIS PROGRAM.
.SKIP 2
.INDEX ^TERMINATE ^EXECUTION ^NORMALLY
^TO TERMINATE EXECUTION NORMALLY AT THE END OF A MAIN PROGRAM WHICH
WAS COMPILED WITH ^^MANTIS\\, RESPOND TO THE ^^MANTIS EXIT\\ MESSAGE WITH THE
WORD '^^EXIT\\' AS SHOWN.
.SKIP 2
.INDENT 5
^&^^EXIT CALLED AT MAIN/\\STATEMENT-REFERENCE\&
.BLANK
.INDENT 5
&*^^EXIT\\
.SKIP 2
^IF THE MAIN PROGRAM WAS ^&NOT\& COMPILED WITH ^^MANTIS\\, THE MESSAGE
.LEFT MARGIN 10
.SKIP 2
^&^^EXIT CALLED AT\\ ?\&
.BLANK
&*^^EXIT\\
.SKIP 2
.LEFT MARGIN 5
IS DISPLAYED AND THE USER MAY END EXECUTION BY TYPING ^^EXIT\\, AS SHOWN.
.SKIP 2
^AS MENTIONED ABOVE, THE USER NEED NOT WAIT FOR THE ^^EXIT\\ MESSAGE.
^TO TERMINATE PROGRAM EXECUTION, ANY TIME ^^MANTIS\\ PROMPTS
FOR A COMMAND WITH A '*', THE ^^EXIT\\ COMMAND MAY BE GIVEN.

.SKIP 2
.INDEX ^COMMAND ^STRINGS
2.4 ^FORMING ^COMMAND ^STRINGS
.SKIP 2
.INDEX ^SIMPLE ^COMMANDS
^SECTION 1.3.1 DESCRIBES TWO FORMS FOR ^^MANTIS\\ COMMANDS:  THE SIMPLE
COMMAND AND THE COMMAND STRING.  ^THE SIMPLE COMMAND IS A SINGLE
^^MANTIS\\ COMMAND.  ^ANY COMMAND MAY BE A SIMPLE COMMAND.  ^A SIMPLE
COMMAND IS ENTERED AFTER A ^^MANTIS\\ PROMPT CHARACTER '*' AND IS 
INTERPRETED IMMEDIATELY.
.SKIP 2
.INDEX ^BREAK ^COMMANDS
^A COMMAND STRING CONSISTS OF A BREAK COMMAND (^^AT, ON CALL, BEFORE,
ON\\) FOLLOWED BY ANY NUMBER OF ^^KILL\\ AND ACTION 
COMMANDS.  ^ONLY THE ACTION COMMANDS COVERED IN ^CHAPTER 2 (^^GO, STOP, \\AND
^^OUTPUT\\ OR ^VALUE ^CHANGE FOR SCALARS, ARRAY ELEMENTS, AND
SUBROUTINE ARGUMENTS) MAY BE APPENDED TO A BREAK COMMAND.  ^EACH 
APPENDED COMMAND IS SEPARATED FROM THE COMMAND PRECEDING IT BY A
SEMICOLON.  ^COMMANDS IN A COMMAND STRING ARE ^&NOT\& EXECUTED IMMEDIATELY
BUT ARE EXECUTED ONLY WHEN PROGRAM EXECUTION REACHES THE BREAKPOINT
SET UP BY THE BREAK COMMAND IN THE COMMAND STRING.
.INDEX ^APPENDED ^COMMAND
.SKIP 2
^TWO EXAMPLES FOLLOW.  ^THE FIRST EXAMPLE IN EACH PAIR SHOWS A SEQUENCE OF
^^MANTIS\\ SIMPLE COMMANDS.  ^THE SECOND SHOWS THE USE OF A COMMAND STRING
TO DO THE SAME TASK.
.SKIP 2
^EXAMPLE ^A:  ^A BREAKPOINT IS ESTABLISHED AT ^^FORTRAN \\STATEMENT
60 IN ^^MAIN\\ WHERE THE USER WISHES TO OUTPUT ^^JTEXT\\.
.LEFT MARGIN 15
.SKIP 2
.INDENT -5
1.###&*^^STOP AT MAIN\\/60
.BLANK
^&^^STORED\&\\
.BLANK
&*^G^O
.BLANK
^&<60>\&##########(^^MANTIS\\ INFORMS THE USER WHEN LABEL 60 IS
.BREAK
##############REACHED AND HALTS EXECUTION.)
.BLANK
&*^^OUTPUT JTEXT IN TEXT\\
.BLANK
^&^^HI\\\&
.SKIP 2
^^MANTIS\\ OUTPUTS ^^JTEXT\\ AND PROMPTS AGAIN.
^EXECUTION IS STILL STOPPED AT THE STATEMENT LABELED 60.
.SKIP 2
&*^G^O
.SKIP 2
^PROGRAM CONTINUES EXECUTING.
.SKIP 2
.INDENT -5
2.###&*^^AT MAIN/60 ; OUTPUT JTEXT IN TEXT\\
.BLANK
^&^^STORED\\\&
.BLANK
&*^G^O
.BLANK
^&<60>\&
.BLANK
^&^^JTEXT = HI\\\&
.SKIP 2
^^MANTIS\\ NOTIFIES USER WHEN ^^FORTRAN\\ STATEMENT 60 IS REACHED, OUTPUTS
^^JTEXT\\ AT THAT POINT, AND CONTINUES EXECUTION.
.SKIP 2
.LEFT MARGIN 5
.INDEX ^VALUE ^CHANGE ^COMMAND
.INDEX ^^KILL\\
^EXAMPLE ^B:  ^USE OF ^VALUE ^CHANGE AND ^^KILL\\ COMMANDS TO CHANGE A
SUBPROGRAM ARGUMENT.
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
1.###&*^^STOP ON CALL SUBA\\
.BLANK
^&^^STORED\\\&
.BLANK
&*^G^O
.BLANK
^&^^SUBR CALLED FROM MAIN/60+1\\\&##(^^MANTIS\\ TELLS USER WHEN
.BREAK
########################### THE ^^ON\\ ^^CALL\\ BREAKPOINT
.BREAK
############################IS REACHED, STOPS
.BREAK
############################EXECUTION, AND PROMPTS
.BREAK
############################FOR MORE COMMANDS.)
.SKIP 2
&*^X^X = 123.32
.BLANK
&*^^KILL ON CALL SUBA\\
.BLANK
&*^G^O
.SKIP 2
^^MANTIS\\ CHANGES THE VALUE OF SCALAR ^X^X, ERASES THE ^^ON CALL\\ 
BREAK AND CONTINUES PROGRAM EXECUTION.
.SKIP 2
.INDENT -5
2.###&*^^ON CALL SUBA ; XX = 321.32 ; KILL ON CALL SUBA\\
.BLANK
^&^^STORED\\\&
.BLANK
&*^G^O
.BLANK
^&^^SUBA CALLED FROM MAIN/80+1\\\&
.SKIP 2
^^MANTIS\\ NOTIFIES USER WHEN A CALL TO SUBROUTINE ^^SUBA\\ IS
REACHED, CHANGES THE VALUE OF ^X^X, ERASES THE ^^ON CALL\\ BREAK, AND
CONTINUES PROGRAM EXECUTION.
.SKIP 2
^IN THIS EXAMPLE, THE ^^ON CALL SUBA\\ COMMAND SETS A BREAK ONLY ON THE FIRST CALL TO SUBROUTINE ^^SUBA\\ BECAUSE
AT THAT FIRST BREAK, THE BREAKPOINT IS ERASED WITH A ^^KILL\\ COMMAND.
.SKIP 2
^NOTICE THAT IN BOTH EXAMPLES, THE COMMAND SEQUENCES WHICH INCORPORATE
A COMMAND STRING ARE SHORTER AND LESS COMPLICATED THAN THE SEQUENCES USING
ONLY SIMPLE COMMANDS.
.LEFT MARGIN 5
.TITLE ^^MANTIS\\ ^CHAPTER 3
.PAGE
.SKIP 3
.INDEX ^RUNNING A ^PROGRAM WITH ^^MANTIS\\
3.0  ^^RUNNING A PROGRAM WITH MANTIS\\
.SKIP 2
.INDEX ^INVOKING ^^MANTIS\\
^INVOKING ^^MANTIS\\ REQUIRES COMMUNICATION WITH THE MONITOR VIA THE
^&^^DEBUG, COMPILE, LOAD\\\&, OR ^&^^EXECUTE\\\& COMMANDS, DESCRIPTIONS OF WHICH
APPEAR IN THE ^^PDP\\-10 REFERENCE HANDBOOK AND THE ^^TOPS\\-10 OPERATING
SYSTEM COMMANDS MANUAL.(1)
.FOOTNOTE 6
.LEFT MARGIN 5
.SKIP 1
-------------------
.BREAK
(1) ^FORMERLY, THE DEBUG COMMAND CAUSED THE ^^DDT CUSP\\ TO BE LOADED
WITH THE FILES IN THE FILE LIST.  ^THE ^^DEBUG\\ COMMAND WILL NOW LOAD
WITH EITHER ^^MANTIS\\ OR ^^DDT\\ DEPENDING ON THE FILENAME
EXTENSION OR SWITCHES.
!
^IF THE FIRST FILE IN THE OPERAND LIST FOR ONE OF THESE COMMANDS IS A 
^^FORTRAN\\ FILE (INDICATED BY AN EXTENSION OF ^F4 OR A NONSTANDARD
EXTENSION), ^^MANTIS\\ WILL BE LOADED; IF THE FIRST FILE IN THE LIST 
HAS AN EXTENSION WHICH REFERS TO ANOTHER COMPILER (^^MAC,
CBL, \\OR ^^ALG\\), THEN ^^DDT\\ OR THE DEBUGGER FOR THAT LANGUAGE WILL BE LOADED.  ^FOR EXAMPLE, THE FOLLOWING
COMMAND LOADS THE FILES ^^MASTER\\ AND ^^ALPHA\\ WITH ^^MANTIS\\ AND GENERATES
OUTPUT AS SHOWN:
.SKIP 2
.LEFT MARGIN 10
.INDEX ^^DEBUG\\
&.^^DEBUG MASTER,ALPHA\\
.BLANK
^&^^FORTRAN:MASTER\\\&
.BLANK
^&^^FORTRAN:ALPHA\\\&
.BLANK
^&^^LOADING\\\&
.BLANK
^&^^MANTIS V3\\\&
.BLANK
^&^^CURRENT PROGRAM IS MAIN\\\&
.BLANK
^&^^READY\\\&
.BLANK
&*
.SKIP 2
.LEFT MARGIN 5
^AT THIS POINT, ^^MANTIS\\ IS READY TO ACCEPT COMMANDS FROM THE USER.
.SKIP 2
^OTHER EXAMPLES OF USING ^^DEBUG\\ TO LOAD WITH ^^MANTIS\\ FOLLOW:
.SKIP 2
.LEFT MARGIN 10
#.^^DEB#####NOVA.F4, SUB\\
.BLANK
#.^^DEB#####RUN, SUBRTN\\
.BLANK
#.^^DEB#####PROG.Q, DUMMY.SUB\\
.SKIP 2
.INDEX ^SWITCHES; /^^NOMAN\\
.LEFT MARGIN 5
.INDEX /^^NOMAN\\ ^SWITCH
^THE /^^NOMAN\\ SWITCH MAY BE USED TO PREVENT A SPECIFIC FILE IN THE
LIST FROM BEING LOADED WITH ^^MANTIS\\ .  ^IF THIS SWITCH
IS USED, THE VARIABLE NAMES AND STATEMENT NUMBERS IN THE FILE AFFECTED MAY NOT
BE REFERENCED IN ^^MANTIS\\ COMMANDS, AND THE CORE WHICH WOULD OTHERWISE
BE REQUIRED FOR THE SYMBOL TABLE IS FREED.
.SKIP 2
.INDEX ^PROGRAMS ^EXPLICITLY ^COMPILED WITH ^^MANTIS\\
^THE ^^COMPILE, LOAD,\\ OR ^^EXECUTE\\ COMMANDS WILL ALSO LOAD WITH
^^MANTIS\\ IF THE /^^MAN\\ SWITCH IS USED.
.SKIP 2
^THE CORE IMAGE
OF A PROGRAM COMPILED WITH ^^MANTIS\\ MAY NOT BE SAVED.
.INDEX /^^MAN\\ ^SWITCH
.SKIP 2
^TO ^^EXECUTE\\ ALL FILES IN THE LIST WITH ^^MANTIS\\, USE A COMMAND OF
THE FOLLOWING FORM:
.INDEX ^SWITCHES: /^^MAN\\
.SKIP 2
.LEFT MARGIN 10
&.^^EX /MAN FILEA, FILEB.F4, FILEG\\
.BLANK
^&^^FORTRAN:FILEA\\\&
.BLANK
^&^^FORTRAN:FILEB.F4\\\&
.BLANK
^&^^FORTRAN.FILEG\\\&
.BLANK
^&^^LOADING\\\&
.BLANK
^&^^MANTIS V3\\\&
.BLANK
^&^^CURRENT PROGRAM IS MAIN\\\&
.BLANK
&*
.SKIP 2
.LEFT MARGIN 5
^TO ^^LOAD, EXECUTE\\, OR ^^COMPILE\\  ONLY SELECTED FILES WITH
^^MANTIS\\, A COMMAND OF THE FOLLOWING FORM IS USED (^^LOAD\\ OR
^^EXECUTE\\ COULD APPEAR INSTEAD OF COMPILE):
.SKIP 2
.LEFT MARGIN 10
&.^^COM##########FILEA/MAN, FILEB.F4, FILEG/MAN\\
.INDEX ^FILES ^COMPILED WITH ^^MANTIS\\
.SKIP 2
.LEFT MARGIN 5
^FILES TO WHICH THE /^^MAN\\ SWITCH IS
APPENDED ARE COMPILED WITH ^^MANTIS\\.
.TITLE ^^MANTIS\\ ^CHAPTER 4
.PAGE
.SKIP 3
4.0  ^^ADVANCED COMMANDS\\
.SKIP 2
^IN THIS CHAPTER WE COVER THE REMAINING ^^MANTIS\\ COMMANDS.  ^THESE
INCLUDE MONITORING COMMANDS, ^I/^O DEVICE CONTROL COMMANDS, AND
ADDITIONAL ACTION COMMANDS.  ^COMMANDS DISCUSSED HERE ARE MORE 
SOPHISTICATED THAN ^CHAPTER 2 COMMANDS; ALSO, WHEREAS ^CHAPTER 2 COMMANDS
MAY BE COMBINED INTO COMMAND STRINGS, ^CHAPTER 4 COMMANDS ^&MUST\& APPEAR
^&ONLY\& AS SIMPLE COMMANDS.
.SKIP 2
.INDEX ^MONITORING ^COMMANDS
4.1  ^MONITORING ^COMMANDS
.SKIP 2
^THE MONITORING COMMANDS ^^HISTORY\\ AND ^^TRACE\\ RECORD BRANCHING
INFORMATION.  (^A BRANCH IS A DEVIATION FROM SEQUENTIAL PROGRAM
EXECUTION;  ^^CALL, RETURN,\\ AND ^^GO TO\\ ARE EXAMPLES OF ^^FORTRAN\\
BRANCHING STATEMENTS.)  ^^SUBCHECK\\ MONITORS SUBSCRIPTS ASSOCIATED WITH
ARRAYS AND THE STATEMENT LOCATION QUERY TELLS THE USER WHICH 
PROGRAM STATEMENT IS BEING EXECUTED AT ANY GIVEN TIME.  ^DESCRIPTIONS
OF THESE FOUR COMMANDS FOLLOW.
.SKIP 2
.INDEX ^^HISTORY\\ ^COMMAND
.INDEX ^RECORD OF ^EXECUTION ^BRANCHES
4.1.1  ^^HISTORY\\ ^COMMAND - ^THE ^^HISTORY\\ COMMAND OUTPUTS A RECORD
OF EXECUTION BRANCHES FOR ^^MANTIS\\-COMPILED ROUTINES.  ^BRANCH
MESSAGES ARE STORED IN A PUSH-DOWN LIST WITH THE MOST RECENT BRANCH MESSAGE
AT THE TOP OF THE LIST.  ^A MAXIMUM OF 200 ENTRIES MAY BE HELD  IN THE
LIST.  ^IF THE PROGRAM BEING MONITORED CONTAINS MORE THAN 200 BRANCHES,
ONLY THE LAST 200 WILL BE AVAILABLE IN THE TABLE.
.SKIP 2
^CALLS AND RETURNS FROM SUBPROGRAMS AND ^^MANTIS GO\\ COMMANDS ARE
^&ALWAYS\& LOGGED IN THE PUSH-DOWN LIST, OR ^^HISTORY\\ TABLE,
AS IT IS CALLED.  ^THIS INFORMATION IS PROVIDED WHETHER OR NOT THE USER
EVER OUTPUTS IT BY TYPING THE ^^HISTORY\\ COMMAND.  ^IF A USER ALSO
WISHES NOTIFICATION OF BRANCHES CAUSED BY ^^GO TO\\ AND ^I^F STATEMENTS,
A ^^TRACE\\ COMMAND MUST BE GIVEN, (^SEE ^SECTION 4.1.2)  ^^MANTIS\\ 
DOES NOT RECORD THE ENTRY OR LOOPING OF A ^D^O LOOP; HOWEVER, BRANCHING
STATEMENTS (^^CALL, GO TO\\, ETC.) WITHIN A ^D^O LOOP ARE MONITORED IN
THE ^^HISTORY\\ TABLE.
.SKIP 2
^THE ^^HISTORY\\ COMMAND IS ONE WORD.
.SKIP 2
.INDENT 5
&*^^HISTORY\\
.SKIP 2
^TWO EXAMPLES OF ^^HISTORY\\ OUTPUT ARE GIVEN AT THE END OF ^SECTION 4.1.2.
.SKIP 2
.INDEX ^^TRACE\\ ^COMMAND
.INDEX ^MONITOR ^EXECUTION ^BRANCHES
4.1.2  ^^TRACE\\ ^COMMAND - ^THE ^^TRACE\\ COMMAND INITIATES MONITORING
OF EXECUTION BRANCHES DUE TO ^^GO TO\\, ARITHMETIC ^I^F, AND LOGICAL
^I^F STATEMENTS.  ^NOTIFICATION OF EACH BRANCH IS ADDED TO THE ^^HISTORY\\
TABLE WHICH WILL THEN HOLD ^^GO TO\\ AND ^I^F BRANCH MESSAGES AS WELL AS 
THE NORMAL ^^CALL, RETURN\\, AND ^^MANTIS GO\\ COMMAND MESSAGES,
(^SEE ^EXAMPLE 2 BELOW). ^^TRACE\\ MONITORING BEGINS WHEN A ^^TRACE\\
COMMAND IS ENTERED AND CONTINUES UNTIL A ^^STOP TRACE\\ COMMAND IS 
ISSUED.  ^ONLY ROUTINES COMPILED WITH ^^MANTIS\\ MAY BE ^^TRACE\\D.
^IF THE USER REQUESTS ^^TRACE\\ING FOR THE ENTIRE EXECUTION
OF A LONG PROGRAM, 
THE TIME OVERHEAD DURING PROGRAM EXECUTION CAN BECOME VERY HIGH.
.SKIP 2
^THE ^^TRACE\\ COMMAND HAS THREE LEVELS:
.SKIP 2
.INDENT 5
.INDEX ^^TRACE\\
&*^^TRACE\\
.SKIP 2
CAUSES ^^GO TO\\ AND ^I^F BRANCHES TO BE INCLUDED IN THE ^^HISTORY\\
TABLE.  ^IN THIS FORM, ^^HISTORY\\ COMMANDS MUST BE GIVEN LATER TO OUTPUT
THE LIST OF BRANCHES.
.SKIP 2
.INDENT 5
.INDEX ^^TRACE OUTPUT\\
&*^^TRACE OUTPUT\\
.SKIP 2
CAUSES THE SAME MESSAGE TO BE OUTPUT AS IS PUT IN THE ^^HISTORY\\ TABLE
WHENEVER A BRANCH OCCURS.
.SKIP 2
.INDENT 5
.INDEX ^^TRACE PAUSE\\
&*^^TRACE PAUSE\\
.SKIP 2
IS THE SAME AS ^^TRACE OUTPUT\\ EXCEPT IT ALSO HALTS EXECUTION AFTER EACH
BRANCH SO THAT ADDITIONAL ^^MANTIS\\ COMMANDS MAY BE ISSUED.  ^EXECUTION 
RESUMES WHEN THE USER TYPES A ^G^O COMMAND.  (^SEE ^SECTION 2.3.1).
.SKIP 2

^EACH ^^TRACE\\ LEVEL ADDS TO THE INFORMATION GIVEN BY THE PREVIOUS
LEVEL.
.INDEX ^DISCONTINUE ^^TRACE\\ING
.INDEX ^^TRACE\\, DISCONTINUE
^TO DISCONTINUE ^^TRACE\\ING COMPLETELY, TYPE
.SKIP 2
.INDENT 5
.INDEX ^^STOP TRACE\\
&*^^STOP TRACE\\
.SKIP 2
^IF ^^TRACE PAUSE\\ IS IN EFFECT AND THE USER NO LONGER WISHES
EXECUTION TO BE HALTED AT EACH BRANCH, HE MAY TYPE
.SKIP 2
.NOFILL
.TAB STOPS 10 35
	&*^^STOP TRACE PAUSE\\	TO REDUCE ^^TRACE\\ING TO THE ^^TRACE
		OUTPUT\\ LEVEL, OR
.BLANK
	&*^^STOP TRACE OUTPUT\\	TO REDUCE THE ^^TRACE\\ LEVEL.  ^THIS
		SECOND COMMAND ALSO WORKS IF ^^TRACE
		OUTPUT\\ IS IN EFFECT.
.FILL
.SKIP 2
^EXAMPLE 1:
.SKIP 2
^THIS ^^HISTORY\\ LOG WAS NOT PRECEDED BY A ^^TRACE\\ REQUEST.
.SKIP 2
.LEFT MARGIN 5
.INDENT 5
&*^^HISTORY\\
.BLANK
.INDENT 5
^&^^RETURNED TO MAIN\\/20-2\&
.BLANK
^THE MOST RECENT BRANCH WAS A RETURN TO THE MAIN PROGRAM FROM SUBROUTINE ^^SUBA\\.
.BLANK
.INDENT 5
^&^^CMD GO TO SUBA\\/5+1\&
.BLANK
^^A MANTIS\\ COMMAND ^^GO SUBA\\/5+1 WAS EXECUTED.
.BLANK
.INDENT 5
^&^^SUBA CALLED\\\&
.BLANK
^THE PROGRAM BRANCHES TO SUBROUTINE ^^SUBA\\.
.SKIP 2
^EXAMPLE 2:
.SKIP 2
^THIS ^^HISTORY \\LOG INCLUDES THE BRANCHES CAUSED BY A ^^TRACE\\
REQUEST.  ^A USER PROBABLY WOULD WANT TO GIVE THE ^^TRACE \\COMMAND EITHER
BEFORE OR DURING PROGRAM EXECUTION AND TO GIVE THE ^^HISTORY\\ AT THE VERY END OF EXECUTION.  ^TO REDUCE TIME OVERHEAD,
A ^^STOP TRACE\\ COMMAND SHOULD BE GIVEN AS SOON AS ^^TRACE\\ING IS
NO LONGER NEEDED.
.SKIP 2
.INDENT 5
&*^^TRACE\\
.BLANK
.INDENT 5
&*^G^O
.SKIP 3
.INDENT 5
^^EXIT CALLED AT\\ STATEMENT-REFERENCE
.BLANK
.INDENT 5
&*^^HISTORY\\
.BLANK
.INDENT 5
^&^^RETURN TO MAIN\\/20-2\&
.BLANK
^THE MOST RECENT BRANCH WAS A RETURN TO THE MAIN PROGRAM FROM SUBROUTINE ^^SUBA\\.
.BLANK
.INDENT 5
^&^^CMD GO TO SUBA\\/5+1\&
.BLANK
^^A MANTIS GO SUBA\\/5+1 COMMAND WAS EXECUTED.
.BLANK
.INDENT 5
^&^^IF TRUE AT SUBA\\/603\&
.BLANK
^NOTIFICATION OF A LOGICAL ^I^F BRANCH.
.BLANK
.INDENT 5
^&^^SUBA CALLED\\\&
.BLANK
^THE SUBROUTINE ^^SUBA\\ WAS CALLED.
.SKIP 2
.INDENT 5
&*^^EXIT\\
.SKIP 2
^EXECUTION IS TERMINATED BY AN ^^EXIT\\ COMMAND.
.SKIP 2
.INDEX ^^EXIT\\ ^COMMAND
.INDEX ^^SUBCHECK\\ ^COMMAND
.INDEX ^CHECK ^ARRAY ^SUBSCRIPTS
.INDEX ^ILLEGAL ^ARRAY ^REFERENCE
4.1.3  ^^SUBCHECK\\ ^COMMAND - ^THE ^^SUBCHECK\\ COMMAND CHECKS ARRAY
SUBSCRIPTS AND HALTS EXECUTION WHENEVER A SUBSCRIPT GOES OUT OF THE
ARRAY BOUNDS.  ^ONLY VARIABLE SUBSCRIPTS ARE CHECKED.  ^A USER HAS THE
OPTION OF MONITORING A PARTICULAR ARRAY, ALL ARRAYS IN A SPECIFIED
ROUTINE, OR ALL ARRAYS IN THE ENTIRE PROGRAM.  ^OF COURSE, ARRAYS CAN 
ONLY BE MONITORED IN ROUTINES COMPILED WITH ^^MANTIS.\\
^THE ^^SUBCHECK\\ COMMAND HAS THE FOLLOWING FORMS:
.SKIP 2
.INDENT 5
.INDEX ^POSITION ^REFERENCE
.INDEX ^SUBSCRIPT ^CHECKING, ARRAYS
&*^^SUBCHECK\\ ROUTINE-NAME/ARRAY-NAME [POSITION]
.SKIP 2
^CHECKS SUBSCRIPTS FOR THE INDICATED ARRAY AT THE INDICATED STATEMENT
OR RANGE OF STATEMENTS IN THE SPECFIED ROUTINE.  ^IF POSITION
IS OMITTED, THE ARRAY IS CHECKED THROUGHOUT THE SPECIFIED ROUTINE:
.SKIP 2
.INDENT 5
&*^^SUBCHECK MAIN/ARRAY\\
.SKIP 2
^IF THE ARRAY-NAME ^&AND\& THE POSITION ARE OMITTED, ALL ARRAYS IN
THE SPECIFIED ROUTINE ARE CHECKED.
.SKIP 2
.INDENT 5
&*^^SUBCHECK SUBR/\\
.SKIP 2
^IF THE ROUTINE-NAME IS OMITTED, BUT THE ARRAY-NAME IS PRESENT,
THE CURRENT PROGRAM IS ASSUMED.
.SKIP 2
.INDENT 5
&*^^SUBCHECK  ARRAY\\
.SKIP 2
^IF THE ROUTINE-NAME, ARRAY-NAME AND POSITION ARE ALL OMITTED, ALL
ARRAYS IN ALL ROUTINES ARE MONITORED.  ^THIS IS THE MOST EXPENSIVE FORM
OF THE ^^SUBCHECK\\ COMMAND.
.INDEX ^^SUBCHECK\\ ^COMMAND

.SKIP 2
.INDENT 5
&*^^SUBCHECK\\
.SKIP 2
^THE FULL FORM OF THE COMMAND IS LEAST COSTLY SINCE IT NARROWS THE 
CHECKING TO ONE ARRAY IN ONE ROUTINE IN A SPECIFIC RANGE. ^FOR EXAMPLE:
.SKIP 2
.INDENT 5
&*^^SUBSCHECK MAIN/II  AT  MAIN\\/55-1
.SKIP 2
CHECKS TO SEE IF ANY SUBSCRIPT FOR ARRAY ^I^I  IS OUT OF RANGE &A&T
THE EXECUTABLE STATEMENT PRECEDING LABEL 55 IN THE MAIN 
PROGRAM.
.SKIP 2
.INDENT 5
&*^^SUBCHECK  II BETWEEN 55 AND 230+1\\
.SKIP 2
MONITORS SUBSCRIPTS FOR ARRAY ^I^I FROM THE EXECUTABLE STATEMENT LABELED
55 TO THE EXECUTABLE STATEMENT ONE PAST LABEL 230 IN THE CURRENT
PROGRAM.
.SKIP 2
.INDENT 5
&*^^SUBCHECK SUBR/ , BETWEEN 100 AND 220\\
.SKIP 2
MONITORS SUBSCRIPTS FOR ALL ARRAYS IN SUBROUTINE ^^SUBR\\
FROM EXECUTABLE STATEMENT LABELED 100 TO THE ONE LABELED 220.  ^NOTE
THE COMMA TO INDICATE 'ALL' ARRAYS.
.SKIP 2
^^MANTIS R\\ESPONSE TO A ^^SUBCHECK\\ ^COMMAND
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
1.###^^MANTIS\\ DOES NOT MONITOR  CONSTANT
SUBSCRIPTS, E.G., ^^YTEST\\(3,1), NOR DOES IT ATTEMPT TO MONITOR ARRAYS
WHICH DO NOT EXIST IN THE ROUTINE AND/OR POSITION SPECIFIED. 
.SKIP 2
.INDENT -5
2.###^WHEN A SUBSCRIPT FOR A MONITORED ARRAY GOES OUT OF BOUNDS, EXECUTION
IS INTERRUPTED AT THE STATEMENT WHERE THE SUBSCRIPT ERROR OCCURRED. ^A ^^USE TTY\\ COMMAND IS GIVEN FOR THE USER.  ^THE
USER MAY THEN ENTER ^^MANTIS\\ COMMANDS TO CORRECT THE SUBSCRIPT, BRANCH
TO ANOTHER PROGRAM, OR DO WHATEVER ELSE HE WANTS.
.SKIP 2
.LEFT MARGIN 25
.INDENT -5
A.###^IF A USER SIMPLY CONTINUES EXECUTION WITH A ^G^O COMMAND WHEN
THE INTERRUPTION OCCURS, THE ERRONEOUS SUBSCRIPT WILL BE USED.
.SKIP 2
.INDENT -5
.INDEX ^ILLEGAL ^ARRAY ^REFERENCE
B.###^IF AN ILLEGAL ARRAY REFERENCE OCCURS WITHIN AN ^I/^O STATEMENT
(E.G., ^^READ, ACCEPT, WRITE, TYPE\\), EXECUTION OF THAT STATEMENT
WILL BE COMPLETED.  ^INPUT DATA SENT TO A BAD ARRAY LOCATION GETS 
THROWN AWAY.  ^ZEROS ARE OUTPUT FOR DATA THE USER ATTEMPTS TO 
OUTPUT FROM A BAD ARRAY LOCATION.  ^WHEN THE ^I/^O IS COMPLETED,
A LIST OF THE ILLEGALLY REFERENCED ARRAYS IS OUTPUT FOR THE USER.
^REMEMBER, THIS IS ONLY TRUE WHEN ^^MANTIS\\ IS ^^SUBCHECK\\ING THE
^I/^O STATEMENT.
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
3.###^IMPORTANT DETAILS
.SKIP 2
.LEFT MARGIN 25
.INDENT -5
A.###^^SUBCHECK\\ING A SPECIFIC ARRAY IS DONE ^&ONLY\& WITHIN THE
ROUTINE SPECIFIED IN THE COMMAND.  ^THUS, IF A USER WISHES TO CHECK
AN ARRAY IN MORE THAN ONE ROUTINE, HE MUST GIVE A ^^SUBCHECK\\ COMMAND
FOR ^&EACH\& ROUTINE.
.SKIP 2
.LEFT MARGIN 15
^EXAMPLE: ^ARRAY ^X^Y IS TO BE CHECKED IN SUBROUTINES ^^SUBA AND SUBB\\.
.SKIP 2
.INDENT 5
&*^^SUBCHECK  SUBA/XY\\
.BLANK
.INDENT 5
&*^^SUBCHECK  SUBB/XY\\
.SKIP 2
.LEFT MARGIN 25
.INDENT -5
B.###^^SUBCHECK\\ING A SPECIFIC ARRAY DOES ^&NOT\& CAUSE MONITORING
OF ARRAYS EQUIVALENCED TO IT.
.LEFT MARGIN 15
.SKIP 2
^EXAMPLE:  ^IF THE FOLLOWING STATEMENTS OCCUR IN THE CURRENT PROGRAM,
.SKIP 2
.INDENT 5
^^DIMENSION A(100), B(100)\\
.BLANK
.INDENT 5
^^EQUIVALENCE (A(1), B(1))
.SKIP 2
^TWO ^^SUBCHECK\\ COMMANDS ARE NEEDED, ^A AND ^B:
.SKIP 2
.INDENT 5
&*^^SUBCHECK A\\
.BLANK
.INDENT 5
&*^^SUBCHECK B\\
.SKIP 2
.INDEX ^DISCONTINUE ^SUBSCRIPT ^CHECKING
^TO DISCONTINUE SUBSCRIPT CHECKING, PRECEDE THE ^^SUBCHECK\\ COMMAND
WITH THE WORD ^^STOP\\.
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
&*^^STOP SUBCHECK\\
.SKIP 2
ERASES ALL ^^SUBCHECK\\ COMMANDS.
.SKIP 2
.INDENT 5
&*^^STOP SUBCHECK MAIN\\/
.SKIP 2
.INDEX ^^SUBCHECK\\ ^COMMANDS, ERASE ALL
ERASES ALL ^^SUBCHECK\\ COMMANDS WHICH WERE SET UP FOR ARRAYS IN THE
MAIN PROGRAM.
.SKIP 2
.INDENT 5
&*^^STOP SUBCHECK MAIN/II\\
.SKIP 2
ERASES ALL ^^SUBCHECK\\ COMMANDS FOR THE ARRAY ^I^I IN THE
MAIN PROGRAM.
.SKIP 2
.INDEX ^STATEMENT ^LOCATION ^QUERY
.LEFT MARGIN 5
4.1.4 ^STATEMENT ^LOCATION ^QUERY - ^THE LOCATION COMMAND MAKES IT POSSIBLE
TO OUTPUT TO THE USER TELETYPE THE STATEMENT LOCATION REFERENCE OF ANY
EXECUTION BREAKPOINT.  ^WHENEVER ^^MANTIS\\ REGAINS CONTROL AT A 
BREAKPOINT AND PROMPTS FOR COMMANDS, THE PROGRAMMER MAY TYPE A 
CARRIAGE RETURN AND ^^MANTIS\\ RESPONDS AS FOLLOWS:
.SKIP 2
.INDENT 5
&*@###################(@ DESIGNATES CARRIAGE RETURN.)
.BLANK
.INDENT 5
^&^^PROGRAM AT\\ STATEMENT-REFERENCE\&
.BLANK
.INDENT 5
&*
.SKIP 2
^GENERALLY, ^^MANTIS\\ AUTOMATICALLY OUTPUTS A STATEMENT LOCATION
MESSAGE WHEN IT GAINS CONTROL AT A BREAKPOINT.  ^IF ^^MANTIS\\ OUTPUT
(MESSAGES, ERROR DIAGNOSTICS, AND DATA) IS SENT TO THE USER TELETYPE,
THERE IS LITTLE NEED FOR THE ^STATEMENT ^LOCATION COMMAND; HOWEVER, IF
^^MANTIS\\ OUTPUT IS SENT TO A ^&DISK\& FILE (^SEE ^^USE\\ COMMAND,
^SECTION 4.2.2), THE ^STATEMENT ^LOCATION COMMAND IS NEEDED TO OUTPUT
BREAKPOINT MESSAGES ON THE USER TELETYPE AS WELL AS THE DISK FILE.
.INDEX ^OUTPUT ^BREAKPOINT ^MESSAGES ON THE ^USER ^TELETYPE
.SKIP 2
.TEST PAGE 10
^EXAMPLE:
.SKIP 2
.LEFT MARGIN 40
.INDENT -30
^&^INFORMATION ON USER ^^TTY\\######^INFORMATION STORED IN DISK FILE ^^MANT.DAT\\\&
.BLANK
.LEFT MARGIN 10
&*^^USE MANT\\
.BLANK
&*^^AT 155 ; OUTPUT X ; STOP\\
.BLANK
&*^^ON ARRAY .LT. 100.0\\
.BLANK
&*^G^O
.LEFT MARGIN 40
.BLANK
^&<155>\&
.BLANK
^&^X = 987.5\&
.BLANK
.LEFT MARGIN 10
&*@
.BLANK
^&^^PROGRAM AT 155\\\&
.BLANK
&*^G^O###########################^&^A^T 155 + 4\&
.BLANK
.INDENT 30
^&^^ARRAY\\(3) = 2.5\&
.BLANK
&*@
.BLANK
^&^^PROGRAM AT 155 + 4\&\\
.BLANK
&*.
.BREAK
#.
.BREAK
#.
.BREAK
#.
.SKIP 2
.LEFT MARGIN 5
^UNDERLINED TEXT IS ^^MANTIS\\ OUTPUT.
.SKIP 3
.INDEX ^INPUT/^OUTPUT ^DEVICE ^CONTROL ^COMMANDS
4.2  ^INPUT/^OUTPUT ^DEVICE ^CONTROL ^COMMANDS
.SKIP 2
.INDEX ^^USE\\ ^COMMAND
.INDEX ^^MANTIS\\ ^OUTPUT ^SENT TO ^DISK ^FILE
.INDEX ^^MANTIS\\ ^OUTPUT ^SENT TO ^TELETYPE
4.2.1  ^^USE\\ ^COMMAND - ^THE ^^USE\\ COMMAND DIRECTS ^^MANTIS\\ OUTPUT EITHER TO A FILE ON
DISK OR TO THE USER'S ^^TTY\\.  ^OUTPUT NORMALLY GOES TO THE 
USER'S TELETYPE, BUT A USER MAY REROUTE ^^MANTIS\\ MESSAGES AND
OUTPUT TO A DISK FILE SO IT MAY LATER BE LISTED ON A ^^TTY\\ OR A
LINE PRINTER.
.SKIP 2
^THE FORMS OF THE ^^USE\\ COMMAND ARE:
.SKIP 2
.LEFT MARGIN 30
.INDENT -20
&*^^USE TTY\\###########^SEND ^^MANTIS\\ OUTPUT TO THE USER'S
TELETYPE. (THE DEFAULT)
.BLANK
.INDENT -20
&*^^USE\\ FILENAME#######^SEND ^^MANTIS\\ OUTPUT TO THE DISK FILE
WITH THE SPECIFIED FILENAME.
.BLANK
'FILENAME' IS A 1 TO 5 CHARACTER NAME OF A FILE TO
BE CREATED, OR ADDED TO, ON
DISK.  ^THE EXTENSION WILL
BE ^^DAT\\, BUT THE EXTENSION
SHOULD NOT BE IN THE ^^USE\\ COMMAND.
.SKIP 2
.LEFT MARGIN 5
^^MANTIS\\ USES LOGICAL UNIT 24 TO WRITE ITS OUTPUT TO DISK; HENCE, NO
ROUTINE BEING DEBUGGED MAY USE UNIT 24 IF ^^MANTIS\\ IS COMMANDED TO 
WRITE TO DISK.  ^HOWEVER, IF ^^MANTIS\\ WRITES ONLY TO THE ^^TTY\\,
THE USER PROGRAM MAY READ AND WRITE FROM UNIT 24 SAFELY.
.SKIP 2
^IF A USER DIRECTS SOME ^^MANTIS\\ OUTPUT TO DISK, HE LATER CAN REDIRECT
OUTPUT TO HIS ^^TTY\\ BY TYPING ^^USE TTY\\.  ^THE DISK FILE CREATED
IS NOT CLOSED, SO ANY SUBSEQUENT ^^USE\\ FILENAME COMMAND, WHERE THE
FILENAME IS THE SAME AS THAT USED IN THE LAST ^^USE\\ FILENAME COMMAND, WILL APPEND THE NEW OUTPUT TO THE PREVIOUS
OUTPUT.  ^A SUBSEQUENT ^^USE\\ FILENAME COMMAND, WHERE THE FILENAME
CHANGES, WILL CLOSE THE OLD OUTPUT FILE AND BEGIN A NEW ONE.
.SKIP 2
^EXAMPLE:
.SKIP 2
.LEFT MARGIN 30
.INDENT -20
&*^^USE PART\\1##########SENDS ^^MANTIS\\ OUTPUT TO A DISK FILE NAMED
^^PART\\1.^^DAT\\
.BLANK
.INDENT -20
&*^^USE TTY\\############^AFTER THIS COMMAND, ^^MANTIS\\ OUTPUT IS
SENT TO USER'S ^^TTY\\.
.BLANK
.TEST PAGE 3
.INDENT -20
&*^^USE PART1\\##########^ANY ^^MANTIS\\ OUTPUT AFTER THIS COMMAND
IS APPENDED TO INFORMATION ALREADY
STORED IN ^^PART1.DAT\\.
.BLANK
.INDENT -20
&*^^USE PART2\\##########CLOSES FILE ^^PART1.DAT\\ AND
BEGINS SENDING ^^MANTIS\\ OUTPUT TO
^^PART2.DAT\\.
.LEFT MARGIN 5
.SKIP 2
^NOTE THAT A FILE CANNOT BE REOPENED AFTER IT HAS BEEN CLOSED.  ^IF ANOTHER
^&^^USE PART1\\\& COMMAND WERE GIVEN NOW, THE EXISTING ^^PART1.DAT\\
FILE WOULD BE OVER-WRITTEN.
.SKIP 2
.INDEX ^DISK ^FILE ^CONTROL ^COMMANDS
.INDEX ^MAGNETIC ^TAPE ^CONTROL ^COMMANDS
4.2.2  ^MAGNETIC ^TAPE OR ^DISK ^FILE ^CONTROL ^COMMANDS - ^THE NEXT
GROUP OF ^^MANTIS\\ COMMANDS ALLOW A USER TO MANIPULATE DATA FILES
WHICH ARE CURRENTLY ACCESSIBLE IN THE ^^MANTIS\\
COMPILED ^^FORTRAN\\ PROGRAM.  ^THE FILES MUST HAVE BEEN OPENED BY THE
^^FORTRAN\\ OPERATING SYSTEM BEFORE THESE COMMANDS CAN BE USED.  ^SEE 
THE ^&^^DEC\\-10 ^MATHEMATICAL ^LANGUAGES
^HANDBOOK\&, PAGE 5-20, FOR MORE INFORMATION.
.SKIP 2
.LEFT MARGIN 10
.INDEX ^^BACKSPACE\\
.INDEX ^^ENDFILE\\
.INDEX ^^REWIND\\
.INDEX ^^SKIPRECORD\\
.INDEX ^^UNLOAD\\
.INDEX ^^RELEASE\\
^^BACKSPACE\\ _#N
.BLANK
^^ENDFILE\\ _#N
.BLANK
^^REWIND\\ _#N
.BLANK
^^SKIPRECORD\\ _#N
.BLANK
^^UNLOAD\\ _#N
.BLANK
^^RELEASE\\ _#N
.LEFT MARGIN 5
.SKIP 2
^NOTE:  ^THE CHARACTER '_#' MUST PRECEDE THE UNIT NUMBER N IN  THESE
COMMANDS.
.SKIP 2
^THE ABOVE DEVICE CONTROL STATEMENTS CALL THE STANDARD ^^FORTRAN\\
LIBRARY SUBROUTINES.  ^IF ONE OF THE LIBRARY ROUTINES DOESN'T WORK
OR HAS RESTRICTIONS, THESE WILL HOLD FOR THE CORRESPONDING ^^MANTIS\\
COMMAND AS WELL.
.INDEX ^DEVICE ^CONTROL ^STATEMENTS
.SKIP 3
4.3 ^MORE ^ACTION ^COMMANDS
.SKIP 2
.INDEX ^ACTION ^COMMANDS
.INDEX ^SIMPLE ^COMMANDS
^ACTION COMMANDS HAVE BEEN DIVIDED BETWEEN ^CHAPTER 2 AND ^CHAPTER 4
FOR TWO REASONS:  CLARITY AND SYNTAX.  ^CHAPTER 2 COMMANDS ARE CLEARER
IN MEANING AND, EXCEPT FOR ^^EXIT\\, MAY APPEAR IN BOTH SIMPLE COMMANDS
AND COMMAND STRINGS (^SECTION 2.4).  ^CHAPTER 4 COMMANDS, HOWEVER,
MAY APPEAR ONLY IN SIMPLE COMMANDS, AND THEY ARE GENERALLY USED IN
MORE COMPLICATED DEBUGGING.
.SKIP 2
.INDEX ^VALUE ^CHANGE FOR ^ARRAYS
.INDEX ^VALUE ^CHANGE FOR ^SUBROUTINE ^ARGUMENTS (^^ARG\\:N)
.INDEX '*' ^SUBSCRIPT ^NOTATION
.INDEX ^^OUTPUT\\ FOR ^ARRAYS
.INDEX ^^OUTPUT\\ FOR ^SUBROUTINE ^ARGUMENTS
.INDEX ^ARRAYS, ^^OUTPUT\\ AND ^VALUE ^CHANGE
.INDEX ^SUBROUTINE ^ARGUMENTS, ^^OUTPUT\\ AND ^VALUE ^CHANGE
4.3.1  ^^OUTPUT\\ AND ^VALUE ^CHANGE FOR ^ARRAYS AND ^SUBROUTINE ^ARGUMENTS -   ^ARRAYS:  ^AN ENTIRE ARRAY OR ANY COLUMN OR ROW OF AN 
ARRAY MAY BE REFERENCED IN ^^OUTPUT\\ AND ^VALUE ^CHANGE COMMANDS
BY USING THE '*' SUBSCRIPT NOTATION.  '*' STANDS FOR ALL ELEMENTS IN
A GIVEN ROW OR COLUMN.
.INDEX ^SUBSCRIPT ^NOTATION '*'
.SKIP 2
^^OUTPUT\\:
.SKIP 2
.LEFT MARGIN 32
.INDENT -20
&*^^OUTPUT I\\(*)########^OUTPUTS THE VALUES OF ALL ELEMENTS OF THE ONE
DIMENSIONAL ARRAY ^I WHICH IS DEFINED IN THE CURRENT PROGRAM.
.BLANK
.INDENT -20
.INDEX ^^IN OCTAL\\
*^^OUTPUT MAIN/P\\(*,*) ^^IN OCTAL\\#####^OUTPUTS IN OCTAL THE VALUES
OF ALL ELEMENTS IN THE TWO DIMENSIONAL ARRAY ^P IN THE MAIN PROGRAM.
.BLANK
.INDENT -20
.INDEX ^^IN TEXT\\
&*^^OUTPUT JARRAY (1,*) IN TEXT\\####^OUTPUTS AS ^^ASCII\\ CHARACTERS, THE
VALUES FOR THE FIRST ROW OF THE ARRAY ^^JARRAY\\ IN THE CURRENT PROGRAM.
.SKIP 2
.INDENT -25
^VALUE ^CHANGE:
.SKIP 2
.INDENT -20
&*^I(*) = 0###########^EACH ELEMENT OF THE ONE DIMENSIONAL ARRAY ^I IN THE 
CURRENT PROGRAM IS GIVEN A VALUE OF 0.
.BLANK
.INDENT -20
&*^^MAIN/P\\(*,*) = "777#^EACH ELEMENT OF THE TWO DIMENSIONAL ARRAY
^P IN THE ^^MAIN\\ PROGRAM IS GIVEN AN OCTAL VALUE OF 777.
.BLANK
.INDENT -20
&*^^JARRAY (1,*) = 'YES'\\##^EACH ELEMENT IN THE FIRST ROW OF ARRAY
^^JARRAY\\ IN THE CURRENT PROGRAM IS GIVEN THE ALPHANUMERIC VALUE ^^YES\\.
.BLANK
.INDENT -20
&*^^SUBR\\/^K(*,3) = ^T####^EACH ELEMENT IN THE THIRD COLUMN OF THE ARRAY ^K
IN SUBROUTINE ^^SUBR\\ IS GIVEN THE LOGICAL VALUE ^T, 'TRUE'.
.LEFT MARGIN 5
.SKIP 2
.INDEX ^CONSTRAINTS ON ^USE OF '*' ^NOTATION
^CONSTRAINTS ON USE OF '*' NOTATION:
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
1.###^THE '*' NOTATION MAY BE USED ONLY IN ^^OUTPUT\\ AND ^VALUE
^CHANGE COMMANDS.
.SKIP 2
.INDENT -5
2.###^IF AN ARRAY'S SUBSCRIPT HAS A '*', THERE MAY BE NO OTHER VARIABLE 
IN THE VARIABLE LIST OF AN OUTPUT COMMAND.
.SKIP 2
.INDENT 5
&*^^OUTPUT I\\(*)##########IS LEGAL, BUT
.BLANK
.INDENT 5
&*^^OUTPUT I(*), J\\#######IS ILLEGAL.
.SKIP 2
.INDENT -5
3.###^A COMMAND CONTAINING '*' ARRAY SPECIFICATION MAY ^&NOT\& APPEAR
APPENDED TO A BREAK COMMAND IN A COMMAND STRING.  ^IT ^&MUST\& APPEAR
AS AN INDEPENDENT COMMAND.
.SKIP 2
.LEFT MARGIN 50
.INDENT -45
&*^^AT MAIN/60 ; OUTPUT ARRAY (1,*) IN TEXT\\##########IS ILLEGAL, BUT
.SKIP 2
.INDENT -45
&*^^STOP AT MAIN\\/60##################################IS LEGAL.
.BLANK
.INDENT -45
&*^G^O
.BREAK
.INDENT -45
#.
.BREAK
.INDENT -45
#.
.BREAK
.INDENT -45
#.
.BLANK
.INDENT -45
^&^^MAIN\\\&
.BLANK
.INDENT -45
^&<60>\&
.BLANK
.INDENT -45
&*^^OUTPUT ARRAY (1,*) IN TEXT\\
.SKIP 2
.LEFT MARGIN 5
.INDEX ^SUBROUTINE ^ARGUMENTS
^SUBROUTINE ^ARGUMENTS:  ^A VARIABLE MAY BE REFERENCED BY NAME IN
ANY ROUTINE IN WHICH IT APPEARS IN AN ^&EXECUTABLE\& STATEMENT.  ^AS
ALWAYS, THE ROUTINE MUST HAVE BEEN COMPILED WITH ^^MANTIS\\.  ^OPTIONALLY,
^&SCALAR\& SUBROUTINE ARGUMENTS MAY BE REFERENCED BY ARGUMENT SEQUENCE NUMBER
INSTEAD OF BY NAME.  ^FOR INSTANCE, ^^CNT\\ IN THE FOLLOWING STATEMENT,
.SKIP 2
.INDENT 5
^^SUBROUTINE SUBR (ARRAY, Y, N, CNT)\\
.SKIP 2
MAY BE REFERENCED AS ^^ARG\\:4.
.SKIP 2
^THE FOLLOWING CONSTRAINTS EXIST:
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
1.###^THE ARGUMENT SHOULD BE A SCALAR VARIABLE.
.SKIP 2
.INDEX ^^ARG\\:N ^NOTATION
.INDENT -5
2.###^THE ^^ARG\\:N NOTATION CAN APPEAR ONLY IN ^^OUTPUT\\ AND ^VALUE
^CHANGE COMMANDS WHICH ARE APPENDED TO AN ^^ON CALL\\ BREAK COMMAND
IN A COMMAND STRING.
.SKIP 2
.INDENT -5
3.###^THE ^^OUTPUT ARG\\:N COMMAND DEVIATES FROM THE NORMAL PATTERN FOR
^^MANTIS\\ COMMANDS BY ALLOWING THE USER TO OUTPUT AN ARGUMENT
WHICH NEVER APPEARS IN AN EXECUTABLE STATEMENT IN THE SUBPROGRAM.
.INDENT -10
.SKIP 2
.TEST PAGE 10
^EXAMPLES:
.SKIP 2
.LEFT MARGIN 10
&*^^ON CALL SUBR ; OUTPUT ARG:4\\#######ARE LEGAL USES OF THE
.BREAK
.INDENT -5
AND#####################################^^ARG\\:N NOTATION.
.BREAK
&*^^ON CALL SUBR ; ARG:4 = 99.9\\
.SKIP 2
&*^^STOP ON CALL SUBR\\
.BLANK
#.
.BREAK
#.
.BREAK
#.
.BLANK
^&^^SUBR\& CALLED FROM\\ POSITION
.BLANK
&*^^OUTPUT ARG\\:4
.SKIP 2
.INDENT -5
IS ILLEGAL, REPLACE WITH
.SKIP 2
&*^^STOP ON CALL SUBR\\
.BLANK
#.
.BREAK
#.
.BREAK
#.
.BLANK
^&^^SUBR\& CALLED FROM\\ POSITION
.BLANK
&*^^OUTPUT SCALAR\\
.SKIP 2
.LEFT MARGIN 5
.INDEX ^^ARG\\:N ^NOTATION
^THE ^^ARG\\:N NOTATION IS  USEFUL WHEN ONE WISHES TO ^^OUTPUT\\
 A SCALAR ARGUMENT WHICH DOESN'T APPEAR IN AN EXECUTABLE
STATEMENT IN THE SUBROUTINE. ^IT IS A SPECIAL PURPOSE OPTION WHICH
IS NOT NORMALLY USED.
.SKIP 2
.INDEX ^^TYPE\\ ^COMMAND
.INDEX ^OUTPUT-TO-^TELETYPE ^COMMAND (^^TYPE\\)
.INDEX ^RESETS THE ^OUTPUT ^DEVICE TO ^^TTY\\
4.3.2  ^^TYPE\\ ^COMMAND - ^THE ^^TYPE\\ COMMAND IS AN OUTPUT-TO-TELETYPE
COMMAND.  ^WHEREAS THE ^^OUTPUT\\ COMMAND MAY SEND TO EITHER DISK OR ^^TTY, TYPE\\
SENDS ONLY TO THE USER ^^TTY\\.  ^^TYPE\\ RESETS THE OUTPUT DEVICE TO
^^TTY\\ SO THAT UNTIL A [^^USE\\ FILENAME] COMMAND IS ISSUED, ^^MANTIS\\
OUTPUT WILL CONTINUE TO GO TO THE USER TELETYPE.  ^ANY VARIABLE WHICH 
CAN BE OUTPUT WITH THE ^^OUTPUT\\ COMMAND CAN ALSO BE OUTPUT WITH ^^TYPE\\.
.SKIP 2
^THE FORMS OF THE ^^TYPE \\COMMAND ARE:
.SKIP 2
.LEFT MARGIN 10
&*^^TYPE\\ VARIABLE-LIST  
.BLANK
.INDEX ^^IN TEXT\\
.INDEX ^^IN OCTAL\\
&*^^TYPE\\ VARIABLE ^^IN TEXT\\  , VARIABLE ^^IN TEXT\\,##...
.BLANK
&*^^TYPE\\ VARIABLE-LIST ^^IN OCTAL\\  , VARIABLE ^^IN OCTAL\\,##...
.LEFT MARGIN 5
.SKIP 2
^EXAMPLES:  ^IF ^J IS AN INTEGER SCALAR AND ^P, ^Z, AND ^Q2 ARE REAL
ARRAYS:
.SKIP 2
.LEFT MARGIN 5
.INDENT 5
&*^^TYPE J\\  
.BLANK
DISPLAYS ^J AS AN INTEGER ON THE ^^TTY\\.
.BLANK
.INDENT 5
&*^^TYPE P(2,) IN TEXT\\  , ^Q2(6) ^^IN TEXT\\
.BLANK
DISPLAYS ^P(2,) AND ^Q2(6) AS CHARACTER STRINGS ON THE ^^TTY\\.
.LEFT MARGIN 5
.SKIP 2
^IN BOTH EXAMPLES ABOVE, THE VARIABLES ARE ASSUMED TO BE IN THE CURRENT
PROGRAM.  ^THE ERROR MESSAGE '?^^NAME UNDEFINED\\' WOULD BE TYPED
IF THE VARIABLES DO NOT APPEAR IN EXECUTABLE STATEMENTS IN THE CURRENT
PROGRAM.  ^TO OUTPUT A VARIABLE WHICH IS DEFINED ELSEWHERE THAN THE
CURRENT PROGRAM, PRECEDE THE VARIABLE NAME WITH A ROUTINE-NAME:
.SKIP 2
.LEFT MARGIN 5
.INDENT 5
&*^^TYPE SUBR/Z(1) IN OCTAL\\
.BLANK
DISPLAYS THE VALUE OF ^Z(1) IN SUBROUTINE ^^SUBR\\ AS AN OCTAL NUMBER.
.LEFT MARGIN 5
.SKIP 2
^NOTE THAT THE SUBSCRIPT OF AN ARRAY ELEMENT MUST BE A CONSTANT, OR
AN '*', AS FOLLOWS:
.SKIP 2
.INDENT 5
.INDEX ^SUBSCRIPT ^NOTATION '*'
&*^^TYPE Q\\2(*)  
.BLANK
DISPLAYS ON THE ^^TTY\\ THE ENTIRE ARRAY ^Q2 AS REAL FLOATING POINT
NUMBERS.
.SKIP 2
.INDENT 5
&*^^TYPE P(*,1) IN TEXT\\  
.BLANK
DISPLAYS THE FIRST COLUMN OF ARRAY ^P AS ^^ASCII\\ CHARACTERS.
.SKIP 2
.INDEX '*' ^SUBSCRIPT ^NOTATION
.INDEX ^^RESTART\\
.INDEX ^RESTART A ^USER'S ^PROGRAM AT ITS ^ORIGINAL ^ENTRY ^POINT
^NOTE THAT WHEN '*' SUBSCRIPT NOTATION IS USED, ONLY
ONE VARIABLE NAME MAY APPEAR IN THE VARIABLE LIST.
.SKIP 2
4.3.3  ^^RESTART\\ ^COMMAND - ^THE ^^RESTART\\ COMMAND IS USED TO RESTART
A USER'S PROGRAM AT ITS ORIGINAL ENTRY POINT.  ^^RESTART\\ CAUSES THE 
FOLLOWING SEQUENCE OF EVENTS:
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
1.###^IF ^^MANTIS\\ OUTPUT WAS GOING TO A DISK FILE WHEN THE PROGRAM
IS ^^RESTART\\ED, THAT DISK FILE IS CLOSED.  ^OUTPUT WILL GO TO ^^TTY\\
UNTIL ANOTHER ^^USE\\ FILENAME COMMAND IS ISSUED;
.SKIP 2
.INDENT -5
2.###^THE ^^MAIN\\ ROUTINE BECOMES THE CURRENT PROGRAM, SINCE ^^MAIN\\
IS ALWAYS THE FIRST ROUTINE IN A USER PROGRAM TO BE EXECUTED.
.SKIP 2
.INDENT -5
3.###^THE ^^HISTORY\\ TABLE IS CLEARED.
.SKIP 2
.LEFT MARGIN 5
^^RESTART\\ DOES NOT ERASE PREVIOUSLY GIVEN ^^MANTIS\\ COMMANDS (EXCEPT
A ^^USE\\ FILENAME).  ^COMMANDS ISSUED BEFORE ^^RESTART\\ WILL STILL BE
IN EFFECT.
.SKIP 2
^WHEN ^^RESTART\\ING A PROGRAM, THE USER SHOULD:
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
1.###^REPOSITION ANY MAGNETIC TAPES OR DISK FILES BEING USED BEFORE
ISSUING A ^^RESTART\\ COMMAND.  (^SEE ^SECTION 4.2.2)
.SKIP 2
.INDENT -5
2.###^AFTER ISSUING A ^^RESTART\\ COMMAND, REINITIALIZE VARIABLES.  
^VARIABLES ARE ^&NOT\& AUTOMATICALLY RESET.  ^THE USER
SHOULD BE CAREFUL TO RESET COUNTERS AND VARIABLES IN ^^DATA\\ STATEMENTS
USING THE ^VALUE ^CHANGE COMMAND.
.SKIP 2
.INDENT -5
3.###^A ^&^G^O\& COMMAND BEGINS EXECUTION AT THE PROGRAM ENTRY
POINT.  ^A ^&^G^O STATEMENT-REFERENCE\& COMMAND WOULD BEGIN EXECUTION AT
THE CHOSEN POSITION (E.G., ^^GO MAIN\\/30).
.SKIP 2
.LEFT MARGIN 5
^THE ^^RESTART\\ PROCEDURE IS ILLUSTRATED BELOW.
.SKIP 2
^FIRST, REPOSITION MAGNETIC TAPES AND/OR DISK FILES, IF NECESSARY.
(^SEE ^SECTION 4.2.2 FOR COMMANDS TO USE.)
.SKIP 2
.LEFT MARGIN 10
&*^^RESTART\\  
.BLANK
###^&^^INITIALIZE DATA AND GO\\\&##########(^^MANTIS\\ MESSAGE)
.BLANK
&*
.BLANK
##########INITIALIZE NECESSARY VARIABLES
.BLANK
###############(^SEE ^SECTION 2.3.4 AND 4.3.1 FOR THE ^VALUE
.BREAK
############### ^CHANGE COMMANDS.)
.BLANK
&*^G^O##################################EXECUTION BEGINS AT
.BREAK
.INDENT -5
OR########################################ENTRY POINT OR AT
.BREAK
&*^G^O##########STATEMENT-REFERENCE#####STATED EXECUTABLE
.BREAK
#####################################STATEMENT.
.INDEX ^STATEMENT-^REFERENCE
.LEFT MARGIN 5
.SKIP 2
.INDEX ^^RETRY\\ ^COMMAND
.INDEX ^MODIFYING AN ^INCORRECT ^INPUT ^RECORD
.INDEX ^DATA, CORRECTION OF DISK INPUT
.INDEX ^INPUT ^DATA, CORRECTION
.INDEX ^MODIFICATION OF ^BAD ^DATA
4.3.4  ^^RETRY\\ ^COMMAND - ^THE ^^RETRY\\ COMMAND ALLOWS THE PROGRAMMER
TO MODIFY AN INCORRECT DISK OR TAPE INPUT RECORD (EITHER DATA OR A VARIABLE FORMAT), READ IN THE CORRECTED VERSION, AND
CONTINUE EXECUTION.  ^ONLY ONE RECORD MAY BE MODIFIED AND REENTERED
VIA THE ^^RETRY\\ COMMAND.
.SKIP 2
  ^ANOTHER
RESTRICTION IS THAT ^^RETRY\\ CANNOT HANDLE AN ERRONEOUS DISK RECORD WHICH
CROSSES A DISK BLOCK BOUNDARY.  ^DATA FILES CREATED BY A ^^FORTRAN \\PROGRAM WILL NEVER HAVE RECORDS SPANNED ACROSS
BLOCK BOUNDARIES, BUT DATA FILES CREATED IN OTHER WAYS MAY.  ^SUCH
FILES CAN BE BLOCKED PROPERLY USING THE ^^PIP /A\\ SWITCH.
.SKIP 2
.LEFT MARGIN 10
&.^^R PIP\\
.BLANK
&*^^FILE.DAT/A__FILE.DAT\\
.BLANK
&*_^^C
.BLANK
&.^^EX PROG.F4/MAN\\####################TO EXECUTE THE PROGRAM
.BREAK
###################################WHICH READS ^^FILE.DAT.
.SKIP 2
.INDENT -5
^THE ^^RETRY\\ COMMAND IS
.BLANK
&*^^RETRY\\
.LEFT MARGIN 5
.SKIP 2
^OF COURSE, IT CAN ONLY BE USED ON ^^READ\\ ERRORS OCCURRING IN 
ROUTINES COMPILED WITH ^^MANTIS\\.
.SKIP 2
.INDEX ^CORRECTING ^INPUT ^DATA
^EXAMPLE 1:  ^CORRECTING INPUT DATA.
.LEFT MARGIN 15
.INDENT -5
.SKIP 2
^CONSIDER THE FOLLOWING ^^FORTRAN \\PROGRAM SEGMENT.
.SKIP 2
^^DIMENSION INT\\(5)
.BREAK
^^READ(1,30) INT\\
.BREAK
.INDENT -5
30###^^FORMAT\\ (5I3)
.LEFT MARGIN 5
.INDEX ^ILLEGAL ^CHARACTER IN ^DATA, CORRECTION
.SKIP 2
^IF ONE OF THE ENTRIES IN THE INPUT DISK FILE ^^FOR01.DAT\\
CONTAINS AN ILLEGAL CHARACTER,  E.G., IF THE DATA LOOKS LIKE
.BLANK
.INDENT 5
1##2#3.##4##5
.SKIP 2
THEN AN ERROR MESSAGE WILL OCCUR.  ^WHEN USING ^^MANTIS,\\ THE EXECUTION
WOULD LOOK LIKE THIS:
.LEFT MARGIN 10
.SKIP 2
&*^G^O  
.BLANK
?^&^^ILLEGAL CHARACTER., IN INPUT STRING\\\&
.BLANK
(5^I3)
.BLANK
^&^^LAST FORTRAN I-0 AT USER LOC 002110\\\&
.BLANK
^&^^ERROR AT MAIN\\/+1\&
.BLANK
^&^^IF FORMAT REQUIRES ONLY ONE LINE OF DATA YOU MAY RETRY READ\\\&
.BLANK
&*^^RETRY\\  
.INDEX ^ILLEGAL ^CHARACTER IN ^INPUT
.BLANK
##^&1##2#3.##4##5\&
.BREAK
########&_^
.BLANK
^&^^TYPE IN NEW LINE ENDING WITH TWO RETURNS\\\&
.BLANK
##1##2##3##4##5###############^&^TWO\& CARRIAGE RETURNS
.BREAK
(^EXECUTION CONTINUES)#########MUST TERMINATE ^^RETRY\\
.BREAK
##############################ENTRY CORRECTION.
.LEFT MARGIN 5
.SKIP 2
.INDEX ^CORRECTING A ^VARIABLE ^FORMAT
.INDEX ^ILLEGAL ^VARIABLE ^FORMAT, CORRECTION
.INDEX ^VARIABLE ^FORMAT, CORRECTION
^EXAMPLE 2: ^CORRECTING A VARIABLE FORMAT.
.SKIP 2
.INDEX ^VALUE ^CHANGE ^COMMAND
^IF A VARIABLE FORMAT IS ERRONEOUS, IT MAY BE CORRECTED WITH A
^^MANTIS\\ ^VALUE ^CHANGE COMMAND.  ^THEN ^^RETRY\\ IS USED TO READ
IN DATA WITH THE CORRECTED FORMAT. ^THERE IS NO RESTRICTION ON HOW MANY DATA RECORDS MAY BE READ WITH A CORRECTED FORMAT.
.SKIP 2
^CONSIDER THE FOLLOWING ^^FORTRAN\\ PROGRAM SEGMENT.
.LEFT MARGIN 10
.SKIP 2
^^DIMENSION FMT\\(2)
.BREAK
^^ACCEPT 5, FMT\\
.BREAK
.INDENT -3
5##^^FORMAT(2A5)
.BREAK
^^READ(1,FMT) MIN\\
.SKIP 2
.INDENT -5
^IF ^^FMT\\ IS ENTERED INCORRECTLY, THE CORRECTION IS AS FOLLOWS:
.TEST PAGE 22
.SKIP 2
&*^G^O  
.BLANK
(10^X,^J4)#####################(^INPUT ^^FMT\\ ARRAY.)
.BLANK
^&^^ILLEGAL CHARACTER J, IN FORMAT\\\&
.BLANK
^&(10^X,^J4)\&
.BLANK
^&^^LAST FORTRAN I-0 AT USER LOC 002107\\\&
.BLANK
^&^^ERROR AT MAIN\\/+1\&
.BLANK
^^^&IF FORMAT REQUIRES ONLY ONE LINE OF DATA YOU MAY RETRY READ\\\&
.BLANK
.NOFILL
.TAB STOPS 40
&*^^FMT\\(2) = '^I4)'  	^^FMT\\ IS CORRECTED.
.BLANK
&*^^OUTPUT FMT(*) IN TEXT\\  
.BLANK
^&(10^X,^I4)\&
.BLANK
.FILL
.LEFT MARGIN 40
.INDENT -30
&*^^RETRY\\########################^EXECUTION CONTINUES.  ^THE 
CORRECTED ^^FMT\\ IS USED IN THE ^^READ\\ STATEMENT.
.LEFT MARGIN 5
.SKIP 2
^NOTE: ^IF THE BAD DATA WAS TYPED IN, IT MAY BE CORRECTED BY USING THE
^G^O COMMAND TO EXECUTE THE INPUT STMT AGAIN AND RE-TYPING THE DATA.
.TITLE ^^MANTIS\\ ^CHAPTER 5
.PAGE
.SKIP 3
.INDEX ^RECOVERY ^FROM ^COMMON ^^FORTRAN\\ ^ERRORS
.INDEX ^^FORTRAN \\^ERRORS, RECOVERY FROM
.INDEX ^^MANTIS\\ ^USEFULNESS
5.0 ^^MANTIS RECOVERY FROM COMMON FORTRAN ERRORS\\
.SKIP 2
^MANY ^^FORTRAN\\ ERRORS CAN BE LOCATED QUICKLY USING THE ^^MANTIS\\
DEBUGGER.  ^^MANTIS\\ TRAPS SEVERAL ERRORS WHICH WOULD OTHERWISE TERMINATE
EXECUTION, TELLING THE USER WHERE THE ERROR OCCURRED IN THE ^^FORTRAN\\
PROGRAM AND GIVING HIM A CHANCE TO EXAMINE VARIABLES, CHECK THE SEQUENCE
OF EXECUTION (^^HISTORY\\ AND ^^TRACE\\ COMMANDS), AND EVEN RE-EXECUTE
ALL OR PART OF THE PROGRAM.  ^INFINITE LOOPS ARE ALSO EASIER TO
LOCATE WITH ^^MANTIS\\.
.SKIP 2
^THE ^^PDP\\-10 MONITOR GENERATES A NUMBER OF ERROR MESSAGES WHICH,
WHILE VALUABLE TO THE MACHINE LANGUAGE PROGRAMMER, DO NOT GIVE THE
^^FORTRAN\\ PROGRAMMER MUCH INSIGHT INTO THE NATURE OF THE PROBLEM
ENCOUNTERED. E.G.,
.SKIP 2
.LEFT MARGIN 10
?^^ILL MEM REF AT USER\\ ADDR
.BLANK
?^^ILLEGAL UUO AT USER\\ ADDR
.BLANK
?^^ILL INST AT USER\\ ADDR
.LEFT MARGIN 5
.SKIP 2
^OTHER MESSAGES ARE CLEAR IN MEANING, BUT DO NOT TELL THE USER WHERE THE
ERROR OCCURRED IN THE ^^FORTRAN\\ PROGRAM.  ^FOR EXAMPLE:
.SKIP 2
.LEFT MARGIN 10
^^FLOATING UNDERFLOW\\#######^P^C = ADDR
.BLANK
^^INTEGER OVERFLOW#########\\^P^C = ADDR
.BLANK
^^INTEGER DIVIDE CHECK\\#####^P^C = ADDR
.LEFT MARGIN 5
.SKIP 2
^WITHOUT ^^MANTIS\\, ^^FORTRAN\\ EXECUTION ERRORS TERMINATE EXECUTION AND
RETURN CONTROL TO THE MONITOR; HOWEVER, ^&WITH\& ^^MANTIS\\, MANY OF
THESE ERRORS RETURN CONTROL TO ^^MANTIS\\ INSTEAD OF THE MONITOR.
^^MANTIS\\ TYPES THE LOCATION OF THE LAST ^^FORTRAN\\ STATEMENT EXECUTED
(IF IT WAS IN A ROUTINE COMPILED WITH ^^MANTIS\\) AND PROMPTS '*' FOR MORE COMMANDS.  ^THE USER MAY THEN EXAMINE CRITICAL
VARIABLES AND THE ^^HISTORY\\ TABLE TO DETERMINE THE ERROR.
.SKIP 2
.TEST PAGE 7
.INDEX ^DIVIDE ^CHECK ^ERRORS
.INDEX ^OVERFLOW ^ERRORS
.INDEX ^UNDERFLOW ^ERRORS
.INDEX ^ERRORS, RECOVERY FROM
5.1 ^OVERFLOW, ^UNDERFLOW, AND ^DIVIDE ^CHECK ^ERRORS
.TEST PAGE 15
.SKIP 2
^THERE ARE PRESENTLY EIGHT ERROR MESSAGES OF THIS TYPE.(1)
.FOOTNOTE 5
.LEFT MARGIN 5
.SKIP 1
-------------------
.BREAK
(1) ^SEE ^^DEC\\SYSTEM-10 ^MATHEMATICAL ^LANGUAGE ^HANDBOOK, ^^FORTRAN\\,
PAGES 11-10, 11-11 FOR MORE INFORMATION ABOUT THE ERRORS WHICH
CAUSE THESE MESSAGES.
!

.SKIP 2
.LEFT MARGIN 10
^^INTEGER OVERFLOW\\#########^P^C = ADDR
.BLANK
^^INTEGER DIVIDE CHECK#####\\^P^C = ADDR
.BLANK
^^FLOATING OVERFLOW\\########^P^C = ADDR
.BLANK
^^FLOATING UNDERFLOW\\#######^P^C = ADDR
.BLANK
^^FLOATING DIVIDE CHECK\\####^P^C = ADDR
.BLANK
^^ATTEMPT TO TAKE SQRT OF NEGATIVE ARG\\
.BLANK
^^ACOS OF ARG>1.0 IN MAGNITUDE\\
.BLANK
^^ASIN OF ARG>1.0 IN MAGNITUDE\\
.SKIP 2
.LEFT MARGIN 5
^WITHOUT ^^MANTIS\\, ONLY THE FIRST TWO OCCURRENCES OF ANY GIVEN ERROR
CAUSE AN ERROR MESSAGE.  ^WITH ^^MANTIS\\, ^&EACH\& ERROR CAUSES AN ERROR
MESSAGE TO BE OUTPUT.  (^A CALL IN THE USER'S PROGRAM TO THE LIBRARY 
SUBROUTINE ^^ERRSET\\ CAN BE USED TO LIMIT THE NUMBER OF MESSAGES
OUTPUT FOR EACH ERROR TYPE WITH ^^MANTIS\\.)
.SKIP 2
.INDEX ^DEBUGGING AN ^ARITHMETIC ^ERROR
.INDEX ^ARITHMETIC ^ERROR ^DEBUGGING
^EXAMPLE: ^DEBUGGING AN ARITHMETIC ERROR.
.SKIP 2
^THE INSTRUCTIONS
.SKIP 2
.LEFT MARGIN 10
^Y = 10.0
.BREAK
^X = ^Y/^A
.BREAK
^^STOP\\
.BREAK
^^END\\
.SKIP 2
.LEFT MARGIN 5
GENERATE AN ERROR MESSAGE DURING EXECUTION.
.SKIP 3
.LEFT MARGIN 10
&*^G^O
.BLANK
^&^^FLOATING DIVIDE CHECK PC\\ = 002110\&
.LEFT MARGIN 30
.BLANK
.INDENT -20
^&^^ERROR AT MAIN/+2\\\&####^^MANTIS\\ LOCATES THE ERROR AS BEING IN THE SECOND
EXECUTABLE STATEMENT (^X = ^Y/^A).
.BLANK
.INDENT -20
&*^^OUTPUT Y,A\\#########^USER COMMANDS ^^MANTIS\\ TO OUTPUT ^Y AND ^A.
.BLANK
.LEFT MARGIN 10
##^&10.00000\&
.BLANK
###^&0.0000000\&
.LEFT MARGIN 5
.SKIP 2
^HOPEFULLY, THE USER WILL BE ABLE TO CORRECT HIS PROGRAM ONCE HE
KNOWS WHICH STATEMENT CAUSES THE ERROR AND WHAT VALUES THE VARIABLE
HAD.  ^IN THIS CASE, ^A WAS STILL ZERO BECAUSE IT WAS NEVER INITIALIZED
IN THE PROGRAM.  ^IF THE USER TYPES
.SKIP 2
.LEFT MARGIN 10
&*^A = 2.0######################TO CHANGE THE VALUE OF ^A
.BLANK
&*^^RESTART\\######################TO RESTART EXECUTION
.BREAK
##############################AT THE ENTRY POINT, AND
.BLANK
^&^^INITIALIZE DATA AND GO\\\&
.BLANK
&*^G^O###########################TO RE-EXECUTE,
.SKIP 2
.LEFT MARGIN 5
HIS PROGRAM WILL NOW RUN WITHOUT ERROR.
.SKIP 2
^HAVING DETERMINED THE ERROR WAS CAUSED BY NOT INITIALIZING ^A, THE
USER NOW CAN EDIT HIS PROGRAM TO INCLUDE INITIALIZATION OF VARIABLE
^A.  ^NOTE THAT ^^MANTIS\\ DOES ^&NOT\& MODIFY SOURCE PROGRAM FILES.
.SKIP 2
.INDEX ^ILLEGAL ^MEMORY ^REFERENCE ^ERROR
5.2 ^ILLEGAL ^MEMORY ^REFERENCE ^ERROR
.SKIP 2
^THE MESSAGE ?^^ILL MEM REF AT USER\\ XXXXXX IS FREQUENTLY CAUSED BY
REFERENCING AN ARRAY ELEMENT WITH SUBSCRIPTS WHOSE VALUES ARE
BEYOND THE RANGE DIMENSIONED FOR THE ARRAY.  ^FOR INSTANCE,
.SKIP 2
.LEFT MARGIN 10
^^DIMENSION ARR\\(10)
.BREAK
^I = 50
.BREAK
^^TEST = ARR(I)
.BREAK
STOP
.BREAK
END\\
.SKIP 2
.LEFT MARGIN 5
GENERATES AN ^^ILL MEM REF\\ ERROR WHEN AN ATTEMPT IS MADE TO REFERENCE
THE NON-EXISTENT ^^ARR\\(50).  ^THE PROBLEM IS THAT THE SUBSCRIPT ^I
IS GREATER THAN THE DIMENSIONED SIZE OF ^^ARR\\.
.SKIP 2
.INDEX ^ARRAY ^SUBSCRIPT ^ERRORS
.INDEX ^^SUBCHECK\\ ^COMMAND
.INDEX ^CHECK ^ARRAY ^SUBSCRIPTS
.INDEX ^SUBSCRIPT ^CHECKING, ARRAYS
.INDEX ^ERRORS, ARRAY SUBSCRIPT
^THE SIMPLEST WAY TO CHECK FOR ARRAY SUBSCRIPT ERRORS IS TO USE THE 
^^MANTIS SUBCHECK\\ FEATURE.  ^TO DEBUG  THE ABOVE PROGRAM STORED
IN THE FILE ^^PROG2.F4\\,
.SKIP 2
.LEFT MARGIN 10
#.^^DEBUG PROG2.F4\\
.BLANK
^&^^FORTRAN:PROG:2.F4\\\&
.BLANK
^&^^MANTIS V3\\\&
.BLANK
^&^^CURRENT PROGRAM IS MAIN\\\&
.BLANK
^&^^READY\\\&
.BLANK
&*^^SUBCHECK MAIN/ARR\\############SETS UP SUBSCRIPT CHECK FOR
.BREAK
##############################^^ARR\\ IN THE MAIN (ONLY)
.BREAK
^&^^SETUP\\\&#########################PROGRAM.
.BLANK
&*^G^O###########################BEGINS EXECUTION OF PROGRAM.
.BLANK
^&^^REFERENCE TO ARR ILLEGAL AT MAIN/+2\\\&
.BLANK
&*.############################^^MANTIS\\ LOCATES THE ERRONEOUS
.BREAK
#.############################SUBSCRIPT REFERENCE.
.BREAK
#.
.SKIP 2
.LEFT MARGIN 5
.INDEX ^ILLEGAL ^ARRAY ^REFERENCE
^ONCE THE LOCATION OF THE ILLEGAL ARRAY REFERENCE IS KNOWN, THE USER
CAN CHECK THE SOURCE PROGRAM TO FIND THE STATEMENT AND FURTHER CHECK THE
VARIABLE SUBSCRIPT(S) USED.  ^IF THERE WERE MORE THAN ONE SUBSCRIPTED
ARRAY IN THE STATEMENT FLAGGED BY ^^MANTIS\\, THE USER MIGHT WISH TO
OUTPUT EACH SUBSCRIPT TO DETERMINE WHICH ONE (OR ONES) ARE OUT OF BOUNDS.
.SKIP 2
.INDEX ^INPUT ^DATA, CORRECTION
.INDEX ^ILLEGAL ^CHARACTER IN ^INPUT
5.3 ^ILLEGAL ^CHARACTER IN ^INPUT
.SKIP 2
^AN ILLEGAL CHARACTER IS FLAGGED IN DATA WHEN A NON-DIGIT APPEARS IN AN
INTEGER AND WHEN A CHARACTER NOT FROM THE SET (0-9,+, -, ., ^D OR ^E)
APPEARS IN A FLOATING OR FIXED POINT NUMBER.  ^THE ERROR MAY ALSO 
OCCUR WHEN A PROGRAM ATTEMPTS TO USE A VARIABLE FORMAT WHICH WAS INPUT
INCORRECTLY. 
.INDEX ^^RETRY\\ ^COMMAND
.INDEX ^MODIFICATION OF ^BAD ^DATA
.SKIP 2
^IN EITHER CASE, AN ILLEGAL CHARACTER CAN USUALLY BE CORRECTED WITH THE
^^MANTIS RETRY\\ COMMAND.  ^^RETRY\\ DISPLAYS AND ALLOWS MODIFICATION
OF BAD DATA.  ^IF A VARIABLE FORMAT IS SYNTACTICALLY INCORRECT, THE USER
MAY MODIFY IT USING THE ^VALUE ^CHANGE ^COMMAND AND THEN USE ^^RETRY\\ TO
'REREAD' THE DATA WHICH USED THAT VARIABLE FORMAT.  ^SEE ^SECTION 4.3.4
FOR DESCRIPTION AND CONSTRAINTS ON THE ^^RETRY\\ COMMAND.  ^EXAMPLE
1, ^SECTION 4.3.4 DEMONSTRATES CORRECTION OF DATA; ^EXAMPLE 2, ^SECTION
4.3.4 DEMONSTRATES CORRECTION OF A BAD VARIABLE FORMAT.  
.SKIP 2
^NOTE:  ^^RETRY\\ CORRECTIONS ARE MADE IN THE ^^FORTRAN\\ INPUT BUFFER;
THEY DO ^&NOT\& CORRECT THE ACTUAL DATA ON AN INPUT DEVICE (DISK,
MAGNETIC TAPE, ETC.).
.SKIP 2
.INDEX ^INFINITE ^LOOPS
5.4 ^INFINITE ^LOOPS
.SKIP 2
^ANOTHER PROGRAMMING ERROR ENCOUNTERED IS THE INFINITE LOOP.  ^THIS 
ERROR CAN BE HARD TO LOCATE BECAUSE THERE IS NO ^^FORTRAN\\ ERROR
MESSAGE FOR IT.  ^ONE CAN SUSPECT AN INFINITE LOOP WHEN 1) THE SAME OUTPUT
IS TYPED OVER AND OVER ON THE USER TELETYPE OR DATA FILE; 2)  
NOTHING IS OUTPUT TO THE TELETYPE AND SOMETHING SHOULD HAVE BEEN.  ^A
WAYWARD LOOP MAY ALSO EVENTUALLY CAUSE A SUBSCRIPT TO GO OUT OF RANGE
(^^ILL MEM REF\\) OR CAUSE A VARIABLE VALUE TO OVERFLOW OR UNDERFLOW.
.SKIP 2
^THERE ARE FOUR ^^MANTIS\\ FEATURES WHICH HELP A PROGRAMMER FIND AN INFINITE
LOOP ONCE HE SUSPECTS ONE EXISTS.  ^THESE ARE ^^TRACE, HISTORY, STOP\\,
AND THE ^^MANTIS\\ RESPONSE TO A MONITOR ^^REENTER\\ COMMAND.
^TWO EXAMPLES ARE PROVIDED.
.SKIP 2
.INDEX ^DEBUGGING AN ^INFINITE ^LOOP
^EXAMPLE 1:  ^DEBUGGING A LOOP WITH ^^TRACE, HISTORY,\\ AND ^^REENTER\\.
.SKIP 2
^THIS ^^FORTRAN \\PROGRAM CONTAINS AN INFINITE LOOP.
.SKIP 2
.LEFT MARGIN 15
^K=1
.BREAK
.INDENT -5
10###^I=0
.BREAK
^^CALL DOIT (K)\\
.BREAK
^^IF (I .GE. 3) STOP\\
.BREAK
^I=^I+1
.BREAK
^^GO TO\\ 10
.BREAK
^^STOP\\
.BREAK
^^END\\
.SKIP 2
.LEFT MARGIN 10
.INDENT -5
^IT CAN BE DEBUGGED AS FOLLOWS:
.INDEX ^^TRACE\\ ^COMMAND
.SKIP 2
.LEFT MARGIN 40
.INDENT -30
&*^^TRACE\\  #######################^SETS UP ^^TRACE\\ING FOR ^^GO TO\\ AND
^I^F STATEMENTS, IN ADDITION TO ^^CALL\\S, ^^RETURN\\S AND ^^MANTIS
GO\\ COMMANDS WHICH ARE ALWAYS TRACED.
.BLANK
.INDENT -30
&*^G^O  #
.BLANK
.INDENT -30
#_^^C_^^C#########################RETURNS CONTROL TO THE MONITOR.
.BLANK
.INDEX ^^REENTER\\
.INDENT -30
&.^^REE\\##########################^REENTER PROGRAM EXECUTION.
.BREAK
.INDENT -30
^&^^INTERRUPTED AT MAIN/10+1\\\&####^^MANTIS\\
TAKES CONTROL.  ^THE LOCATION GIVEN IS SOMEWHERE WITHIN THE LOOP.
.BLANK
.LEFT MARGIN 10
&*^^OUTPUT I\\  #
.BLANK
#######&0
.BLANK
.INDEX ^^HISTORY\\ ^COMMAND
&*^^HISTORY\\  #####################^OUTPUTS THE ^^HISTORY\\ TABLE.
.BLANK
^&^^GO TO MAIN\\/10\&
.BLANK
^&^^RETURNED TO MAIN\\/10+2\&
.BLANK
^&^^DOIT CALLED\\\&
.BLANK
^&^^GO TO MAIN\\/10\&
.BLANK
^&^^RETURNED TO MAIN\\/10+2\&
.BLANK
^&^^DOIT CALLED\\\&
.BLANK
^&^^GO TO MAIN\\/10\&
.BLANK
^&^^RETURNED TO MAIN\\/10+2\&
.BLANK
^&^^DOIT CALLED\\\&
.BLANK
^&^^GO TO MAIN\\/10\&
.BLANK
^&^^RETURNED TO MAIN\\/10+2\&
.BLANK
^&^^DOIT CALLED\\\&
.BLANK
&*^^EXIT\\#########################^TERMINATES THE ERRONEOUS
.BREAK
.INDENT 30
 EXECUTION.
.BLANK
&.
.LEFT MARGIN 5
.SKIP 2
^THE LOCATION GIVEN IN THE '^^INTERRUPTED AT\\' MESSAGE GIVES THE
GENERAL AREA OF THE LOOP, AND ITS NATURE CAN BE  DETERMINED MORE PRECISELY
BY EXAMINING THE HISTORY TABLE, WHICH SHOWS THE PATH OF EXECUTION IN
THE RECENT PAST.  ^IN THIS EXAMPLE, THE HISTORY TABLE SHOW THAT ^^DOIT\\
WAS CALLED MORE THAN THE EXPECTED THREE TIMES.  ^CLOSER EXAMINATION
SHOWS THAT THE INDEX ^I SHOULD NOT BE RESET TO 0 EACH TIME THROUGH
THE LOOP.  ^NOW THE PROGRAMMER CAN EXIT EXECUTION AND CORRECT HIS
PROGRAM LOGIC SO THAT ^I IS NOT RESET TO 0 EACH TIME THROUGH THE LOOP.
.SKIP 3
^EXAMPLE 2: ^DEBUGGING WITH ^^REENTER.\\
.SKIP 2
^IF ONE HALTS AND REENTERS WHEN INPUT IS PENDING FROM THE TELETYPE, THE
INPUT MUST BE ENTERED IMMEDIATELY AFTER ^^REENTER\\ING.
.SKIP 2
^CONSIDER THE PROGRAM SEGMENT:
.LEFT MARGIN 15
.SKIP 2
^^WRITE\\ (5,10)
.BREAK
.INDENT -5
10###^^FORMAT ('\\ ^^FORCE\\=',$)
.BREAK
^^READ (5,20) FORCE\\
.BREAK
.INDENT -5
20###^^FORMAT (F)\\
.SKIP 2
.LEFT MARGIN 10
.INDENT -5
^DEBUG AS FOLLOWS:
.SKIP 2
&*^G^O ##########################BEGIN EXECUTION.
.BLANK
^&^^FORCE\\\& = _^^C####################RETURN CONTROL TO THE MONITOR.
.BLANK
&.^^REE\\ #########################REENTER EXECUTION.
.BLANK
25.4 @########################ENTER EXPECTED ^^TTY\\ INPUT.
.BLANK
.LEFT MARGIN 40
.INDENT -30
^&^^INTERRUPTED#AT#MAIN\\/+2\&########^^MANTIS \\TAKES CONTROL AND OUTPUTS
THE LOCATION WHERE EXECUTION REENTERED.
.BLANK
.INDENT -30
&*
.SKIP 2
.LEFT MARGIN 5
^IF ^^REENTER\\ RETURNS TO A POINT IN EXECUTION WHICH IS NOT IN A
ROUTINE COMPILED WITH ^^MANTIS\\,
THE MESSAGE
.SKIP 2
.INDENT 5
^&^^INTERRUPTED AT\\ ?\&
.SKIP 2
IS RETURNED.  ^THE USER CAN STILL BREAK OUT OF THE LOOP AND RESUME EXECUTION
AT SOME STATEMENT EITHER BEFORE OR AFTER THE LOOP BY TYPING A
.SKIP 2
.INDENT 5
&*^G^O STATEMENT-REFERENCE
.SKIP 2
COMMAND.
.SKIP 2
.INDEX ^DEBUGGING AN ^INFINITE ^LOOP
.INDEX ^INFINITE ^LOOPS
^EXAMPLE 3:  ^DEBUGGING AN ^INFINITE ^LOOP WITH ^^TRACE, HISTORY,\\ AND
^^STOP\\.
.SKIP 2
.INDEX ^^STOP\\ ^COMMAND
^IF BREAKPOINT(S) HAVE BEEN SET WITH ^^AT, ON CALL, BEFORE RETURN
FROM\\, OR ^O^N COMMANDS, A ^^STOP\\ COMMAND MAY BE TYPED ANY TIME AND 
^^MANTIS\\ WILL STOP AT THE NEXT BREAKPOINT.
.SKIP 2
^AN ALTERNATE WAY TO DEBUG THE PROGRAM SEGMENT IN ^EXAMPLE 1 WOULD BE:
.SKIP 2
.LEFT MARGIN 40
.INDENT -30
&*^A^T 10#######################SETS A BREAKPOINT AT THE
EXECUTABLE STATEMENT LABELED 10.
.LEFT MARGIN 10
.BLANK
&*^^TRACE\\########################SET UP ^^TRACE\\ FUNCTION.
.BLANK
&*^G^O###########################BEGIN EXECUTION.
.BLANK
#^&<10>\&
.BREAK
#^&<10>\&#########################^^MANTIS\\ OUTPUTS ^&<10>\& EACH TIME
.BREAK
#^&<10>\&#########################EXECUTION PASSES TO STATEMENT
.BREAK
.INDENT 30
 10.
.BLANK
#^&<10>\&
.BLANK
.INDEX ^HALT ^EXECUTION
#^^STOP\\#########################^USER TYPES ^^STOP\\ TO HALT THE
.BREAK
.INDENT 30
 LOOP.
.BLANK
#^&<10>\&
.BLANK
&*^^OUTPUT I\\#####################^^MANTIS\\ GAINS CONTROL AND
.BREAK
.INDENT 30
 PROMPTS '*'.
.BREAK
########&0#####################^USER ENTERS AN ^^OUTPUT\\ COMMAND.
.BLANK
&*^^HISTORY\\
.SKIP 2
.LEFT MARGIN 5
.INDEX ^INTERRUPTING ^EXECUTION
^INTERRUPTING EXECUTION USING ^^REENTER\\ OR ^^STOP\\ MAY ALSO BE
HELPFUL WHEN EXECUTION UNEXPECTEDLY GETS OUT OF CONTROL, AS WHEN A
^G^O COMMAND IS GIVEN WITHOUT FIRST SETTING BREAKPOINTS OR WHEN AN UNEXPECTED
BRANCH CAUSES EXECUTION TO ENTER A PORTION OF THE PROGRAM IN WHICH NO
BREAKPOINTS HAVE BEEN SET.
.TITLE ^^MANTIS\\ ^APPENDIX ^A
.PAGE
.SKIP 3
.INDEX ^^MANTIS\\ ^COMMAND ^SUMMARY
.INDEX ^TELETYPE ^CRIB ^SHEET
.INDEX ^KEYWORDS, ^^MANTIS\\
^A.0 ^^MANTIS COMMAND SUMMARY AND TELETYPE CRIB SHEET\\
.SKIP 2
.CENTER
^COMMAND ^TYPES
.SKIP 2
.NOFILL
.LEFT MARGIN 0
.TAB STOPS 5 17 28 44 58
	^&^BREAK  	^KILL	  ^ACTION	^MONITORING	   ^I/^O\&
.SKIP 2
	^^AT	KILL	GO	HISTORY	USE\\
	^^ON CALL		STOP	TRACE	UNLOAD\\
	^^BEFORE		OUTPUT	SUBCHECK	REWIND\\
	 ^^RETURN		\\^VALUE ^CHANGE	^STATEMENT	^^ENDFILE\\
	  ^^FROM\\		^^EXIT\\	 ^LOCATION	^^BACKSPACE\\
			^^TYPE\\	  ^QUERY	^^SKIPRECORD\\
	^^ON		RESTART		RELEASE\\
			^^RETRY\\
.FILL
.PAGE
.SKIP 2
.LEFT MARGIN 5
.INDEX ^COMMAND ^SYNTAX
^A.1  ^COMMAND ^SYNTAX
.SKIP 2
.LEFT MARGIN 10
.INDENT -5
^&^SIMPLE ^^MANTIS\\ ^COMMANDS\&
.SKIP 2
&*##^BREAK  ^COMMAND
.BREAK
&*##^^KILL\\  ^COMMAND
.BREAK
&*##^ACTION  ^COMMAND
.BREAK
&*##^MONITORING  ^COMMAND
.BREAK
&*##^INPUT/^OUTPUT  ^COMMAND
.SKIP 2
.INDENT -5
.INDEX ^SIMPLE ^COMMANDS
^SIMPLE COMMANDS ARE EXERCISED AS SOON AS THEY ARE TYPED.
.SKIP 2
.INDENT -5
.INDEX ^COMMAND ^STRINGS
^&^^MANTIS ^COMMAND ^STRINGS\&
.SKIP 2
.LEFT MARGIN 8
&*^BREAK ^COMMAND ; ^ACTION/^^KILL\\ ^COMMAND ; ^ACTION/^^KILL\\ ^COMMAND...
.SKIP 2
.LEFT MARGIN 5
^THERE MAY BE AS MANY ACTION/^^KILL\\ COMMANDS AS DESIRED APPENDED TO THE
INITIAL BREAK COMMAND.
.SKIP 2
^THE ACTION COMMANDS ALLOWED IN A COMMAND STRING ARE ^^GO, STOP, OUTPUT,
\\AND ^VALUE ^CHANGE.
.SKIP 2
^APPENDED COMMANDS ARE STORED UNTIL THE BREAKPOINT IS REACHED DURING EXECUTION;
THEY ARE NOT IMMEDIATELY EXECUTED AS ARE SIMPLE COMMANDS.
.SKIP 2
.INDEX ^REFERENCING A ^^FORTRAN\\ ^STATEMENT
.INDEX ^FORMAT FOR A ^STATEMENT ^REFERENCE
^A.2  ^REFERENCING ^^FORTRAN\\ ^STATEMENTS AND ^VARIABLES
.SKIP 2
^&^^FORTRAN \\ ^STATEMENT ^REFERENCE\&
.SKIP 2
.INDENT 5
ROUTINE-NAME/EXECUTABLE STATEMENT LABEL &+ N
.SKIP 2
IDENTIFIES THE LOCATION OF AN EXECUTABLE STATEMENT
IN THE MAIN ROUTINE OR A SUBROUTINE WHICH HAS BEEN COMPILED WITH
^^MANTIS\\.
.SKIP 2
^EXAMPLES:
.LEFT MARGIN 10
.SKIP 2
#####10###STATEMENT NUMBER 10 IN THE CURRENT PROGRAM.
.BLANK
^^SUBR\\/20###STATEMENT NUMBER 20 IN SUBROUTINE ^^SUBR\\.
.BLANK
^^SUBR\\/+1###FIRST ^&EXECUTABLE\& STATEMENT IN SUBROUTINE ^^SUBR\\.
.BLANK
.LEFT MARGIN 20
.INDENT -10
75&+ 5#####THE FIFTH ^&EXECUTABLE\& STATEMENT BEFORE (-) OR AFTER (+)
THE STATEMENT LABELED 75.
.LEFT MARGIN 5
.SKIP 2
.INDEX ^VARIABLES, REFERENCING OF
.INDEX ^REFERENCING A ^VARIABLE
^&^VARIABLE REFERENCES\&
.SKIP 2
.INDENT 5
ROUTINE-NAME/VARIABLE
.SKIP 2
IDENTIFIES A VARIABLE TO BE REFERENCED IN A ROUTINE COMPILED WITH ^^MANTIS\\.
.SKIP 2
^EXAMPLES:
.SKIP 2
.LEFT MARGIN 10
^^VALUE#########\\THE VARIABLE NAMED ^^VALUE\\ IN THE CURRENT
##############PROGRAM.
.BLANK
^^MAIN/SCALAR\\###VARIABLE NAMED ^^SCALAR\\ IN THE MAIN PROGRAM.
.BLANK
^^ARR\\(7)########THE SEVENTH ELEMENT IN ARRAY ^^ARR\\
.BREAK
.INDENT 20
(SUBSCRIPT MAY ^&NOT\& BE A VARIABLE)
.BLANK
^^ARR\\(*)########ALL VALUES IN ARRAY ^^ARR\\
.BLANK
^P(2,*)########ALL VALUES IN THE SECOND ROW OF ^P.
.LEFT MARGIN 5
.SKIP 2
'*' NOTATION CAN BE USED IN CERTAIN ^^OUTPUT\\ AND ^VALUE ^CHANGE COMMANDS
(^SECTION 4.3.1).
.SKIP 3
^A.3  ^BREAK ^COMMANDS
.SKIP 2
^NOTE: ^BRACKETED INFORMATION IN A COMMAND IS OPTIONAL.
.SKIP 2
^THESE COMMANDS CAUSE BREAKS DURING PROGRAM EXECUTION AT ^&EXECUTABLE\&
^^FORTRAN\\ STATEMENTS OR ON VARIABLES.
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
1.###[^^STOP\\] ^A^T STATEMENT-REFERENCE [,N]
.SKIP 2
OUTPUTS A MESSAGE EVERY NTH TIME THE SPECIFIED STATEMENT POSITION IS
EXECUTED.
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
^^STOP AT SUBR\\/20
.SKIP 2
OUTPUTS ^&<20>\& AND HALTS EXECUTION  EVERY TIME STATEMENT LABELED 20 IN SUBROUTINE 
^^SUBR\\ IS EXECUTED.
.SKIP 2
.INDENT 5
^A^T 75+5,2
.SKIP 2
OUTPUTS ^&<75>+5\& EVERY SECOND TIME THE STATEMENT FIVE PAST STATEMENT
LABELED 75 IS EXECUTED.
.SKIP 3
.INDENT -5
.INDEX ^^ON CALL\\ ^COMMAND
2.###^^[STOP] ON CALL\\ SUBPROGRAM-NAME
.SKIP 2
OUTPUTS A MESSAGE EACH TIME THE INDICATED SUBPROGRAM IS CALLED.
^THE SUBPROGRAM MUST HAVE BEEN COMPILED WITH ^^MANTIS\\.
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
^^ON CALL SUBR\\
.SKIP 2
OUTPUTS ^&^^SUBR CALLED FROM\\ STATEMENT-REFERENCE\& WHEN SUBROUTINE
^^SUBR\\ IS CALLED.
.SKIP 2
.INDENT 5
^^STOP ON CALL FUNC\\
.SKIP 2
OUTPUTS ^&^^FUNC CALLED FROM\\ STATEMENT-REFERENCE\&
WHEN THE FUNCTION ^^FUNC\\ IS CALLED; THEN EXECUTION HALTS AND ^^MANTIS
\\ PROMPTS '*' FOR MORE COMMANDS.
.SKIP 3
.INDENT -5
.INDEX ^^BEFORE RETURN FROM\\ ^COMMAND
3.  ^^[STOP] BEFORE [RETURN FROM\\] SUBPROGRAM-NAME
.SKIP 2
OUTPUTS  A MESSAGE EACH TIME A ^^RETURN\\ OR ^^END\\ STATEMENT IS 
ENCOUNTERED DURING THE INDICATED SUBROUTINE.
.SKIP 2
^EXAMPLE:
.SKIP 2
.INDENT 5
^^BEFORE BETA\\
.SKIP 2
OUTPUTS ^&^^BEFORE RETURN\\\& WHEN CONTROL RETURNS FROM SUBROUTINE
^^BETA\\.
.SKIP 3
.INDENT -5
.INDEX ^POSITION ^REFERENCE
4.  [^^STOP\\] ^O^N VARIABLE [RELATION AND CONSTANT] [POSITION]
.SKIP 2
CAUSES AN EXECUTION BREAK IF THE VARIABLE EITHER
.LEFT MARGIN 25
.SKIP 2
.INDENT -5
A.###SATISFIES THE CONDITION
.BREAK
.INDENT -15
VARIABLE (^^.EQ., .LET., .LE., .GT., .GE., .NE.\\) CONSTANT;
.SKIP 1
OR
.SKIP 1
.INDENT -5
B.###THE VARIABLE CHANGES VALUE AT THE INDICATED STATEMENT OF RANGE OF
STATEMENTS.
.SKIP 2
.LEFT MARGIN 5
^EXAMPLES:
.SKIP 2
.INDENT 5
^^ON VAR .EQ. 0.0 AT MAIN/300\\
.SKIP 2
CAUSES AN EXECUTION BREAK WHEN ^^VAR\\ = 0.0 AT STATEMENT LABELED 300
IN THE MAIN PROGRAM.
.SKIP 2
.INDENT 5
^^ON VAR BETWEEN BETA/+1 AND BETA/15\\
.SKIP 2
CAUSES AN EXECUTION BREAK IF ^^VAR\\ CHANGES ITS VALUE FROM THE 
FIRST EXECUTABLE STATEMENT UP TO THE STATEMENT LABELED 15 IN THE 
SUBROUTINE ^^BETA\\.
.SKIP 2
.INDENT 5
^^ON ARR AT SUBR/+5\\
.SKIP 2
CAUSES AN EXECUTION BREAK IF ANY ELEMENT OF THE ARRAY ^^ARR\\ CHANGES
VALUE ^&AT\& THE FIFTH EXECUTABLE STATEMENT IN SUBROUTINE ^^SUBR\\.
.SKIP 2
.INDEX ^^KILL\\ ^COMMAND
.INDEX ^REVOKE ^BREAK ^COMMANDS
.LEFT MARGIN 5
.INDEX ^BREAK ^COMMANDS, REVOKING
.INDEX ^DELETE ^UNWANTED ^BREAK ^COMMANDS
^A.4  ^^KILL\\ ^COMMAND
.SKIP 2
^THIS COMMAND REVOKES ONE OR ALL BREAK COMMANDS
.SKIP 2
.INDENT 5
^^KILL AT \\STATEMENT-REFERENCE
.SKIP 2
REVOKES THE ^A^T STATEMENT-REFERENCE COMMAND.
.SKIP 2
.INDENT 5
^^KILL ON CALL\\ SUBPROGRAM-NAME
.SKIP 2
REVOKES THE ^^ON CALL\\ COMMAND.
.SKIP 2
.INDENT 5
^^KILL BEFORE\\ SUBPROGRAM-NAME
.SKIP 2
REVOKES THE ^^BEFORE RETURN FROM\\ BREAK.
.SKIP 2
.INDENT 5
^^KILL ON\\ VARIABLE [POSITION]
.SKIP 2
REVOKES THE SPECIFIED ^O^N COMMAND.
.SKIP 2
.INDENT 5
.INDEX ^^KILL\\ ^COMMAND
^^KILL\\
.SKIP 2
REVOKES ALL BREAK COMMANDS.
.SKIP 2
.INDEX ^ACTION ^COMMANDS
^A.5  ^ACTION ^COMMANDS
.SKIP 2
^THERE ARE TWO CLASSES OF ACTION COMMANDS; THOSE WHICH MAY
APPEAR IN COMMAND STRINGS AND THOSE WHICH MAY NOT.
.SKIP 2
.INDEX ^ACTION ^COMMANDS ^WHICH ^MAY ^APPEAR IN ^COMMAND ^STRINGS
^A.5.1  ^ACTION ^COMMANDS ^WHICH ^MAY ^APPEAR IN ^COMMAND ^STRINGS.
.SKIP 2
.INDENT 5
.LEFT MARGIN 15
.INDENT -5
.INDEX ^G^O
1.###^G^O [STATEMENT-REFERENCE]
.SKIP 2
BEGINS OR RESUMES EXECUTION AT THE STATEMENT (IF SPECIFIED)
OR WHEREVER IT LAST STOPPED.
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
^G^O
.SKIP 2
STARTS EXECUTION AT THE PROGRAM ENTRY POINT OR RESUMES EXECUTION WHERE
IT LAST STOPPED.
.SKIP 2
.INDENT 5
^^GO MAIN/5\\
.SKIP 2
STARTS OR RESUMES EXECUTION AT STATEMENT LABELED 5 IN THE MAIN PROGRAM.
.SKIP 2
.INDENT 5
.INDEX ^^STOP\\ ^COMMAND
.INDENT -5
2.###^^STOP\\
.SKIP 2
.INDEX ^HALT ^EXECUTION
.INDEX ^INTERRUPTING ^EXECUTION
HALTS EXECUTION, THEN ^^MANTIS\\ PROMPTS '*' FOR MORE COMMANDS.
.SKIP 2
.INDENT -5
3.###^^OUTPUT\\ VARIABLE-LIST
.BLANK
^^OUTPUT\\ VARIABLE ^^IN TEXT\\, VARIABLE ^^IN TEXT\\,##...
.BLANK
^^OUTPUT\\ VARIABLE ^^IN OCTAL\\, VARIABLE ^^IN OCTAL\\,##...
.INDEX ^^IN TEXT\\
.INDEX ^^IN OCTAL\\
.SKIP 2
OUTPUTS (TO EITHER DISK OR ^^TTY\\) VALUES OF THE VARIABLES IN THE LIST
AS DECIMAL NUMBERS, ^^ASCII\\ CHARACTERS, OR OCTAL NUMBERS, RESPECTIVELY.
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
^^OUTPUT IT1, IT2\\
.SKIP 2
OUTPUTS ^I^T1 AND ^I^T2 AS DECIMAL INTEGERS.
.SKIP 2
.INDENT 5
^^OUTPUT P(1,1) IN TEXT ,  P(2,1) IN OCTAL\\
.SKIP 2
OUTPUTS REAL ARRAY ELEMENTS ^P(1,1) AND ^P(2,1) AS ^^ASCII\\
CHARACTERS AND ^P(2,1) AS AN ^^OCTAL\\ CONSTANT.
.SKIP 2
.INDENT 5
^^OUTPUT ARG:3 IN OCTAL\\
.SKIP 2
OUTPUTS THE THIRD ARGUMENT IN A ^^CALL\\ ARGUMENT LIST AS AN OCTAL NUMBER.
.SKIP 2
.INDEX ^^ARG\\:N ^NOTATION
^NOTE: ^^ARG\\:N NOTATION MAY BE USED ^&ONLY\& IN ^^OUTPUT\\ OR ^VALUE
^CHANGE COMMANDS ATTACHED TO AN ^^ON CALL\\ BREAK COMMAND IN A COMMAND 
STRING, E.G.,
.SKIP 2
.INDENT 5
&*^^ON CALL SUBR; OUTPUT ARG:3 IN OCTAL\\
.SKIP 3
.INDENT -5
4.###^VARIABLE = (NEW VALUE)
.INDEX ^VALUE ^CHANGE ^COMMAND
.SKIP 2
CHANGES THE VALUE OF THE SPECIFIED SCALAR, ARRAY ELEMENT, OR SUBROUTINE
ARGUMENT.
.SKIP 2
^EXAMPLES:
.SKIP 2
.LEFT MARGIN 20
^^XYZ\\ = 4.2#########DECIMAL CONSTANT
.BLANK
##^J#=#'^^HELLO\\####'#LITERAL CONSTANT (^^ASCII\\
#################CHARACTERS)
.BLANK
^^LOG(1) = ^F########LOGICAL CONSTANT (^FALSE)
.BLANK
^^ARR(5) = "577#####OCTAL CONSTANT\\
.SKIP 2
.INDENT -15
.INDEX ^ACTION ^COMMAND ^WHICH ^CANNOT ^APPEAR IN ^COMMAND ^STRINGS
^A.5.2 ^ACTION ^COMMANDS ^WHICH ^CANNOT ^APPEAR IN ^^COMMAND ^STRINGS.
.LEFT MARGIN 15
.INDEX ^^OUTPUT\\
.INDEX ^^IN TEXT\\
.INDEX ^^IN OCTAL\\
.SKIP 2
.INDENT -5
1.###^^OUTPUT\\ ARRAY-NAME
.BLANK
^^OUTPUT\\ ARRAY-NAME ^^IN TEXT\\
.BLANK
^^OUTPUT\\ ARRAY-NAME ^^IN OCTAL\\
.SKIP 2
OUTPUTS TO DISK OR ^^TTY\\ AN ENTIRE ARRAY, OR ANY ROW OR COLUMN
OF AN ARRAY.
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
^^OUTPUT I\\(*)
.SKIP 2
OUTPUTS WHOLE ARRAY ^I AS DECIMAL INTEGERS.
.SKIP 2
.INDENT 5
^^OUTPUT P(*,1) IN TEXT\\
.SKIP 2
OUTPUTS IN ^^ASCII\\ CHARACTERS THE FIRST COLUMN OF ARRAY ^P.
.SKIP 2
.INDENT 5
^^OUTPUT Q(2,*) IN OCTAL\\
.SKIP 2
OUTPUTS AS OCTAL NUMBERS THE SECOND ROW OF ARRAY ^Q.
.SKIP 2
.INDENT -5
2.###^ARRAY = (NEW VALUE)
.SKIP 2
CHANGES VALUES OF ALL OR SPECIFIED SUBSET OF ELEMENT OF THE ARRAY.
.SKIP 2
^EXAMPLES:
.SKIP 2
.LEFT MARGIN 40
.INDENT -20
^I(*) = 0############ENTIRE ARRAY ^I IS INITIALIZED TO 0.
.BLANK
.INDENT -20
^P(*,1) = '^^YES\\'######ELEMENTS IN FIRST COLUMN OF ARRAY ^P
GET VALUE '^^YES'\\.
.BLANK
.INDENT -20
^Q(2,*)#=#"777#######ELEMENTS IN SECOND ROW OF ARRAY ^Q GET THE OCTAL
VALUE 777.
.SKIP 2
.INDEX ^^TYPE\\ ^COMMAND
.INDEX ^^IN TEXT\\
.INDEX ^^IN OCTAL\\
.INDEX ^OUTPUT-TO-^TELETYPE ^COMMAND (^^TYPE\\)
.LEFT MARGIN 15
.INDENT -5
3.###^^TYPE\\ VARIABLE
.BLANK
^^TYPE\\ VARIABLE ^^IN TEXT\\ , VARIABLE ^^IN TEXT\\,##...
.BLANK
^^TYPE\\ VARIABLE ^^IN OCTAL , \\ VARIABLE ^^IN OCTAL\\,##...
.SKIP 2
OUTPUTS TO ^^TTY\\ A LIST OF SCALARS AND ARRAY ELEMENTS OR OUTPUTS A SINGLE
ARRAY OR ARRAY SUBSET.
.SKIP 2
.INDENT -5
.INDEX ^^RESTART\\
4.###^^RESTART\\
.SKIP 2
CLEARS ^^HISTORY\\ TABLE AND RETURNS TO ENTRY POINT OF THE PROGRAM SO
EXECUTION MAY START OVER.
.SKIP 2
.INDENT -5
.INDEX ^^RETRY\\ ^COMMAND
.INDEX ^MODIFICATION OF ^BAD ^DATA
.INDEX ^CORRECTING ^INPUT ^DATA
.INDEX ^DATA, CORRECTION OF DISK INPUT
.INDEX ^ILLEGAL ^CHARACTER IN ^INPUT
.INDEX ^INPUT ^DATA, CORRECTION
5.###^^RETRY\\
.SKIP 2
ALLOWS USER TO CORRECT AND 'REREAD' DATA WHEN AN ILLEGAL CHARACTER IS
ENCOUNTERED.  ^ONLY THE FIRST RECORD OF A MULTI-RECORD FORMAT CAN BE
AFFECTED BY ^^RETRY\\.
.SKIP 2
.INDENT -5
.INDEX ^^EXIT\\ ^COMMAND
.INDEX ^TERMINATE ^EXECUTION
6.###^^EXIT\\
.SKIP 2
CLOSES ^^MANTIS\\ OUTPUT FILE AND TERMINATES EXECUTION.  ^CONTROL
RETURNS TO THE MONITOR.
.SKIP 2
.INDEX ^MONITORING ^COMMANDS
.INDENT -10
^A.6 ^MONITORING ^COMMANDS
.SKIP 2
.INDENT -5
.INDEX ^^HISTORY\\ ^COMMAND
1.###^^HISTORY\\
.SKIP 2
OUTPUTS, MOST RECENT FIRST, THE LIST OF EXCEPTIONS (BRANCHES) TO 
SEQUENTIAL PROGRAM EXECUTION.  ^SUBROUTINE CALLS AND RETURNS AND 
^^MANTIS GO\\ STATEMENT-REFERENCE COMMANDS ARE AUTOMATICALLY LOGGED IN THE
^^HISTORY\\ TABLE.
.SKIP 2
.INDENT -5
.INDEX ^^TRACE\\ ^COMMAND
2.###^^TRACE\\
.BLANK
^^TRACE##OUTPUT\\
.BLANK
^^TRACE##PAUSE\\
.SKIP 2
SETS UP MONITORING OF ^^GO TO\\ AND ^I^F STATEMENT BRANCHES TO BE
 LOGGED IN THE ^^HISTORY\\ TABLES.  ^^CALL\\S, ^^RETURN\\S AND
^^MANTIS GO\\ COMMANDS ARE ALWAYS LOGGED IN THE ^^HISTORY\\ TABLE,
REGARDLESS OF ^^TRACE\\.
.SKIP 2
^^TRACE\\ SETS UP MONITORING IN THE ^^HISTORY\\ TABLE.
.SKIP 2
.INDENT 5
^^TRACE OUTPUT\\
.SKIP 2
SETS UP MONITORING AND OUTPUTS A MESSAGE AT EACH BRANCH.
.SKIP 2
.INDENT 5
^^TRACE PAUSE\\
.SKIP 2
SETS UP MONITORING, OUTPUTS A MESSAGE, AND HALTS EXECUTION AT EACH
BRANCH.
.SKIP 2
.INDENT -5
.INDEX ^^SUBCHECK\\ ^COMMAND
.INDEX ^CHECK ^ARRAY ^SUBSCRIPTS
.INDEX ^SUBSCRIPT ^CHECKING, ARRAYS
3.###^^SUBCHECK\\ ROUTINE-NAME/VARIABLE POSITION
.SKIP 2
SETS UP SUBSCRIPT CHECKING FOR A VARIABLE.
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
^^SUBCHECK\\
.SKIP 2
SETS UP SUBSCRIPT CHECKING FOR ALL ARRAYS UNDER ^^MANTIS\\ CONTROL.
.SKIP 2
.INDENT 5
^^SUBCHECK ARR\\
.SKIP 2
CHECKS ARRAY ^^ARR\\ IN THE CURRENT PROGRAM.
.SKIP 2
.INDENT 5
^^SUBCHECK SUBR/\\
.SKIP 2
CHECKS ALL ARRAYS IN SUBROUTINE ^^SUBR\\ (ASSUMING THAT ^^SUBR\\ WAS
COMPILED WITH ^^MANTIS\\).
.SKIP 2
.INDENT 5
^^SUBCHECK MAIN/I AT 110\\
.SKIP 2
CHECKS SUBSCRIPTS FOR ARRAY ^I IN MAIN PROGRAM AT STATEMENT LABELED
110.
.SKIP 2
.INDENT 5
^^SUBCHECK I BETWEEN 90 AND 100+2\\
.SKIP 2
CHECKS SUBSCRIPTS FOR ARRAY ^I FROM STATEMENT LABELED 90 UP TO THE SECOND
EXECUTABLE STATEMENT PAST  LABEL 100 IN THE CURRENT PROGRAM.
.SKIP 2
.INDENT 5
^^SUBCHECK MAIN/,BETWEEN 50-5 AND 70\\
.SKIP 2
CHECKS ^&ALL\& ARRAYS REFERENCED FROM STATEMENT 50-5 UP TO, BUT NOT
INCLUDING, THE STATEMENT LABELED 70 IN THE MAIN PROGRAM.
.SKIP 2
.INDENT -5
.INDEX ^STATEMENT ^LOCATION ^QUERY
4.###^STATEMENT ^LOCATION ^QUERY
.SKIP 2
^AT ANY '*' PROMPT, THE USER MAY TYPE A CARRIAGE RETURN AND ^^MANTIS\\
WILL TYPE (ON THE ^^TTY\\) THE CURRENT EXECUTION LOCATION WITHIN THE
PROGRAM BEING DEBUGGED.
.SKIP 2
.LEFT MARGIN 5
.INDEX ^^USE\\ ^COMMAND
^A.7 ^^USE\\ ^COMMAND
.SKIP 2
.INDENT 5
^^USE TTY\\
.BLANK
.INDENT 5
^^USE\\ FILENAME
.SKIP 3
SETS THE DEVICE TO WHICH ^^MANTIS\\ OUTPUT WILL BE SENT.
.SKIP 2
^EXAMPLES:
.SKIP 2
.INDENT 5
^^USE TTY\\
.SKIP 2
SENDS ^^MANTIS\\ MESSAGES TO THE USER TELETYPE.  ^THIS IS THE DEFAULT.
^ALSO, A ^^TYPE\\ COMMAND RESETS OUTPUT TO THE TELETYPE.
.SKIP 2
.INDENT 5
^^USE MANTI\\
.SKIP 2
SENDS ^^MANTIS\\ MESSAGES TO A DISK FILE NAMED ^^MANTI.DAT\\.
.SKIP 2
.INDEX ^DISK ^FILE ^CONTROL ^COMMANDS
.INDEX ^MAGNETIC ^TAPE ^CONTROL ^COMMANDS
^A.8 ^MAGNETIC ^TAPE OR ^DISK ^FILE ^CONTROL ^COMMANDS
.SKIP 2
^IF A PROGRAM READS OR WRITES TO UNIT 16:
.SKIP 2
.INDENT 5
^^READ (16,1)\\ LIST
.BREAK
.INDENT 3
1#^^FORMAT\\ (####)
.LEFT MARGIN 15
.SKIP 2
.INDENT -5
.INDEX ^^BACKSPACE\\
1.###^^BACKSPACE _#16\\
.SKIP 2
BACKSPACES THE FILE REFERENCED BY UNIT 16 ONE RECORD.
.SKIP 2
.INDENT -5
.INDEX ^^ENDFILE\\
2.###^^ENDFILE\\ _#16
.SKIP 2
WRITES AN END-OF-FILE MARK ON THE DEVICE REFERENCED BY UNIT 16.
.SKIP 2
.INDENT -5
.INDEX ^^REWIND\\
3.###^^REWIND\\ _#16
.SKIP 2
GOES BACK TO THE BEGINNING OF THE TAPE OR FILE ASSOCIATED WITH UNIT 16.
.SKIP 2
.INDENT -5
.INDEX ^^SKIPRECORD\\
4.###^^SKIPRECORD\\ _#16
.SKIP 2
SKIPS ONE INPUT RECORD IN THE FILE REFERENCE BY UNIT 16.
.SKIP 2
.INDENT -5
.INDEX ^^UNLOAD\\
5.###^^UNLOAD\\ _#16
.SKIP 2
REWINDS THE FILE OR REWINDS AND UNLOADS THE TAPE ASSOCIATED WITH
UNIT 16.
.SKIP 2
.INDENT -5
.INDEX ^^RELEASE\\
6.###^^RELEASE\\ _#16
.SKIP 2
CALLS THE ^^RELEASE\\ LIBRARY SUBROUTINE TO FREE THE BUFFERS AND CHANNEL
ASSOCIATED WITH UNIT 16.
.LEFT MARGIN 5
.SKIP 2
^NOTE: ^THESE DEVICE CONTROL COMMANDS ARE ^^MANTIS\\ CALLS TO THE 
^^FORTRAN\\ DEVICE CONTROL SUBROUTINES DESCRIBED IN ^&^^DEC\\SYSTEM-10
^MATHEMATICAL ^LANGUAGES ^HANDBOOK\&, ^^FORTRAN\\, PAGE 5-20.
.TITLE ^^MANTIS\\ ^APPENDIX ^B
.PAGE
.SKIP 3
.CENTER
^TABLE ^B-1
.SKIP 2
.CENTER
^^MANTIS\\ ^COMMAND ^ERROR ^MESSAGES
.SKIP 2
.INDEX ^DIAGNOSTICS, ^^MANTIS\\
.INDEX ^^MANTIS\\ ^DIAGNOSTICS
.LEFT MARGIN 30
.INDENT -25
####^MESSAGE##########################^EXPLANATION
.SKIP 2
.INDENT -25
?^^ARG NEVER USED\\
.BREAK
^THE SUBROUTINE ARGUMENT REFERENCED BY ^^ARG\\:N DOES NOT APPEAR IN AN EXECUTABLE STATEMENT IN THE SUBROUTINE.
.SKIP 2
.INDENT -25
.INDEX ^^ARG\\:N ^NOTATION
#.^^ARG: VALID ONLY ONCALL\\
.BREAK
^THE NOTATION ^^ARG\\:N CAN ONLY BE USED IN ^^OUTPUT\\ OR ^VALUE ^CHANGE COMMANDS IN AN ^^ONCALL\\ COMMAND STRING.
.SKIP 2
.INDENT -25
?^^BAD ARRAY ELEMENT\\
.BREAK
^THE ARRAY SUBSCRIPT IS OUTSIDE THE RANGE SPECIFIED FOR THE ARRAY IN A ^^DIMENSION\\ STATEMENT.
.SKIP 2
.INDENT -25
?^^BAD POSITION\\
.BREAK
^STATEMENT REFERENCED DOES NOT EXIST IN SPECIFIED (OR ASSUMED) PROGRAM, E.G. ^^MAIN\\/-1.
.SKIP 2
.INDENT -25
?^^BOUNDS UNDEFINED\\
.BREAK
^THERE IS NO CALCULATED REFERENCE TO THE VARIABLE DIMENSIONED ARRAY IN SPECIFIED SUBPROGRAM.
.SKIP 2
.INDENT -25
.INDEX ^COMMAND ^STRINGS
?^^CAN'T STOP AND GO\\
.BREAK
^A COMMAND STRING MAY NOT INCLUDE BOTH A ^^STOP\\ COMMAND AND A ^G^O COMMAND.
.SKIP 2
.INDENT -25
.INDEX ^^KILL\\
?^^GENERAL KILL CANNOT BE ATTACHED\\
.BREAK
^A ^^KILL\\ TO REVOKE ^&ALL\& STATEMENT BREAKS MUST BE AN INDEPENDENT SIMPLE COMMAND; IT CANNOT APPEAR IN A COMMAND STRING.
.SKIP 2
.INDENT -25
?^^GO WHERE?\\
.BREAK
^A ^G^O COMMAND IN A COMMAND STRING MUST INCLUDE A STATEMENT REFERENCE. ^AFTER AN EXIT OR INPUT ERROR, A ^G^O COMMAND MUST INCLUDE A STMT REFERENCE.
.SKIP 2
.INDENT -25
?^^INVALID RELATION\\
.BREAK
^RELATIONAL OPERATOR IN THE ^O^N COMMAND IS MISSPELLED OR LACKS DELIMITING PERIOD(S).
.SKIP 2
.INDENT -25
?^^INVALID UNIT\\
.BREAK
^^FORTRAN\\ UNIT NUMBER REFERENCED IN A ^MAGNETIC ^TAPE/^DISK ^FILE ^CONTROL COMMAND IS TOO SMALL OR LARGE OR IF ^^USE\\ COMMAND HAS BEEN GIVEN, IS EQUAL TO THE ^^USE\\ UNIT NUMBER (24).
.SKIP 2
.INDENT -25
?^^KILL WHAT?\\
.BREAK
^THE BREAK COMMAND TO BE REVOKED WAS INCORRECTLY SPECIFIED OR ISN'T IN EFFECT.
.SKIP 2
.INDENT -25
?^^NAME UNDEFINED\\
.BREAK
^THE STATEMENT-LABEL OR VARIABLE REFERENCED DOES NOT APPEAR IN AN EXECUTABLE STATEMENT IN THE SPECIFIED ROUTINE.
.SKIP 2
.INDENT -25
?^^NO SUCH ARGUMENT\\
.BREAK
^THERE IS NO SUCH ARGUMENT AS ^^ARG\\:N. ^N IS TOO LARGE.
.SKIP 2
.INDENT -25
?^^NOT A COMMAND\\
.BREAK
^COMMAND NOT RECOGNIZABLE.  ^BE SURE BLANKS ARE IN PROPER PLACES AND SPELLING CORRECT.
.SKIP 2
.INDENT -25
?^^NOT VALID ATTACHED\\
.BREAK
^THE SECOND OR LATER COMMAND APPEARING IN THIS COMMAND IS NOT A LEGAL ATTACHED COMMAND.  ^IT CAN APPEAR ONLY AS A SIMPLE COMMAND.
.SKIP 2
.INDENT -25
?^^NOTHING MAY FOLLOW GO\\
.BREAK
^G^O MUST BE THE LAST OR ONLY COMMAND IN STRING.
.SKIP 2
.INDENT -25
?^^NUMBER MUST BE POSITIVE\\
.BREAK
^N MUST BE POSITIVE IN ^^ARG\\:N; ^A^T STATEMENT-REFERENCE, N; AND ^^BEFORE RETURN\\, N.
.SKIP 2
.INDENT -25
?^^ONLY SCALAR ARGS ALLOWED\\
.BREAK
^ONLY SCALAR SUBROUTINE ARGUMENTS MAY BE REFERENCED BY ^^ARG\\:N.
.SKIP 2
.INDENT -25
?^^PROG HAS NOT BEEN CALLED YET\\
.BREAK
^THE ROUTINE SPECIFIED WHEN REFERENCING A DUMMY VARIABLE HAS NEVER BEEN CALLED.
.SKIP 2
.INDENT -25
?^^PROGRAM NOT LOADED OR HAS NO SYMBOLS\\
.BREAK
^PROGRAM REFERENCED IN ^^MANTIS\\ COMMAND WAS NOT COMPILED WITH ^^MANTIS\\ OR IS MISSING.
.SKIP 2
.INDENT -25
?^^RESET. LUUO NOT ALLOWED\\
.BREAK
^^MACRO\\-10 PROGRAMS MAY NOT BE DEBUGGED WITH ^^MANTIS\\.
.SKIP 2
.INDENT -25
?^^SPECIFY ARRAY ELEMENT OR SECTION\\
.BREAK
^AN ARRAY-NAME REFERENCED IN ACTION COMMANDS MUST INCLUDE A SUBSCRIPT QUALIFIER.
.SKIP 2
.INDENT -25
?^^SPECIFY ELEMENT OR JUST NAME\\
.BREAK
'*' NOTATION IS NOT VALID IN THE ^O^N COMMAND.
.SKIP 2
.INDENT -25
?^^STOPPING BECAUSE OF ILLEGAL ASSIGNMENT\\
.BREAK
^THE COMMAND '^^ARG\\:N = CONSTANT' IS ILLEGAL IF THE ARGUMENT REFERENCED
IN THE ^^CALL\\ STATEMENT IS A CONSTANT INSTEAD OF A VARIABLE.
.SKIP 2
.INDENT -25
?^^SYNTAX ERROR\\
.BREAK
^THE COMMAND HAS BEEN MISTYPED.  ^BE SURE BLANKS ARE IN PROPER PLACES.
.SKIP 2
.INDENT -25
?^^TOO MANY COMMAND STRINGS THOUGH ON CMDS WITH INTERSECTING
.BREAK
.INDENT -25
#####RANGES HAVE BEEN REVOKED\\
.BREAK
^THE TABLE WHICH HOLDS BREAK REFERENCES IS FULL.  ^THE NUMBER OF BREAKS ALLOWED VARIES BUT HAS A MINIMUM OF 50.
.SKIP 2
.INDENT -25
?^^THIS CORE LOAD IS IMPOSSIBLY LARGE\\
.BREAK
^THE PROGRAM TO BE DEBUGGED IS TOO LARGE TO FIT IN CORE WITH  THE ^^MANTIS\\ PROGRAM.
.SKIP 2
.INDENT -25
?^^TOO LITTLE CORE\\
.BREAK
^^MANTIS\\ NEEDS MORE CORE THAN IS AVAILABLE TO PERFORM DEBUGGING COMMAND REQUESTED.
.SKIP 2
.TEST PAGE 5
.INDENT -25
^^LABEL FOR GO NEEDED NOW\\
.BREAK
^^RETRY\\ ONLY WORKS WHEN ^^MANTIS\\ OUTPUTS A MESSAGE SUGGESTING IT.
.PAGE
.LEFT MARGIN 5
.CENTER
^TABLE ^B-2
.SKIP 2
.CENTER
^PROGRAM ^EXECUTION ^MESSAGES
.SKIP 2
.INDEX ^DIAGNOSTICS, ^^MANTIS\\
.INDEX ^^MANTIS\\ ^DIAGNOSTICS
.LEFT MARGIN 30
.INDENT -25
####^MESSAGE########################^EXPLANATION
.SKIP 2
.INDENT -25
^A^T STATEMENT-REFERENCE
.BREAK
^NOTIFICATION THAT AN ^O^N BREAKPOINT HAS BEEN REACHED.
.SKIP 2
.INDENT -25
^^BEFORE RETURN\\####N
.BREAK
^NOTIFICATION THAT A ^^BEFORE RETURN\\ BREAKPOINT HAS BEEN REACHED.  ^N IS MULTIPLE RETURN ARGUMENT NUMBER.
.SKIP 2
.INDENT -25
^^CMD GOTO\\ STATEMENT-REFERENCE
.BREAK
^NOTIFICATION BY ^^TRACE\\ OR ^^HISTORY\\ OF A ^^MANTIS GO\\ COMMAND HAVING BEEN GIVEN.
.SKIP 2
.INDENT -25
^^ERROR AT\\ STATEMENT-REFERENCE
.BREAK
^THERE IS AN INPUT OR PROCESSOR ERROR AT THE STATEMENT INDICATED.
.SKIP 2
.INDENT -25
^^EXIT CALLED AT\\ STATEMENT-REFERENCE
.BREAK
^MESSAGE OUTPUT WHEN THE END OF THE USER PROGRAM HAS BEEN REACHED.
.SKIP 2
.INDENT -25
^^GO TO\\ STATEMENT-REFERENCE
.BREAK
^NOTIFICATION BY ^^TRACE\\ OR ^^HISTORY\\ OF A ^^FORTRAN GO TO\\ STATEMENT HAVING BEEN REACHED.
.SKIP 2
.INDENT -25
^^GO TO INPUT STMT AND RE-TYPE DATA\\
.BREAK
^AN ERROR IN INPUT DATA FROM A TELETYPE CAN BE CORRECTED BY USING THE ^G^O COMMAND AND RE-TYPING THE DATA.
.SKIP 2
.INDENT -25
^^IF FORMAT REQUIRES ONE LINE OF DATA YOU MAY RETRY READ\\
.BREAK
^IF THERE IS AN ERROR IN INPUT DATA, IT MAY BE CORRECTED WITH THE ^^RETRY\\ COMMAND.
.SKIP 2
.INDENT -25
^^IF TRUE AT \\STATEMENT-REFERENCE
.BREAK
^NOTIFICATION THAT THE CONDITION IN A LOGICAL ^I^F STATEMENT TESTED TRUE AT THE INDICATED LOCATION.
.SKIP 2
.INDENT -25
^^ILLEGAL I/O REFERENCES AT\\ STATEMENT-REFERENCE ^^TO\\ ARRAY-LIST
.BREAK
^GIVEN BY ^^SUBCHECK\\ WHEN AN INPUT STATEMENT INCLUDES AN ARRAY WITH SUBSCRIPT OUT OF BOUNDS.
.SKIP 2
.INDENT -25
^^INITIALIZE DATA AND GO\\
.BREAK
^AFTER ^^RESTART\\ING, USER WILL WANT TO REINITILIZE VARIABLE IN ^^DATA\\ STATEMENT, COUNTERS, ETC.
.SKIP 2
.INDENT -25
^^INTERRUPTED AT\\ STATEMENT-REFERENCE
.BREAK
^WHEN A USER ^^REENTER\\S PROGRAM EXECUTION, ^^MANTIS\\ TYPES OUT THE LOCATION OF THE NEXT STATEMENT TO BE EXECUTED.
.SKIP 2
.INDENT -25
^^INTERRUPTED AT\\ ?
.BREAK
^IF THE USER INTERRUPTED EXECUTION IS IN A ROUTINE ^&NOT\& COMPILED WITH ^^MANTIS\\ AND ^^REENTER\\S, ^^MANTIS\\ CANNOT LOCATE THE INTERRUPTION POINT.
.SKIP 2
.INDENT -25
^^MISSED KILL\\
.BREAK
^THE BREAKPOINT TO BE ERASED BY THE ATTACHED ^^KILL\\ IN A COMMAND STRING WAS NOT FOUND.
.SKIP 2
.INDENT -25
^^NO COMPUTED REFS\\
.BREAK
^THE ARRAY WHICH IS TO BE ^^SUBCHECK\\ED IS NEVER USED IN AN EXECUTABLE STATEMENT IN THE POSITION SPECIFIED SO THERE IS NOTHING TO ^^SUBCHECK\\.
.SKIP 2
.INDENT -25
^^ONE OR MORE ARRAYS SPECIFIED AS ONLY ONE ELEMENT\\
.BREAK
^IF ANY DUMMY ARRAYS ARE GREATER IN SIZE THAN SPECIFIED IN THE SOURCE PROGRAM, THE ^^SUBCHECK\\ OR ^O^N COMMANDS CANNOT WORK PROPERLY WITH ANY OF THE ARRAYS. ^AN ARRAY CAN BE REFERENCED PROPERLY ONLY IN SUBPROGRAMS WHERE THE TRUE SIZE IS SPECIFIED.
.SKIP 2
.INDENT -25
^^PROGRAM AT\\ STATEMENT-REFERENCE
.BREAK
^NOTIFICATION BY THE  ^LOCATION ^QUERY ^COMMAND  OF THE CURRENT LOCATION OF EXECUTION CONTROL IN THE USER PROGRAM.
.SKIP 2
.INDENT -25
PROGRAM ^^CALLED\\
.BREAK
^NOTIFICATION IN ^^HISTORY\\ TABLE THAT THE INDICATED PROGRAM WAS CALLED.
.SKIP 2
.INDENT -25
PROGRAM ^^CALLED FROM\\ STATEMENT-REFERENCE
.BREAK
^NOTIFICATION THAT AN ^^ON CALL\\ BREAKPOINT WAS REACHED.
.SKIP 2
.INDENT -25
^^REFERENCE TO\\ ARRAY ^^ILLEGAL AT\\ STATEMENT-REFERENCE
.BREAK
^MESSAGE FROM ^^SUBCHECK\\ THAT A SUBSCRIPT FOR THE INDICATED ARRAY IS OUT OF RANGE.
.SKIP 2
.INDENT -25
^^RETRY IMPOSSIBLE SINCE RECORD SPLIT BETWEEN BLOCKS\\
.BREAK
^^RETRY\\ DOES NOT WORK ON A DATA RECORD WHICH OVERLAPS A BLOCK BOUNDARY ON DISK OR TAPE.
.SKIP 2
.INDENT -25
^^RETURNED\\
.BREAK
^^TRACE OUTPUT\\ MESSAGE FOR RETURN FROM A SUBPROGRAM.
.SKIP 2
.INDENT -25
^^RETURNED TO\\ STATEMENT-REFERENCE
.BREAK
^^HISTORY\\ MESSAGE FOR RETURN FROM A SUBPROGRAM.
.SKIP 2
.INDENT -25
^^SETUP\\
.BREAK
^MESSAGE OUTPUT BY ^^SUBCHECK\\ IF IT WAS ABLE TO SETUP THE SUBSCRIPT CHECKING REQUESTED.
.SKIP 2
.INDENT -25
^^STORED\\
.BREAK
^MESSAGE OUTPUT IF A BREAK COMMAND SUCCESSFULLY SETS UP A BREAKPOINT.
.SKIP 2
.INDENT -25
^^TYPE IN NEW LINE ENDING WITH TWO RETURNS\\
.BREAK
^DURING A ^^RETRY\\, TERMINATE CORRECTED DATA LINE WITH TWO CARRIAGE RETURNS.
.LEFT MARGIN 5
.TITLE ^^MANTIS\\ ^APPENDIX ^C
.PAGE
.SKIP 2
^C.0  ^^EXAMPLES\\
.INDEX ^EXAMPLE
.SKIP 2
^EXAMPLE 1: ^THIS EXAMPLE DEMONSTRATES THE USE OF ^^MANTIS\\ COMMANDS
FROM ^CHAPTER 2, ALTHOUGH A COUPLE OF ^CHAPTER 4 COMMANDS APPEAR
ALSO.
.SKIP 2
^THE ^^FORTRAN\\  PROGRAM IN THE EXAMPLE IS A SIMPLE (THOUGH NOT
NECESSARILY EFFICIENT) METHOD OF COMPUTING PERCENTAGES OF TEST SCORES,
GIVEN THE NUMBER OF POINTS RECEIVED AND THE NUMBER OF POINTS POSSIBLE
ON THE TEST.  ^IN ADDITION, THE PROGRAM MAKES CERTAIN COMMENTS DEPENDING
ON WHAT PERCENTAGE SCORE WAS ATTAINED.  ^THE PROGRAM IS CONTAINED IN
TWO FILES: ^^TEST\\, CONTAINING THE MAIN ROUTINE, AND ^^TSUBS\\, CONTAINING
A SUBROUTINE ^^GRADER\\ AND A FUNCTION ^^COMP\\.  ^WHEN REFERRING TO THESE
ROUTINES IN A ^^MANTIS\\ COMMAND, THE USER SPECIFIES ^^MAIN, GRADER,\\
OR ^^COMP\\, RESPECTIVELY.
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
&.^^TYPE TEST
.BLANK
DIMENSION NSCORE(3),NPOS(3),PERCT(3),REMARK(3)
.BLANK
DATA NSCORE/100,90,75/,NPOS/100,100,100/
.BLANK
CALL GRADER(NSCORE,SPOS,PERCT,REMARK,3)
.BLANK
TYPE 20, (NSCORE(I),NPOS(I),PERCT(I),REMARK(I),I=1,3)
.BLANK
.INDENT -5
20###FORMAT(1X,I3,5X,I3,5X,F6.2,5X,A5)
.BLANK
STOP
.BLANK
END
.SKIP 2
.INDENT -5
&.TYPE TSUBS
.BLANK
SUBROUTINE GRADER(NSCROE,NPOS,PERCT,REMARK,N)
.BLANK
DIMENSION NSCORE(N),NPOS(N),PERCT(N),REMARK(N)
.BLANK
DO 10 I=1,N
.BLANK
PERCT(I) = COMP(NSCORE(I),NPOS(I))
.BLANK
.INDENT -5
10###CONTINUE
.BLANK
DO 100 I=1,N
.BLANK
IF(PERCT(I) .LT. 95.0) GO TO 20
.BLANK
REMARK(I) = 'EXCEL'
.BLANK
GO TO 100
.BLANK
.INDENT -5
20###IF(PERCT(I) .LT. 85.0) GO TO 30
.BLANK
REMARK(I) = 'GOOD'
.BLANK
GO TO 100
.BLANK
.INDENT -5
30###IF(PERCT(I) .LT. 70.0) GO TO 40
.BLANK
REMARK(I) = 'OKAY'
.BLANK
GO TO 100
.BLANK
.INDENT -5
40###REMARK(I) = 'WANTS'
.BLANK
.INDENT -5
100##CONTINUE
.BLANK
RETURN
.BLANK
END
.BLANK
FUNCTION COMP(M,N)
.BLANK
COMP = (FLOAT(M)/FLOAT(N))*100.0
.BLANK
RETURN
.BLANK
END\\
.PAGE
.LEFT MARGIN 5
^THE FILES ARE EXECUTED USING THE ^^DEBUG\\ MONITOR COMMAND SIGNIFYING THAT THE FILES ARE TO BE COMPILED WITH
^^MANTIS\\ SYMBOLS AND THAT ^^MANTIS\\ IS TO BE LOADED INTO CORE
ALONG WITH THE USER'S ROUTINE DURING EXECUTION.  ^MANTIS\\ ASSUMES
CONTROL OF EXECUTION AND ISSUES A PROMPT, '*', TO SIGNAL ITS READINESS TO RECEIVE A COMMAND.
.SKIP 2
.LEFT MARGIN 15
.INDEX ^^DEBUG\\
&.^^DEBUG TEST,TSUBS
.BLANK
^&FORTRAN: TEST\&
.BLANK
^&FORTRAN:TSUBS\&
.BLANK
^&LOADING\&
.SKIP 2
^&MANTIS V3\&
.BLANK
^&CURRENT PROGRAM IS MAIN\&
.SKIP 2
.INDENT -5
1)###&*OUTPUT NSCORE(*)
.BLANK
.INDENT 12
^&100##########90##########75\&
.INDENT -5
.BLANK
2)###&*ON CALL GRADER;OUTPUT N;STOP
.BLANK
^&STORED\&
.BLANK
.INDENT -5
3)###&*GO
.BLANK
^&GRADER CALLED FROM MAIN/ + 1\&
.BLANK
^&N=##########3\&
.BLANK
.INDENT -5
4)###&*BEFORE RETURN FROM COMP;
.BLANK
&*OUTPUT M;
.BLANK
&*OUTPUT N;
.BLANK
&*OUTPUT COMP
.BLANK
^&STORED\&
.BLANK
.INDENT -5
5)###&*STOP AT 20-1
.BLANK
^&STORED\&
.BLANK
.INDENT -5
6)###&*GO
.BLANK
^&BEFORE RETURN
.BLANK
^&M=##########100
.BLANK
N=##########100\&
.BLANK
^&COMP=###100.0000\&
.BLANK
^&COMP/\&
.BLANK
^&BEFORE RETURN
.BLANK
^&M=##########90
.BLANK
N=##########100
.BLANK
COMP=###90.00000
.BLANK
COMP/
.BLANK
BEFORE RETURN
.BLANK
M=##########75
.BLANK
N=##########100
.BLANK
COMP=###75.00000
.BLANK
GRADER/
.BLANK
<20>-###1\&
.BLANK
.INDENT -5
7)###&*OUTPUT I
.BLANK
##########&1
.BLANK
.INDENT -5
8)###OUTPUT PERCT(1)
.BLANK
###^&100.0000\&
.BLANK
.INDENT -5
9)###&*OUTPUT REMARK(1)
.BLANK
^&-0.9472284E+31\&
.BLANK
.INDENT -6
10)###&*OUTPUT REMARK(1) IN TEXT
.BLANK
^&EXCEL\&
.BLANK
.INDENT -6
11)###&*ON I.EQ.3;OUTPUT REMARK(2) IN TEXT
.BLANK
^&STORED\&
.BLANK
.INDENT -6
12)###&*STOP AT MAIN/+2
.BLANK
^&STORED\&
.BLANK
.INDENT -6
13)###&*GO
.BLANK
^&AT GRADER/ 10+###1
.BLANK
I=##########3
.BLANK
REMARK(###2) =###GOOD
.BLANK
MAIN/
.BLANK
<>+###2\&
.BLANK
.INDENT -6
14)###&*KILL
.BLANK
.INDENT -6
15)###&*GO
.BLANK
^&100##########100##########100.00##########EXCEL
.BLANK
#90##########100###########90.00##########GOOD
.BLANK
#75##########100###########75.00##########OKAY\&
.BLANK
^&EXIT CALLED AT MAIN/ + 3\&
.BLANK
.INDENT -6
16)###&*NSCORE(1)=50
.BLANK
.INDENT -6
17)###&*NSCR/R/ORE(2)=80
.BLANK
.INDENT -6
18)###&*P/P/NPOS(*)=90
.BLANK
.INDENT -6
19)###&*RESTART
.BLANK
^&INITIALIZE DATA AND GO\&
.BLANK
.INDENT -6
20)###&*GO
.BLANK
^&50##########90##########55.56##########WANTS
.BLANK
80##########90##########88.89##########GOOD
.BLANK
75##########90##########83.33##########OKAY\&
.BLANK
^&EXIT CALLED AT MAIN/ + 3\&
.BLANK
.INDENT -6
21)###&*EXIT
.SKIP 2
^&EXECUTION TIME##########0.23 SEC.
.BLANK
TOTAL ELAPSED TIME:#####27.02 SEC.
.BLANK
NO EXECUTION ERRORS DETECTED
.BLANK
EXIT
.BLANK
#.\&
.LEFT MARGIN 5
.PAGE
.INDENT 5
(1)&*OUTPUT NSCORE(*)\\
.SKIP 2
^THE FIRST COMMAND (1) GIVEN TO ^^MANTIS\\ IS A COMMAND TO OUTPUT ALL
OF THE ELEMENTS OF THE ARRAY ^^NSCORE\\ IMMEDIATELY.  ^THE '*' SUBSCRIPT MEANS ALL ELEMENTS IN THE ARRAY.  ^A SINGLE ARRAY ELEMENT MAY
ALSO BE OUTPUT AS SHOWN IN  COMMAND (8).\\.  ^NOTE ALSO THAT ^^NSCORE\\ WAS
OUTPUT IN AN INTEGER FORMAT.  ^THIS CORRESPONDS TO THE FACT THAT
^^NSCORE\\ IS OF TYPE ^INTEGER WITHIN THE ^^MAIN\\ ROUTINE.
.SKIP 2
.INDENT 5
(2)&*^^ON CALL GRADER; OUTPUT N; STOP\\
.BLANK
.INDENT 9
^&^^STORED\\\&
.SKIP 2
^THIS COMMAND STRING DIRECTS ^^MANTIS\\ TO (1) PROVIDE NOTIFICATION
WHEN ^^GRADER\\ IS CALLED, (2) OUTPUT THE VALUE OF ^N (ONE OF THE
ARGUMENTS OF ^^GRADER\\), AND (3) STOP EXECUTION IN ORDER TO RECEIVE 
ANOTHER COMMAND.  ^THE FIRST PART, ^^ON CALL GRADER\\, IS A BREAK
COMMAND SO NAMED BECAUSE IT SETS AN EXECUTION BREAK WHEN ^^GRADER\\ IS
CALLED.  ^THE SEMICOLON FOLLOWING THE STORED COMMAND INDICATES THAT
ANOTHER COMMAND FOLLOWS.  ^THE ACTION COMMAND ^^OUTPUT N\\ WILL ONLY
BE EXERCISED AT THE BREAKPOINT SET BY THE ^^ON CALL GRADER\\ COMMAND.
^SIMILARLY, THE SEMICOLON FOLLOWING ^^OUTPUT N\\ INDICATES THAT
ANOTHER COMMAND IS ATTACHED (I.E., ^^STOP\\) WHICH DIRECTS ^^MANTIS\\
TO STOP EXECUTION AT THAT POINT (WHEN ^^GRADER\\ IS CALLED).  ^^MANTIS\\
INDICATES ACCEPTANCE OF A BREAK COMMAND OR A COMMAND STRING BY RESPONDING ^&^^STORED\\\&.
.SKIP 2
.INDENT 5
(3)&*^G^O
.SKIP 2
^THE THIRD COMMAND IS NEARLY SELF EXPLANATORY.  ^IT DIRECTS ^^MANTIS\\
TO BEGIN EXECUTION AT THE CURRENT PLACE, WHICH HAPPENS TO BE THE START
OF THE PROGRAM.
.SKIP 2
.LEFT MARGIN 15
^&^^GRADER CALLED FROM MAIN/+1
.BLANK
N=##########3
.BLANK
*\\\&
.SKIP 2
.LEFT MARGIN 5
^^MANTIS\\ IS EXECUTING THE STORED COMMAND GIVEN IN (2), TELLING THE
USER THAT ^^GRADER\\ WAS CALLED FROM THE FIRST EXECUTABLE
STATEMENT IN ROUTINE ^^MAIN\\, OUTPUTTING THE VALUE OF ^N, AND STOPPING.
^THE PROGRAM HAS BEEN STOPPED JUST AFTER ENTERING ^^GRADER\\ SO THAT
^N HAS A VALUE OF 3 WHICH IT JUST RECEIVED FROM ^^MAIN\\.
.SKIP 2
.LEFT MARGIN 13
.INDENT -3
(4)&*^^BEFORE RETURN FROM COMP;
.BLANK
&*OUTPUT M;
.BLANK
&*OUTPUT N;
.BLANK
&*OUTPUT COMP
.BLANK
^&STORED\\\&
.SKIP 2
.LEFT MARGIN 5
^THE FOURTH COMMAND, ANOTHER COMMAND STRING, DIRECTS ^^MANTIS\\ TO
(1) PROVIDE NOTIFICATION, (2) OUTPUT THE VALUE OF ^M, (3) OUTPUT ^N,
AND (4) OUTPUT ^^COMP\\ (JUST BEFORE  RETURNING FROM ^^FUNCTION COMP\\).
^THIS IS AN ALTERNATIVE WAY TO STRING TOGETHER ^^MANTIS\\ COMMANDS.
^ALTHOUGH THEY ARE ON DIFFERENT LINES, THE SEMICOLON SIGNIFIES THAT
ANOTHER COMMAND IS APPENDED.  ^THE ABSENCE OF A SEMICOLON ON ^^OUTPUT
COMP\\ SIGNIFIES THE END OF THE COMMAND STRING AND ^^MANTIS\\ REPLIES
WITH ^&^^STORED\\\&.  ^NOTE THAT THE PROGRAM WILL NOT STOP BEFORE RETURNING
SINCE NO ^^STOP\\ COMMAND HAS BEEN APPENDED.
.SKIP 2
.LEFT MARGIN 13
.INDENT -3
(5)&*^^STOP AT 20-1
.BLANK
^&STORED\&
.BLANK
&*GO\\
.SKIP 2
.LEFT MARGIN 5
^BEFORE EXECUTION RESUMES, A SIMPLE BREAK COMMAND IS ALSO GIVEN TO
^^MANTIS\\.  ^IT TELLS ^^MANTIS\\ TO STOP EXECUTION JUST PRIOR TO
EXECUTING THE FIRST ^&EXECUTABLE\& STATEMENT BEFORE STATEMENT 20
IN SUBROUTINE ^^GRADER\\.
.SKIP 2
.INDENT 9
^^GO TO\\ 100###################(THIS IS STATEMENT 20-1.)
.BLANK
.INDENT 5
20##^^IF(PERCT(I) .LT. 85.0) GO TO 30\\
.SKIP 2
^THE PROGRAM FLOW WILL ONLY REACH THIS STATEMENT IF ^^PERCT(I)\\ IS
GREATER THAN OR EQUAL TO 85.0.  ^NOTE THAT 20-1 REFERS TO A
STATEMENT IN ^^GRADER\\ SINCE ^^GRADER\\ HAS BECOME THE CURRENT PROGRAM.
.SKIP 2
^FINALLY, ^G^O (^COMMAND (6)) IS TYPED TO CONTINUE EXECUTION.
.LEFT MARGIN 15
.SKIP 2
&*^G^O
.BLANK
^^^&BEFORE RETURN
.BLANK
M=##########100
.BLANK
N=##########100
.BLANK
COMP=######100.0000\\\&
.LEFT MARGIN 5
.SKIP 2
^^MANTIS\\ IS PERFORMING THE NOTIFICATION AND OUTPUTTING THE VALUES
SPECIFIED IN COMMAND (4).  ^NOTE THAT THE ABOVE SEQUENCE IS REPEATED 
THREE TIMES, ONCE JUST PRIOR TO EACH TIME A RETURN FROM ^^COMP\\ WAS
MADE.  ^COMMAND STRINGS AND SIMPLE BREAK COMMAND REMAIN IN EFFECT UNTIL
EXPLICITLY REVOKED WITH A ^^KILL\\ COMMAND.  ^SEE COMMAND (14).  ^NOTE
THAT THE PROGRAM FLOW IS STILL IN ^^COMP\\--^M AND ^N WOULD HAVE
NO MEANING IN OTHER ROUTINES SINCE THEY ARE NOT VARIABLES IN ANY OF THE OTHER
ROUTINES.
.SKIP 2
.LEFT MARGIN 15
^&^^GRADER/
.BLANK
<20>-1
.BLANK
*\\\&
.LEFT MARGIN 5
.SKIP 2
^^MANTIS\\ NOTIFIES THE USER THAT THE EXECUTABLE STATEMENT PRIOR TO THE
STATEMENT LABELED 20 WAS REACHED IN SUBROUTINE ^^GRADER.  \\^THE STORED
COMMAND FOR THIS WAS GIVEN IN COMMAND (5).  ^IN ADDITION, ^^MANTIS\\ 
WAS TOLD TO STOP, THEREFORE THE PROMPT APPEARS AND ^^MANTIS\\ WILL ACCEPT
COMMANDS.
.SKIP 2
.LEFT MARGIN 13
.INDENT -3
(7)&*^^OUTPUT I
.BLANK
##########&1
.BLANK
.INDENT -3
(8)&*OUTPUT PERCT(1)
.BLANK
#^&100.0000\&
.BLANK
.INDENT -3
(9)&*OUTPUT REMARK(1)
.BLANK
#-^&0.0472284E+31\&
.BLANK
.INDENT -4
(10)&*OUTPUT REMARK(1) IN TEXT
.BLANK
#^&EXCEL\\\&
.SKIP 2
.LEFT MARGIN 5
^WHILE THE PROGRAM EXECUTION IS STOPPED AT ^^GRADER\\/20-1, THE
USER GIVES ^^MANTIS\\ FOUR ^^OUTPUT\\ COMMANDS, OUTPUTTING VALUES OF VARIABLES
AND/OR SPECIFIC ARRAY ELEMENTS WHICH ARE OF INTEREST AT THIS POINT IN
THE PROGRAM.  ^NOTE THAT ^^REMARK\\(1) IS AT FIRST OUTPUT
AS A VERY LARGE NEGATIVE NUMBER INSTEAD OF AS CHARACTERS.  ^THE REASON IS THAT THE USER FORGOT
TO INCLUDE THE QUALIFIER '^^IN TEXT\\' IN THE OUTPUT COMMAND.
^A SECOND ATTEMPT WHICH ADDED '^^IN TEXT\\', PRINTED THE ARRAY
ELEMENT PROPERLY AS AN ^^ASCII\\ CHARACTER STRING.
.SKIP 2
.INDENT 5
(11)&*^^ON I .EQ. 3; OUTPUT REMARK(2) IN TEXT
.BLANK
.INDENT 9
^&STORED\\\&
.SKIP 2
^THIS COMMAND STRING SPECIFIES THAT WHEN THE VARIABLE ^I IS GIVEN THE 
VALUE 3 ANY PLACE WITHIN ^^GRADER, MANTIS\\ WILL PROVIDE NOTIFICATION
AND ALSO OUTPUT THE VALUE OF ^^REMARK(2) \\AS ^^ASCII\\ CHARACTERS.
^^MANTIS\\ WILL NOT STOP SINCE NO ^^STOP\\ COMMAND WAS APPENDED TO THE
^O^N COMMAND.
.SKIP 2
.INDENT 5
(12)&*^^STOP AT MAIN\\/+2
.SKIP 2
^THIS COMMAND TELLS ^^MANTIS\\ TO STOP AT THE SECOND EXECUTABLE STATEMENT
IN THE MAIN ROUTINE.  ^^MAIN\\/ IS NECESSARY TO IDENTIFY THE STATEMENT
  BECAUSE 1) +2 IS ILLEGAL--EITHER A STATEMENT LABEL OR A ROUTINE-NAME MUST
 BE INCLUDED IN A ^^MANTIS\\
STATEMENT REFERENCE; 2) ROUTINE-NAME QUALIFIER, STATEMENT REFERENCES
ARE ASSUMED TO BE IN THE CURRENTLY EXECUTING ROUTINE, WHICH RIGHT
NOW IS ^^GRADER\\.
.SKIP 2
.INDENT 5
(13)^&^^AT GRADER\\/10+1
.BLANK
.INDENT 9
^I =##########3\&
.LEFT MARGIN 14
.BLANK
^&^^REMARK(2) = ##GOOD\&\\
.BLANK
^&^^MAIN/\\\&
.BLANK
<>+2
.BLANK
&*
.LEFT MARGIN 5
.SKIP 2
^^MANTIS\\ PERFORMS COMMANDS (11) AND (12).  ^SINCE (12) SPECIFIED ^^STOP\\,
A PROMPT IS GIVEN.
.SKIP 2
.INDENT 5
(14)&*^^KILL\\
.SKIP 2
^UNTIL THIS MOMENT ALL BREAK COMMANDS AND COMMAND STRINGS (2), (4), 
(5), (11), AND (12) WERE IN EFFECT.  ^THIS COMMAND ^^ERASES\\ OR ^&^^KILL\\S\& ALL THESE COMMANDS.
.SKIP 2
.LEFT MARGIN 13
.INDENT -4
(15)&*^G^O
.BLANK
#.
.BREAK
#.
.BREAK
#.
.BLANK
#OUTPUT FROM PROGRAM
.BLANK
#.
.BREAK
#.
.BREAK
#.
.BLANK
^&^^EXIT CALLED AT MAIN\\/+3\&
.SKIP 2
.LEFT MARGIN 5
^THE USER RESUMES EXECUTION AT ^^MAIN\\/+2 WHICH HAPPENS TO BE THE
^^TYPE\\ STATEMENT.  ^THE OUTPUT FROM THE PROGRAM IS TYPED AND ^^MANTIS\\
INFORMS THE USER THAT ^^MAIN\\/+3 (A ^^STOP\\ STATEMENT) IS THE NEXT
EXECUTABLE STATEMENT IN THE PROGRAM.  ^AT THIS POINT, THE USER MAY TERMINATE EXECUTION WITH AN
^^EXIT\\ COMMAND OR HE MAY REEXECUTE ALL OR PART
OF THE PROGRAM.
.SKIP 2
.INDENT 5
(16)&*^^NSCORE(1) = 50
.SKIP 2
.INDENT 5
(17)&*NSCORE(2) = 80
.SKIP 2
.INDENT 5
(18)&*NPOS(*) = 90\\
.SKIP 2
^THE USER REDEFINES THE VALUES OF ^^NSCORE\\(1), ^^NSCORE\\(2), AND
ALL THREE VALUES OF ^^NPOS\\.
.SKIP 2
.INDENT 5
(19)&*^^RESTART
.BLANK
.INDENT 9
^&INITIALIZE DATA AND GO\&
.BLANK
.INDENT 9
&*GO\\
.SKIP 2
^THE USER WISHES TO RERUN THE PROGRAM WITH THE NEW DATA ENTERED IN (16-18).
^^RESTART\\ STARTS THE PROGRAM OVER AT THE BEGINNING.  ^^MANTIS\\
REMINDS THE USER THAT SOME DATA CHANGES MIGHT BE NECESSARY.  ^IN THIS
CASE, NONE WERE, SO THE USER TYPES ^G^O TO START EXECUTION.
.SKIP 2
.LEFT MARGIN 15
.INDENT -4
.TEST PAGE 7
(20)PROGRAM OUTPUT
.BLANK
#.
.BREAK
#.
.BREAK
#.
.BLANK
^&^^EXIT CALLED AT MAIN\\/+3\&
.SKIP 2
.INDENT -4
(21)&*^^EXIT\\
.LEFT MARGIN 5
.SKIP 2
^THE PROGRAM EXECUTES AGAIN AND THE ^^STOP\\ STATEMENT AT ^^MAIN\\/+3 IS
REACHED.  ^NOTE THAT ^^MANTIS\\ DID NOT INTERRUPT EXECUTION, SINCE
ALL STORED COMMANDS HAD BEEN KILLED IN (14).  ^NOTE ALSO THAT THE
PROGRAM OUTPUT REFLECTS THE DATA CHANGES IN (16-18).  ^FINALLY, THE
USER TYPES ^^EXIT\\, WHICH DELETES ^^MANTIS\\ AND ALLOWS THE PROGRAM
TO TERMINATE NORMALLY.
.PAGE
.SKIP 2
.INDEX ^EXAMPLE
^EXAMPLE 2:
.SKIP 2
^THIS EXAMPLE DEMONSTRATES THE USE OF ^^MANTIS\\ COMMANDS
FROM BOTH ^CHAPTER 2 AND ^CHAPTER 4.
.SKIP 2
^THE FOLLOWING PROGRAM CONTAINS TWO BUGS:
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
1.###^^ISTART\\ IS INITIALIZED TO ZERO, SO THE FIRST REFERENCE TO 
^^IARRAY\\ (^^IRRAY\\(0)) IS ILLEGAL;
.SKIP 2
.INDENT -5
2.###^^INC\\ IS INITIALIZED TO ZERO (BY DEFAULT), SO THE VALUE OF 
^I NEVER CHANGES, THUS CAUSING AN INFINITE LOOP.
.SKIP 2
.LEFT MARGIN 15
.INDENT -5
&.^^TY INFIN
.BLANK
DIMENSION IDUMMY(2),IARRAY(5)
.BREAK
DATA IEND/5/
.BREAK
I=ISTART
.BREAK
.INDENT -5
10###IARRAY(I)=10*I
.BREAK
I=I+INC
.BREAK
IF(I.LE.IEND) GO TO 10
.BREAK
STOP
.BREAK
END\\
.SKIP 2
.INDENT -10
^THE PROGRAMMER COULD USE ^^MANTIS\\ TO FIND THESE TWO BUGS:
.LEFT MARGIN 10
.SKIP 2
&.^^EX /MAN INFIN
.BLANK
^&FORTRAN:  INFIN
.BLANK
LOADING
.SKIP 2
MANTIS V3
.BLANK
CURRENT PROGRAM IS MAIN\\\&
.SKIP 2
.LEFT MARGIN 40
.INDENT -30
&*^^TRACE########################\\^FIRST, A ^^TRACE\\ COMMAND IS ENTERED TO MONITOR
THE FLOW OF EXECUTION.
.SKIP 2
.INDENT -30
&*^G^O###########################^AFTER ^G^O HAS BEEN TYPED AND AN
.BREAK
.INDENT -30
_^^C############################INORDINATE
AMOUNT OF TIME HAS
.BREAK
.INDENT -30
_^^C############################ELAPSED WITH NO PROGRAM RESPONSE, THE USER TYPES
_^^C_^^C TO LEAVE PROGRAM EXECUTION AND RETURN TO THE MONITOR.
.SKIP 2
.INDENT -30
&.^^REE\\##########################^EXECUTION IS ^^REENTER\\ED.  ^^MANTIS\\
INFORMS THE USER AT WHICH STATEMENT IN THE PROGRAM EXECUTION WAS
INTERRUPTED.
.SKIP 2
.INDENT -30
^&^^INTERRUPTED AT MAIN\\/ 10\&#######^THIS STATEMENT (^^MAIN\\/10) ^&IS
ONE\& OF THE ^&STATEMENTS\& IN THE INFINITE LOOP.
.BLANK
.INDENT -30
&*^^USE TRCFL\\
.SKIP 2
.INDENT -30
&*^^HISTORY\\######################^SINCE THE ^^HISTORY\\ TABLE CAN HOLD 200 LINES OF OUTPUT AND THE ^^TTY\\ IS A 'SLOW' DEVICE, THE USER DIRECTS ^^MANTIS \\OUTPUT TO THE DISK FILE 
^^TRCFL.DAT\\, WHICH CAN BE EXAMINED LATER.
.SKIP 2
.INDENT -30
&*^^USE TTY\\######################^THE USER NOW REDIRECTS ^^MANTIS\\
OUTPUT TO HIS TELETYPE, EXAMINES AND CORRECTS ^^INC\\,
.SKIP 2
.INDENT -30
&*^^OUTPUT INC\\
.SKIP 2
.INDENT -30
&0
.BLANK
.INDENT -30
&*^^INC\\=1
.SKIP 2
.INDENT -30
&*^^STOP TRACE\\###################^STOPS ALL ^^TRACE\\ING, AND
.SKIP 2
.INDENT -30
&*^^SUBCHECK\\#####################^SETS UP SUBSCRIPT CHECKING FOR ALL
ARRAYS.
.BLANK
.INDENT -30
^&^^SETUP\\\&
.SKIP 2
.INDENT -30
&*^^GO MAIN\\/+1##################^RESUMES EXECUTION AT THE BEGINNING OF
THE PROGRAM.
.SKIP 2
.INDENT -30
^&^^REFERENCE TO IARRAY ILLEGAL AT MAIN\\/ 10\&#####^A SUBSCRIPT ERROR IS
FOUND AT ^^MAIN\\/10.
.BLANK
.INDENT -30
&*^^OUTPUT I\\
.SKIP 2
.INDENT -30
&0
.BLANK
.INDENT -30
&*^^ISTART=1\\#####################^THE USER EXAMINES AND CORRECTS THE
SUBSCRIPT VARIABLE ^I, AND
.SKIP 2
.INDENT -30
&*^^EXIT\\#########################^EXITS TO THE MONITOR SO HE CAN EDIT HIS
PROGRAM FILE.
.SKIP 3
.LEFT MARGIN 10
^&^^EXECUTION TIME:#########5.48 SEC.
.BLANK
TOTAL ELAPSED TIME:#####2 MIN. 25.30 SEC.
.BLANK
NO EXECUTION ERRORS DETECTED\\\&
.SKIP 2
^&^^EXIT\\\&
.SKIP 2
&.^^TY TRCFL.DAT
.BLANK
^&MANTIS OUTPUT\&
.SKIP 2
.NOFILL
.TAB STOPS 40
^&GO TO MAIN/  10\\\&	^THE INFINITE LOOP IS WELL
^&^^GO TO MAIN/  10\\\&	REPRESENTED BY THE SERIES
^&^^GO TO MAIN/  10\\\&	OF [^^GO TO MAIN\\/10] ENTRIES
^&^^GO TO MAIN/  10\\\&	IN THE ^^HISTORY\\ OUTPUT
^&^^GO TO MAIN/  10\\\&	WHICH WAS SENT TO THE 
^&^^GO TO MAIN/  10\\\&	FILE ^^TRCFL.DAT\\.
^&^^GO TO MAIN/  10
GO TO MAIN/  10
GO TO MAIN/  10
GO TO MAIN/  10
GO TO MAI\\\&_^^C
.FILL
.NONUMBER
.TITLE ^INDEX
.LEFT MARGIN 0
.PAGE
.PAPER SIZE 58 105
.PRINT INDEX