101 001 job 1401 format retrieval 102 ctl 6611 103 size equ 15999 used to org prog in upper core 104 org 1 define fields in i/o 105 ahere ds 3 control blocks relative 106 alow ds 4 to one 107 ahigh ds 4 108 ab ds 1 109 bhere ds 3 110 blow ds 4 111 bhigh ds 4 112 bc ds 1 b and/or c, a is and, o is or *same for a,b 113 chere ds 3 units pos of c field * fields 114 clow ds 4 lowest c to be used * 115 chigh ds 4 highest c to be used * 116 status ds 1 no wm if last,zone if rd cds for a low/high 117 count ds 6 count output records 118 nxtabc ds 3 start of next i/o control block, ahere-3 119 io ds 1 start of output routine 120 * 121 org 81 122 cgm dcw @}@ 123 ds 5 124 *throughout generation, x3 is last loc assigned, called origin 125 *for processing routines 126 * x1 is start of current output block - 1 127 * x2 is start of current ahere - 1 128 * x3 is start of tape input record - 1, zero if card input 129 x1 dcw #3 130 ds 1 131 sww dc #1 wm if print gen 132 x2 dcw #3 133 ds 1 134 swp dc #1 wm if punch gen 135 x3 dcw 335 ititial origin 136 ds 1 137 org 181 138 dcw @}@ 139 recnt dcw -000000 140 noisec dcw #6 141 job generate print and punch file controls 142 org 336 143 headpg sbr hdx+3 eject 144 cc 1 145 mrcm hl1-131,201 146 a *-6,pagect page count 147 ppage nop pagect,* 148 hsp1 cc / 149 w print heading 150 mrcm hl2-131,201 151 hsp2 cc s 152 w 153 mrcm hc-131,201 clear print 154 hdx b aftil 155 dcw #1 156 hl1 ds 131 157 dcw @'@ 158 hl2 ds 132 159 dcw @'@ 160 hc ds 132 161 dcw @'@ 162 pagect dcw #4 163 * 164 fincnt dcw #6 165 seqchk dcw #9 166 ds 45 save for abc 167 coutt equ *-3 168 wi0 c seqchk-8,seqchk-8 169 be print 170 bwz print,recnt,k q. first record 171 wi1 mcw *,* reset sequence 172 wi2 nop coutt,* move count to print area 173 a coutt,fincnt 174 s coutt 175 wi3 nop pagect reset page count 176 nop print total line 177 wi4 nop coutt,* clear print area 178 wi5 nop headpg 179 swtot b print+5 180 print bcv headpg 181 * 182 orgsze equ size-999 183 orgsz2 equ orgsze-999 184 org orgsz2-189 185 setwm b * end sw string 186 doset sbr setwm+3 187 b 1+x2 188 starti cc 1 189 mrcm 76,276 identify program and version 190 mlc cprog,274 191 cc t 192 w read 193 c 6,chead1 q. head 194 be genh 195 cs print+4 196 cs 197 cs 198 cs 199 cs 200 cs 201 cs 202 b qpunch 203 genh sw 7 204 mcw 76,hl1-62 store 1-70 205 b read 206 c 6,chead2 207 be *+6 208 nop 1111 head 2 missing 209 h 210 sw 7,72 211 mcw 68,hl1 store 71-132 212 bce *+19,71, q. page ct 213 sw 69 214 mcw 71,ppage+6 215 mcw cmcs,ppage 216 bce *+8,72, 217 mcw 72,hsp1+1 218 b read 219 c 6,chead3 220 bu nohl3 221 sw 7 222 mlc 76,hl2-62 223 b read 224 c 6,chead4 225 be *+6 226 nop 1112 head 4 missing 227 h 228 sw 7,72 229 mlc 68,hl2 230 bce *+8,72, 231 mlc 72,hsp2+1 232 b read 233 b qprint 234 bin hdx, 235 nohl3 sbr hsp2-4,hc-131 236 lca nohl3-1,hsp2+4 237 qprint c 5,cprint 238 be *+6 239 nop 1114 no print after head 240 h 241 sbr x3,seqchk up origin 242 b ldabc 243 bce notot,f3, q. totals 244 mcw f3,wi2+6 245 mcw f3,wi4+6 246 mcw cmcs,wi2 247 mcw cmcs,wi4 248 mcw cw 249 notot bce noseq,f1, q. sequence check 250 mz cb,f1-1 251 mcw f1,wi0+3 252 sbr x1,seqchk-9 253 mn f2-2,*+7 254 sbr wi0+6,0+x1 255 sbr wi1+6 256 mcw f1,wi1+3 257 bce noseq,f4-2, q. space after break 258 bce ej,f4-2,1 259 lca cnn,wi5+3 set cc x, nop x 260 mcw f4-2 261 lca ccc 262 b noseq 263 ej mcw cb,wi5 264 bce *+8,f4-1, q. reset page count 265 mcw cs,wi3 266 noseq sbr x3,print+4 up origin 267 b getdv 268 b doset 269 bce *+22,f2-1, q. space after print 270 mcw f2-1,2+x3 271 mlcwaccc,1+x3 272 sbr x3,2+x3 273 sbr 12+x3,pass 274 lca cb,9+x3 275 lca clrp+6 276 mlcwacw 277 sbr x3,12+x3 278 sw 1+x3,sww print sw on 279 * 280 qpunch c 5,cpunch 281 bu clrjnk q. punch 282 b ldabc 283 b getdv 284 b doset 285 lca cp,1+x3 286 bce nstack,f1-2, q. stacker selection 287 mcw f1-2,6+x3 288 sbr 5+x3,pass 289 lca css,2+x3 290 sbr x3,6+x3 291 b *+15 292 nstack sbr 4+x3,pass 293 sbr x3,4+x3 294 sw swp,1+x3 punch sw on 295 b qpunch 296 clrp mrcm hc-131,201 297 ccc dcw @f@ 298 chead1 dcw @head 1@ 299 chead2 dcw @head 2@ 300 chead3 dcw @head 3@ 301 chead4 dcw @head 4@ 302 cmcs mcs 303 cnn dcw @nn@ 304 cp p 305 cprint dcw @print@ 306 cprog dcw @program@ 307 cpunch dcw @punch@ 308 css ss 309 cw w 310 clrjnk cs * done with print/punch 311 cs clear routines 312 cs 313 cs 314 cs 315 cs 316 cs 317 cs 318 cw p print or punch switch off 319 sbr getdv+10,*+4 new start for sw in mcw 320 clrjk3 b clrjk2 321 job generate tape output file controls 322 * this is upper limit of user generated output routines 323 b tup 324 * hold must be in core for generation and initp 325 hold dcw #1 *hold file definition 326 dc #43 * 327 f1 dcw #3 * 328 f2 dcw #3 * 329 f3 dcw #3 * 330 f4 dcw #3 * 331 dc #25 * 332 clrjk2 cs clrjk3+3 333 cs 334 * 335 qtypef bce readn,1,r read 336 bce end,1,e end 337 bce title,2,i title 338 bce tapen,1,t tapen 339 nop 2111 card type error 340 h 341 * 342 *generated tape output routines, sample 343 * ds 45 a,b,c control 344 wtape2 sbr x1 ,* * is record to fill - 1 345 * *,* 346 * *,* generated move commands 347 * *,* 348 bce wtape,0+1+x1,} q. end block, 0 is rec lng 349 sbr wtape2+6 ??? set to next block 350 b pass 351 dcw 2 352 std dcw #5 blockcount 353 *write area follows with 's, gm, and wms 354 * 355 * 356 tapen b ldabc load abc for tape file 3562 mn hold+4,*+4 3564 rwd 2 357 lca wtape2+3,4+x3 358 sbr whrwt2+3,7+x3 sbr x1,* 359 sbr x3 360 b getdv 361 whrwt2 sbr *,22+x3 362 mlcwastd 363 mlcwa 364 lca 365 lca 366 lca 367 mn hold+4,17+x3 370 mcw whrwt2+3,12+x3 move sbr wtape2+6 371 mn f1,tup+6 372 mn 373 mlc 374 a *-6,f1 375 mn f1,7+x3 376 mn 377 mlc 378 sbr x3,22+x3 379 qblock s c1,f2 380 bwz orc,f2,k 381 b 1+x2 382 tup sbr x3,0+x3 383 mlc crm 384 b qblock 385 orc sbr x3,1+x3 386 lca cgm end of tape output file gen 387 b qtypef 388 job data move generation and misc control cards 389 readn mrcm 1,hold 390 bwz *+5,5,2 q. tape input 391 b nolab 392 mn 5,*+4 393 rwd 1 rewind input tape 394 bce nolab,51, q. tape label 395 mn 5,*+4 396 rt 1,201 read tape label 397 ber taperr 398 w 399 mrcm 101,201 400 nolab mrcm highm-28,260 401 sbr x3,1+x3 402 sbr 293,0+x3 403 w 404 mrcm 130,260 405 astatu sbr x1,* no wm in last status 406 cw 0+x1 407 fabc sbr 9+x1,* first abc 408 sbr x2 initialize for processing 409 b read 410 b qtypef 411 * 412 title bce *+6,6,1 413 nop 2121 first title not 1 414 h 415 mrcm 7,201 416 r 417 c 6,ctit 418 be *+6 419 nop 2122 title 2 missing 420 h 421 lca cgm,69 422 mrcm 7,271 423 cc 1 424 wr 425 ccb headpg+6,l 426 aftil bce end2,1,e 427 nop 2124 no end after title 428 h 429 * 430 end bwz headpg,sww,1 431 end2 cs 80 432 sw 56,63 433 r 56 434 * 435 ldabc sbr ldabcx+3 436 sw 6 437 lca blk3,45+x3 438 lca blk6 load abc controls 439 lca 41 440 mrcm 1,hold hold file card 441 anxtab sbr fabc+6,0+x3 chain nxtabc 442 s x1+1 443 swabc sw 42+x1 444 s c4,42+x1 445 mn 42+x1,*+7 446 sbr x2,0+x3 447 sw 4+x2,8+x2 set wm for length abc 448 sw 1+x3 set wm for location 449 mz cb,2+x3 index for location 450 bce *+19,x1,2 451 sbr x1,1+x1 452 sbr x3,12+x3 453 b swabc 454 sw 12+x3 set wm in status 455 sbr astatu+6,12+x3 location of status 456 sbr anxtab+3,21+x3 chain nxt abc 457 sbr x3 458 ldabcx b * 459 * 460 getdv sbr getdvx+3 read and assemble moves 461 sbr x2,setwm-1 init sw string, see mcw 462 rctl b read 463 s x1+1 search table of moves for type 464 qtypem c 4,datamv+x1 465 bu *+16 466 mcw datamv+3+x1,*+8 467 s x1+1 468 b * exit to process type 469 getdvx bce *,datamv+4+x1,* exit to file assembly 470 sbr x1,7+x1 471 b qtypem 472 datamv dcw @mlc @ 473 dcw mcw 474 dcw @mlzs@ 475 dcw mz 476 dcw @mlns@ 477 dcw mn 478 dcw @bwz @ 479 dcw bwz 480 dcw @bce @ 481 dcw bce 4812 dcw @cons@ 4814 dcw const 482 dcw @core@ 483 dcw core 484 dcw @1hdr@ 485 dcw hdr 486 dcw @*@ 487 * 488 bwz mcw cbwz,op assembles 489 b *+8 490 bce mcw cb,op 491 sw 6+x1,9+x1 bwz/bce *+6,ccc+x3,d 492 sw 10+x1 b *+9 493 mcw 8+x1,20+x3 dcw @b@ 494 sbr 17+x3,13+x3 mcw *-1,aaa+x1 495 lca cmcw,14+x3 496 lca 9+x1 497 sbr 12+x3,21+x3 498 lca cb,9+x3 499 mcw 13+x1 500 sbr 4+x3,14+x3 501 lca op,1+x3 502 cbwz bwz *+8,p,1 503 mz cs,19+x3 504 mz cb,6+x3 505 sbr x3,20+x3 506 bce rctl,14+x1, 507 sbr x1,8+x1 508 b bce+7 509 * 510 core mrcm orgis,230 511 sbr 242,1+x3 print origin for patch 512 mn 8,*+9 513 mn 514 mn 515 sbr x3,0+x3 516 w 517 mrcm 130,230 518 b rctl 519 orgis dcw @o@ 520 dc @rigin is@ 521 dcw @}@ ??? gmark ??? 522 * 523 mcw sw 6+x1,9+x1 assembles 524 sw 12+x1 mcw aaa+x3,ccc+x1 525 cmcw mcw 14+x1,7+x3 526 mcw 8+x1 527 lca cmcw 528 mcw 11+x1,0+x2 generate sw string to sw in 529 lca csw each output record of block 530 sbr x2 531 bwz *+8,p,1 532 mz cb,3+x2 533 bwz *+8,p,1 534 mz cs,6+x3 535 mz cb,3+x3 536 sbr x3,7+x3 537 bce rctl,15+x1, 538 sbr x1,9+x1 539 b mcw 540 * 541 mz mcw cmz,op 542 b *+8 543 mn mcw cmn,op assembles 544 sw 6+x1 mz/mn aaa+x3,bbb+x1 545 mcw 11+x1,7+x3 546 lca op 547 bwz *+8,p,1 548 cmz mz cs,6+x3 549 mz cb,3+x3 550 sbr x3,7+x3 551 bce rctl,12+x1, 552 sbr x1,6+x1 5525 b mn+7 553 * 553aconst sw 8,11 553c mlc 7,x1 553e mlc blk3,x1-2 553g mlcwacb,1+x3 553i ma x1,x3 553k mlc 10,11+x3 553m bwz *+8,p,1 553o mlzs cs,10+x3 553q mlcwacmcw,5+x3 553s sbr 8+x3 553t mlcwa10+x1 553u sbr *+4 553w sbr *,5+x3 553y sbr x3,11+x3 5530 b rctl 554 * 555 hdr mn hold+4,*+4 556 wt 2,1 557 ber taperr 558 b rctl 559 * 560 read sbr readx+3 read and list card 561 cs 80 562 r 563 sbr x1,1 564 readm mrcm 0+x1,200+x1 565 sar x1 566 bce *+5,x1-1,8 loop if rm in card stopped move 567 b readm 568 w 569 mrcm 101,201 570 readx b * 571 * 572 blk3 dcw #3 573 blk6 dc #3 574 crm dcw @'@ 575 p dcw #1 wm while gen print/punch 576 ctit dcw @title2@ 577 c1 dcw 1 578 c4 dcw 4 579 highm dcw @ high location for output is@ 580 dcw @}@ 581 op dcw #1 bwz/bce, mn/mz for generation 582 cb b 583 cmn mn 584 cs s 585 csw sw 586 * 587 org size-98 588 taperr sbr comand+16 repeat 8 character tape 589 sbr *+4 r/w commands after error 590 c *,comand+13 591 c 592 mcw 593 mn comand+17,comand+18 594 mn comand+3,backsp+3 595 repeat a *-6,comand+18 596 c comand+18,comand+17 597 bu *+7 598 h 599 bss comand+13,g 600 backsp cu %u1,b 601 bce comand,comand+7,r 602 bl comand 603 cu %u1,e 604 comand nop *,*,* 605 ber repeat 606 b *-3 607 dcw 7 608 dcw @ @ ??? gmark ??? 609 ex starti 610 ********************************************************************* 611 * control cards here in condensed deck 612 ********************************************************************* 613 job initialize processing 614 org size-999 615 r getrec+11 constants for conversion 616 bce loadtr,1,, of get tape to read card 6165 nop 617 card mlcwa*-7,qpad9 618 chain2 619 s x3+1 621 b getrec+7 622 * 623 initp cs 80 624 bce card,hold+4,c 6245 mz *-6,abit make a-bit constant 625 mn hold+4,rtape+3 626 mn hold+4,eot1+3 627 sbr intblk+6,0+x3 628 sbr rtape+6,1+x3 set start of tape input block 629 sbr getbl3+6,13+x3 init noise test 6295 sbr getblk+6 6297 mlc abit,getbl3+7 630 a *-6,f1 631 mn f1,getrec+13 632 mn 633 mlc 634 mcw rtape+7,getbl2+7 635 mlc f3,reels save input reel count 637 s ipc1,reels 638 r 639 cs *-4 640 sbr *-4 641 bwz *-15,hold,1 642 bin getblk, 643 ipc1 dcw 1 644 job processing routines, input/output, pass/fail 645 org *+x00 6455orgpro equ * 646 dcw @}@ core protection 647 * this is upper limit of user tape input block 648 *get next record from blocked input tape 649 noise a *-6,noisec 650 getblk mlc abit,0+12 init abit for noise rec test 6505rtape rt 1,* * is read area 651 bef eot1 652 getbl3 bce noise,0+12,^ abit q. noise record 654 b *+9 655 getbl2 rt 1,* calling sequence for taperr 656 ber taperr 657 intblk sbr x3,* * is read area - 1 658 b qpad9 659 eot1 rwu 1 input reel completed 660 s prc1,reels q. all reels 661 bwz getblk,reels,b 662 loadtr sw 56,63 663 b 56 664 scan9 mcw x3,x1 first char of record was 9 665 sbr x1,1+x1 scan for all 9s 666 bce *-14,1+x1,9 667 bce getrec+7,1+x1,' yes, was padding 668 b qpad9+8 no, process 669 pass a *-6,count+x2 670 selx bw outsel,status+x2 q. last file def tested 671 getrec a *-6,recnt count last input record 672 bce getblk,0+1+x3,} q. end of blk, 0 is record lng 673 sbr x3 set to next record 674 qpad9 bce scan9,1+x3,9 q. padding 675 * 676 outsel mcw nxtabc+x2,x2 test for truth of a,b,c 6765 bce io+x2,ahere+x2, when ahere blk, accept all rec 677 mcw ahere+x2,*+4 678 c *,alow+x2 679 bh tstaf 680 mcw ahere+x2,*+4 681 c *,ahigh+x2 682 bl tstaf 683 bce io+x2,ab+x2, 684 bce tstbp,ab+x2,o 685 tstbl mcw bhere+x2,*+4 686 c *,blow+x2 687 bce tstbn,ab+x2,n 688 bh tstbf 689 mcw bhere+x2,*+4 690 c *,bhigh+x2 691 bl tstbf 692 tstbp bce io+x2,bc+x2, 693 bce io+x2,bc+x2,o 694 tstcl mcw chere+x2,*+4 695 c *,clow+x2 696 bce tstcn,bc+x2,n 697 bh fail 698 mcw chere+x2,*+4 699 c *,chigh+x2 700 bl fail 701 b io+x2 702 tstaf bce tstbl,ab+x2,o 703 bce fail,ab+x2, 704 b tstbf 705 tstbn bh tstbp 706 mlc bhere+x2,*+4 707 c *,bhigh+x2 708 bl tstbp 709 tstbf b tstcl,bc+x2,o 710 fail bwz selx,status+x2,2 711 bce selx,1,, q. end of cards 712 mcw ahere+x2,*+4 713 c *,ahigh+x2 714 bl *+5 715 b selx 716 r 717 mcw 16,ahigh+x2 718 mcw 719 b outsel+7 720 tstcn bh io+x2 721 mlc chere+x2,*+4 722 c *,chigh+x2 723 bl io+x2 724 b fail 725 * 726 *generated write and taperr must be in core for processing 727 * and for close 728 *generalized write output block 729 wtape sbr x1 730 wtapel mcw 3+x1,*+4 reset routine to fill 731 sbr *,13+x1 first record of next block 732 mcw 8+x1,*+4 drive 733 wt 2,14+x1 734 ber taperr 735 a *-6,13+x1 count tape block 736 qeot bef *+5 q. eot 737 b pass 738 mn 8+x1,*+4 739 wtm 2 tm 740 mlc 13+x1,wtcnt 741 mlc wttrl+25,13+x1 742 mn 8+x1,*+4 743 wt 2,wttrl-4 write trailer label 744 mn 8+x1,*+4 745 wtm 2 tm after trailer 746 mn 8+x1,*+4 747 rwu 2 748 wtex b pass 749 wttrl dcw @1eor @ 80 char trailer label 750 wtcnt dcw #5 751 da 1x70,g,c 752 abit dcw #1 7522prc1 dcw 1 7524reels dcw 00 753 ex initp 754 ********************************************************************* 755 * card input, when used, here 756 ********************************************************************* 757 job close files, print i/o counts 758 org orgpro 759 endprg sw qeot+4 modify wt to close file 760 mlc @f@,wttrl-1 change eor to eof 761 bss *+8,f 762 mcw cr,wtex-1 763 sbr wtex+3,qlast 764 bwz pft,sww,1 q. printed output 765 b findon+2 766 pft sbr swtot+3,*+5 switch to final total 767 b wi1 768 mlc fincnt,coutt 769 mcw wi2+6,*+7 770 nop *,* 771 w 772 findon cc 1 773 cs 332 774 cs 775 mcw cinput,250 input count 776 mcs recnt,258 777 bce *+15,noisec, 778 mlc cnoise,275 779 mcs noisec,282 780 cc t 781 w 782 cs 783 cs 784 mcw cout,255 785 cc s 786 w 787 cs 788 cs 789 pcnt mcw nxtabc+x2,x2 790 mcs count+x2,258 791 bce bt,io+x2,h q. tape file 792 qlast w 793 bwz pcnt,status+x2,1 q. last file 794 cc 1 795 bwz *+5,swp,1 796 b *+7 797 cs 180 798 p 799 p 800 r 40 806 bt mcw io+6+x2,x3 807 mcw x3,x1 808 bce *+9,0+x1,} scan backward for gm 809 sbr x1 on bce wtape,0+1+x1,gm 810 b *-15 811 sbr x1,1+x1 set x1 to point to calling seq 812 mn 8+x1,250 813 mcw ctape,248 814 bwz qeot,0+x3,2 q. no records in this block 815 fill9 mcw c9,1+x3 scan forward to gm, 816 bce *+9,2+x3,' fill 9 padding 817 sbr x3 818 b fill9 819 bce wtapel,3+x3,} q. padding complete 820 sbr x3,2+x3 821 b fill9 824 cinput dcw @input@ 825 cnoise dcw @noise rec@ 826 cout dcw @output counts@ 827 cr dcw @r@ 828 ctape dcw @tape@ 829 c9 dcw @9@ 830 ex endprg 831 job load next program or halt 8315 org orgpro 832 qeojl bss eoj,a 833 cs 80 834 sw 1 835 r 836 bce sort7,2, 837 b 1 838 *sort7 sort7 sort7 b x0k001 h x0j001 org 15951 x0k001 sw 1 cs *-4 sbr *-4 bwz x0k001+4,1,1 b *+2 dcw @ @ x0l001 rwd 1 rtw 1,1 ber x0l001 b 2701 org x0j001 839 eoj nop 2888 eoj halt 840 h 841 b eoj 842 h 843 end qeojl