Google
 

Trailing-Edge - PDP-10 Archives - SRI_NIC_PERM_FS_1_19910112 - c/user/ncref/parses.fai
There are no other files named parses.fai in the archive.
	TITLE	parses
	EXTERN	$$ONE
	OPDEF	ADJBP	[IBP]	
DEFINE %CHRBP(TOAC,FRMBP)	
<	SETO	TOAC,		
	ADJBP	TOAC,FRMBP	
>




	IFNDEF	ERJMP,< OPDEF ERJMP [JUMP 16,] >
	OPDEF	ERJMPA	[ERJMP]
	OPDEF	XMOVEI	[SETMI]
	DEFINE	IFIW	<SETZ >



	.REQUEST C:CLIB


	TWOSEG	400000	    	
	RELOC	0
	RELOC	400000		

	DEFINE	$$CODE	<RELOC>
	DEFINE	$$DATA	<RELOC>


IFNDEF $START,<		
	EXTERN	$START
	EXTERN	$RET,$RETZ,$RETN,$RETP,$RETF,$RETT
	EXTERN	$ZERO
>


	PURGE	IFE,IFN,IFG,IFGE,IFL,IFLE,IFDEF,IFNDEF,IFIDN,IFDIF



	$$DATA

	$$CODE
parse:
	ADJSP 17,12
	SETZB 4,0(17)
	MOVEM 4,-1(17)
	MOVEM 4,-2(17)
	MOVEM 4,-4(17)
	MOVEM 4,-5(17)
	MOVEM 4,-6(17)
	MOVEM 4,-10(17)
	MOVEM 4,-7(17)
	MOVEI 3,1
	MOVEM 3,-3(17)
	MOVEM 3,pg
	MOVEM 3,ln
$2::
	SKIPN 4,-3(17)
	 JRST $3
	MOVE 5,-6(17)
	CAIGE 5,23420
	 JRST $4
	SKIPN 6,-4(17)
	 JRST $5
	XMOVEI 3,string
	IOR 3,$BYTE
	PUSH 17,3
	PUSH 17,ln
	PUSH 17,pg
	XMOVEI 7,$6
	IOR 7,$BYTE*$$ONE+4
	PUSH 17,7
	PUSHJ 17,printf
	ADJSP 17,-4
	PUSHJ 17,exit
	JRST $4
$5::
	SETZB 3,0(17)
	MOVEM 3,-6(17)
	PUSHJ 17,backup
	MOVEM 1,-6(17)
$4::
	PUSH 17,iop
	PUSHJ 17,getc
	ADJSP 17,-1
	MOVEM 1,-11(17)
	JUMPGE 1,$7
	SETZB 3,-3(17)
	MOVEI 4,73
	MOVEM 4,-11(17)
$7::
	SKIPN 4,-5(17)
	 JRST $8
	MOVE 6,-11(17)
	CAIN 6,12
	 JRST $11
	CAIN 6,57
	 JRST $10
	CAIE 6,52
	 JRST $12
	MOVEM 6,-10(17)
	JRST $2
$10::
	MOVE 4,-10(17)
	CAIE 4,52
	 JRST $2
	SETZB 3,-5(17)
	MOVE 6,-7(17)
	MOVEM 6,-10(17)
	JRST $2
$11::
	PUSHJ 17,incloc
	SKIPN 7,-6(17)
	 JRST $12
	MOVE 5,-7(17)
	CAIE 5,40
	 JRST $13
	MOVEI 3,12
	ADJBP 7,[1100,,string*$$ONE-1]
	DPB 3,7
	MOVEM 3,-7(17)
	JRST $12
$13::
	MOVEI 3,12
	AOS 4,-6(17)
	ADJBP 4,[1100,,string*$$ONE-1]
	DPB 3,4
	MOVEM 3,-7(17)
$12::
	MOVE 4,-11(17)
	MOVEM 4,-10(17)
	JRST $2
$8::
	MOVE 4,-11(17)
	MOVM 5,4
	IDIVI 5,16
	CAME 4,$24(6)
	 JRST $1
	JRST @$25(6)
$24::
	 52
	 -1
	 -1
	 73
	 40
	 57
	 42
	 43
	 134
	 11
	 12
	 47
	 50
	 -1
$25::
	IFIW $15
	IFIW $1
	IFIW $1
	IFIW $22
	IFIW $21
	IFIW $16
	IFIW $17
	IFIW $14
	IFIW $19
	IFIW $21
	IFIW $20
	IFIW $18
	IFIW $23
	IFIW $1
$14::
	SKIPN 4,-2(17)
	 SKIPE 3,-1(17)
	 JRST $2
	CAMN 3,-6(17)
	 JRST $26
	MOVE 6,-6(17)
	ADJBP 6,[1100,,string*$$ONE-1]
	LDB 7,6
	CAIE 7,12
	 JRST $1
$26::
	AOS 3,0(17)
	JRST $2
$15::
	SKIPN 4,-2(17)
	 SKIPE 5,-1(17)
	 JRST $27
	MOVE 6,-10(17)
	CAIE 6,57
	 JRST $28
	MOVEI 3,1
	MOVEM 3,-5(17)
	SOS 7,-6(17)
	JRST $27
$28::
	MOVE 4,-11(17)
	AOS 3,-6(17)
	ADJBP 3,[1100,,string*$$ONE-1]
	DPB 4,3
$27::
	MOVE 4,-11(17)
	MOVEM 4,-10(17)
	JRST $2
$16::
	SKIPN 4,-2(17)
	 SKIPE 5,-1(17)
	 JRST $29
	MOVE 6,-10(17)
	MOVEM 6,-7(17)
	MOVE 7,-11(17)
	AOS 3,-6(17)
	ADJBP 3,[1100,,string*$$ONE-1]
	DPB 7,3
$29::
	MOVE 4,-11(17)
	MOVEM 4,-10(17)
	JRST $2
$17::
	SKIPE 4,-2(17)
	 JRST $30
	MOVE 5,-10(17)
	CAIE 5,134
	 SKIPA 3,[1]
	 TRNA 
	 XORB 3,-1(17)
$30::
	MOVE 4,-11(17)
	MOVEM 4,-10(17)
	JRST $2
$18::
	SKIPE 4,-1(17)
	 JRST $31
	MOVE 5,-10(17)
	CAIE 5,134
	 SKIPA 3,[1]
	 TRNA 
	 XORB 3,-2(17)
$31::
	MOVE 4,-11(17)
	MOVEM 4,-10(17)
	JRST $2
$19::
	MOVE 4,-10(17)
	CAIE 4,134
	 JRST $32
	SETZB 3,-10(17)
	JRST $2
$32::
	MOVE 4,-11(17)
	MOVEM 4,-10(17)
	JRST $2
$20::
	SKIPN 4,0(17)
	 JRST $33
	SETZ 3,
	MOVE 6,-6(17)
	ADJBP 6,[331100,,string]
	DPB 3,6
	MOVEM 3,-10(17)
	SKIPE 7,-4(17)
	 PUSHJ 17,parse2
	SETZB 3,0(17)
	MOVEM 3,-4(17)
	MOVEM 3,-6(17)
	JRST $2
$33::
	PUSHJ 17,incloc
	SKIPN 7,-6(17)
	 JRST $35
	MOVE 5,-10(17)
	CAIE 5,40
	 JRST $36
	MOVEI 3,12
	ADJBP 7,[1100,,string*$$ONE-1]
	DPB 3,7
	JRST $35
$36::
	MOVEI 3,12
	AOS 4,-6(17)
	ADJBP 4,[1100,,string*$$ONE-1]
	DPB 3,4
$35::
	MOVE 4,-11(17)
	MOVEM 4,-10(17)
	JRST $2
$21::
	SKIPN 4,-2(17)
	 SKIPE 3,-1(17)
	 JRST $37
	CAMN 3,-6(17)
	 JRST $2
	MOVE 7,-10(17)
	CAIE 7,40
	 CAIN 7,12
	 JRST $2
	MOVEI 5,40
	AOS 6,-6(17)
	ADJBP 6,[1100,,string*$$ONE-1]
	DPB 5,6
	MOVEM 5,-10(17)
	JRST $2
$37::
	MOVE 4,-11(17)
	MOVEM 4,-10(17)
	JRST $2
$22::
	SKIPN 4,-2(17)
	 SKIPE 3,-1(17)
	 JRST $38
	MOVE 6,-6(17)
	ADJBP 6,[331100,,string]
	DPB 3,6
	MOVEM 3,-10(17)
	SKIPE 7,-4(17)
	 PUSHJ 17,parse2
	SETZB 3,-4(17)
	MOVEM 3,-6(17)
	JRST $2
$38::
	MOVE 4,-11(17)
	MOVEM 4,-10(17)
	JRST $2
$23::
	SKIPN 4,-2(17)
	 SKIPE 5,-1(17)
	 SKIPA 6,-11(17)
	 JRST $40
	MOVEM 6,-10(17)
	JRST $2
$40::
	AOS 3,-4(17)
$1::
	SKIPN 4,-2(17)
	 SKIPE 3,-1(17)
	 JRST $42
	CAME 3,-6(17)
	 JRST $43
	MOVE 6,pg
	MOVEM 6,rpg
	MOVE 7,ln
	MOVEM 7,rln
$43::
	MOVE 4,-11(17)
	AOS 3,-6(17)
	ADJBP 3,[1100,,string*$$ONE-1]
	DPB 4,3
$42::
	MOVE 4,-11(17)
	MOVEM 4,-10(17)
	JRST $2
$3::
	ADJSP 17,-12
	POPJ 17,
$6::
	BYTE	(7) 163,164,162,151,156
	BYTE	(7) 147,40,163,151,172
	BYTE	(7) 145,40,145,170,143
	BYTE	(7) 145,145,144,145,144
	BYTE	(7) 40,40,40,45,144
	BYTE	(7) 55,45,144,12,45
	BYTE	(7) 163,12,0

parse2:
	PUSH 17,[0]
	ADJSP 17,1
$44::
	AOS 3,-1(17)
	ADJBP 3,[1100,,string*$$ONE-1]
	LDB 6,3
	MOVEM 6,0(17)
	JUMPE 6,$45
	CAIN 6,50
	 JRST $47
	CAIN 6,12
	 PUSHJ 17,newcas
	JRST $44
$47::
	PUSH 17,-1(17)
	PUSHJ 17,parcas
	ADJSP 17,-1
	JRST $44
$45::
	ADJSP 17,-2
	POPJ 17,
newcas:
	AOS 5,rln
	MOVE 4,rpg
	IMULI 4,70
	CAMLE 5,4
	 AOS 3,rpg
	POPJ 17,
parcas:
	MOVE 5,-1(17)
	SUBI 5,2
	PUSH 17,5
	ADJBP 5,[331100,,string]
	LDB 4,5
	CAIN 4,40
	 SOS 3,0(17)
	PUSH 17,[0]
	ADJSP 17,1
$50::
	MOVE 4,-2(17)
	ADJBP 4,[331100,,string]
	LDB 5,4
	CAIE 5,12
	 JRST $51
	SOS 3,-2(17)
	AOS 6,-1(17)
	JRST $50
$51::
	PUSH 17,-2(17)
	PUSHJ 17,getkey
	ADJSP 17,-1
	MOVEM 1,0(17)
	JUMPE 1,$52
	XMOVEI 3,statke
	PUSH 17,3
	PUSH 17,1
	PUSHJ 17,lookup
	ADJSP 17,-2
	JUMPGE 1,$52
	PUSH 17,-4(17)
	PUSH 17,-2(17)
	PUSH 17,-2(17)
	PUSHJ 17,found
	ADJSP 17,-3
$52::
	ADJSP 17,-3
	POPJ 17,
getkey:
	PUSH 17,[16]
	ADJSP 17,1
$53::
	SKIPGE 4,-3(17)
	 JRST $54
	SOS 3,-3(17)
	ADJBP 3,[221100,,string]
	LDB 6,3
	MOVEM 6,0(17)
	CAIL 6,141
	 CAILE 6,172
	 TRNA 
	 JRST $56
	CAIL 6,101
	 CAILE 6,132
	 CAIN 6,137
	 JRST $56
	CAIL 6,60
	 CAILE 6,71
	 JRST $55
$56::
	SKIPLE 4,-1(17)
	 JRST $59
	MOVEI 3,16
	MOVEM 3,-1(17)
	SETOB 5,-3(17)
	JRST $53
$59::
	MOVE 4,0(17)
	SOS 3,-1(17)
	ADJBP 3,[331100,,key]
	DPB 4,3
	JRST $53
$55::
	SETOB 3,-3(17)
	JRST $53
$54::
	MOVE 1,-1(17)
	CAIL 1,16
	 JRST $61
	XMOVEI 3,key
	IOR 3,$BYTE
	ADJBP 1,3
	ADJSP 17,-2
	POPJ 17,
$61::
	SETZ 1,
	ADJSP 17,-2
	POPJ 17,
found:
	PUSH 17,-1(17)
	XMOVEI 3,$62
	IOR 3,$BYTE*$$ONE+4
	PUSH 17,3
	XMOVEI 4,.iob*$$ONE+5
	PUSH 17,4
	PUSHJ 17,fprint
	MOVE 4,arg
	IOR 4,$BYTE
	MOVEM 4,-2(17)
	ADJSP 17,-2
	PUSH 17,-2(17)
	PUSHJ 17,scopy
	ADJSP 17,-2
	MOVE 4,rln
	SUB 4,-2(17)
	MOVE 5,arg
	MOVEM 4,5(5)
	MOVE 6,rln
	SUB 6,-2(17)
	MOVE 7,rpg
	IMULI 7,70
	SUBI 7,70
	CAMLE 6,7
	 JRST $64
	MOVE 10,rpg
	SUBI 10,1
	MOVE 11,arg
	MOVEM 10,4(11)
	JRST $63
$64::
	MOVE 4,rpg
	MOVE 5,arg
	MOVEM 4,4(5)
$63::
	PUSH 17,-3(17)
	PUSHJ 17,whatyp
	ADJSP 17,-1
	MOVE 4,arg
	MOVEM 1,6(4)
	CAIGE 1,0
	 POPJ 17,
	PUSH 17,arg
	PUSH 17,top
	PUSHJ 17,insfun
	MOVEM 1,top
	ADJSP 17,-2
	POPJ 17,
$62::
	BYTE	(7) 106,157,165,156,144
	BYTE	(7) 72,40,42,45,163
	BYTE	(7) 42,12,0

whatyp:
	ADJSP 17,3
$66::
	AOS 3,-4(17)
	ADJBP 3,[1100,,string*$$ONE-1]
	LDB 5,3
	MOVEM 5,-2(17)
	CAIE 5,51
	 JUMPN 5,$66
	JUMPN 5,$68
	SETO 1,
	ADJSP 17,-3
	POPJ 17,
$68::
	MOVE 4,-4(17)
	ADJBP 4,[331100,,string]
	LDB 5,4
	CAIN 5,40
	 AOS 3,-4(17)
$70::
	MOVE 4,-4(17)
	ADJBP 4,[331100,,string]
	LDB 5,4
	CAIN 5,12
	 AOSA 3,-4(17)
	 SKIPA 7,-4(17)
	 JRST $70
	ADJBP 7,[331100,,string]
	LDB 10,7
	CAIE 10,173
	 JRST $73
	SETZ 1,
	ADJSP 17,-3
	POPJ 17,
$73::
	SETZB 3,-1(17)
	MOVEI 4,1
	MOVEM 4,0(17)
$74::
	MOVE 10,-1(17)
	CAILE 10,16
	 JRST $75
	AOS 3,-4(17)
	ADJBP 3,[1100,,string*$$ONE-1]
	LDB 7,3
	MOVEM 7,-2(17)
	CAIE 7,40
	 CAIN 7,12
	 TRNA 
	 JUMPN 7,$77
	SETZ 5,
	ADJBP 10,[331100,,key]
	DPB 5,10
	MOVEI 4,17
	MOVEM 4,-1(17)
	JRST $74
$77::
	MOVEI 3,141
	CAMLE 3,-2(17)
	 JRST $78
	MOVE 7,-2(17)
	CAILE 7,172
	 JRST $78
	MOVE 6,-1(17)
	CAIL 6,16
	 JRST $78
	AOS 4,-1(17)
	ADJBP 4,[1100,,key*$$ONE-1]
	DPB 7,4
	JRST $74
$78::
	SETZB 3,0(17)
	MOVEI 4,17
	MOVEM 4,-1(17)
	JRST $74
$75::
	SKIPE 4,0(17)
	 JRST $79
	MOVEI 1,1
	ADJSP 17,-3
	POPJ 17,
$79::
	XMOVEI 3,declke
	PUSH 17,3
	XMOVEI 4,key
	IOR 4,$BYTE
	PUSH 17,4
	PUSHJ 17,lookup
	ADJSP 17,-2
	MOVEM 1,0(17)
	JUMPGE 1,$80
	MOVEI 1,1
	ADJSP 17,-3
	POPJ 17,
$80::
	SETZ 1,
	ADJSP 17,-3
	POPJ 17,
backup:
	ADJSP 17,2
	MOVE 4,ln
	MOVEM 4,rln
	MOVE 5,pg
	MOVEM 5,rpg
	MOVEI 3,23377
	MOVEM 3,0(17)
	SETZB 6,-1(17)
$81::
	MOVE 4,0(17)
	CAIL 4,23420
	 JRST $82
	AOS 3,0(17)
	ADJBP 3,[1100,,string*$$ONE-1]
	LDB 6,3
	AOS 5,-1(17)
	ADJBP 5,[1100,,string*$$ONE-1]
	DPB 6,5
	JRST $81
$82::
	SETZB 3,0(17)
$83::
	MOVE 4,0(17)
	CAMLE 4,-1(17)
	 JRST $84
	AOS 3,0(17)
	ADJBP 3,[1100,,string*$$ONE-1]
	LDB 6,3
	CAIN 6,12
	 SOS 5,rln
	JRST $83
$84::
	MOVE 4,rln
	MOVE 5,rpg
	IMULI 5,70
	SUBI 5,70
	CAMGE 4,5
	 SOS 3,rpg
	MOVE 1,-1(17)
	ADJSP 17,-2
	POPJ 17,

	$$ONE==1
	EXTERN	$BYTE
	EXTERN	.iob
	EXTERN	fgets
	EXTERN	fopen
	EXTERN	tree
	EXTERN	list
	EXTERN	f.free
	EXTERN	p
	EXTERN	top
	EXTERN	r.free
	EXTERN	q
	EXTERN	pass
	EXTERN	arg
	EXTERN	statke
	EXTERN	declke
	EXTERN	iop
	EXTERN	title
	EXTERN	head1
	EXTERN	head2
	EXTERN	string
	EXTERN	key
	EXTERN	srfile
	EXTERN	pg
	EXTERN	ln
	EXTERN	rpg
	EXTERN	rln
	EXTERN	crproc
	EXTERN	filenu
	INTERN	getkey
	INTERN	parse
	EXTERN	printf
	EXTERN	exit
	INTERN	backup
	EXTERN	getc
	EXTERN	incloc
	INTERN	parse2
	INTERN	newcas
	INTERN	parcas
	EXTERN	lookup
	INTERN	found
	EXTERN	insfun
	EXTERN	fprint
	EXTERN	scopy
	INTERN	whatyp

	LIT
	END