" " Begin include file ...... readtape.incl.alm " Created 9/15/75 by Noel I. Morris readtape: stx2 rtx2 subr to read one log record stx1 rtx1 save XR's ldx6 tbufi buffer offset in X6 ldx7 tbufd compute lth of data left in buffer sbx7 tbufi .. tpnz *+2 if empty, tsx2 tfill refill the buffer lda tbuf,6 get control word sta kind save it eax1 0,al X1 contains data length eax7 -1,7 decrement remaining length eax6 1,6 increment offset trlp: cmpx7 0,du buffer empty? tpnz *+2 if so, tsx2 tfill fill it stx1 tlrl save length to xfer eaa 0,7 remaining buffer length in AU cmpa tlrl compare against desired length tmoz *+2 take min lda tlrl to get number of words to move sta trlen save length to xfer this time eaq 0,6 buffer offset in QU lls 2 compute char offset and length mlr (rl,qu),(pr,rl) move data desc9a tbuf,au desc9a tmp|0,au adwp1 trlen bump data pointer adx6 trlen bump buffer offset sbx7 trlen decrement remaining buffer length sbx1 trlen decrement remaining data length tpnz trlp loop if more data to move stx6 tbufi save buffer offset rtxit: epbp1 tmp|0 set pointer back to base of buffer seg rtx2: eax2 * restore XR's rtx1: eax1 * .. tra 0,2 return to caller " tfill: stx2 tfx2 save X2 stx0 tfx0 and X0 aos recno bump number trbuf: stz thdr here to get new buffer stz thdr+7 reset known words ldx6 ttlr get pointer to trailer stz 0,6 clear trailer words stz 7,6 .. tsx2 xio_wait read record vfd 18/thdr,12/tbufl+16,6/0 zero tapeno,5 tra *-3 retry if error lda thdr check known words ldq thdr+7 cmpaq tkw tnz trbuf lda thdr+5 check for end of tape record cana eor,du tnz eot cana admin,du ignore administrative records tnz trbuf ldq thdr+4 get # of data bits in record div 36,dl compute # of words stcq tbufd,70 save word count eax6 tbuf,ql X6 points to record trailer stx6 ttlr save trailer pointer lda 0,6 check known words of trailer ldq 7,6 .. cmpaq tkw+2 tnz trbuf ldi ovflm,dl turn overflow mask on lda =0,dl clear A eax6 thdr X6 first points to record header eax7 1 X7 is shift count odd; rpda 6,1 add up header words awca 0,6 .. alr 0,7 .. awca 1,6 skip checksum word alr 0,7 ldx6 ttlr X6 now points to record trailer odd; rpda 8,1 add up trailer words awca 0,6 .. alr 0,7 .. awca 0,dl add any last carry cmpa thdr+6 check it tnz trbuf ldx6 ttlr X6 -> record trailer lda 6,6 check recno cmpa recno tze *+3 tpl tback too high, backup tra trbuf too low, read more ldx7 tbufd buffer length in X7 eax6 0 buffer offset in X6 tfx2: eax2 * restore XR's tfx0: eax0 * .. tra 0,2 return tback: szn tapdev reading on cold MPC? tnz tapfatal if so, incapable of backspacing eax0 10 here if too far down tape backup: tsx2 xio_wait zero zero tapeno,38 backspace tra *+1 ignore errors eax0 -1,0 tpl backup tra trbuf now, try here on tape eot: lca 1,dl all one's in A sta kind set end of tape indication ldx0 tfx0 restore X0 tra rtxit and exit tapfatal: tsx2 erpt acc 'cannot reposition tape, reboot bos.' dis * tra -1,ic " kind: oct 0 logical record ID recno: oct 0 physical record number tbufd: bss ,1 data length of tape record tbufi: bss ,1 offset into tape buffer tlrl: bss ,1 length of logical record trlen: bss ,1 number of words to move ttlr: arg tbuf+tbufl pointer to tape record trailer tapeno: bss ,1 tape channel and device tapdev: bss ,1 non-zero if cold tape MPC even tkw: oct 670314355245,512556146073,107463422532,265221631704 bool eor,100000 bool admin,600000 equ tbufl,1024 eight thdr: bss ,8 tbuf: bss ,tbufl bss ,8 " End of include file ...... readtape.incl.alm " " " ----------------------------------------------------------- " " " " Historical Background " " This edition of the Multics software materials and documentation is provided and donated " to Massachusetts Institute of Technology by Group Bull including Bull HN Information Systems Inc. " as a contribution to computer science knowledge. " This donation is made also to give evidence of the common contributions of Massachusetts Institute of Technology, " Bell Laboratories, General Electric, Honeywell Information Systems Inc., Honeywell Bull Inc., Groupe Bull " and Bull HN Information Systems Inc. to the development of this operating system. " Multics development was initiated by Massachusetts Institute of Technology Project MAC (1963-1970), " renamed the MIT Laboratory for Computer Science and Artificial Intelligence in the mid 1970s, under the leadership " of Professor Fernando Jose Corbato. Users consider that Multics provided the best software architecture for " managing computer hardware properly and for executing programs. Many subsequent operating systems " incorporated Multics principles. " Multics was distributed in 1975 to 2000 by Group Bull in Europe , and in the U.S. by Bull HN Information Systems Inc., " as successor in interest by change in name only to Honeywell Bull Inc. and Honeywell Information Systems Inc. . " " ----------------------------------------------------------- " " Permission to use, copy, modify, and distribute these programs and their documentation for any purpose and without " fee is hereby granted,provided that the below copyright notice and historical background appear in all copies " and that both the copyright notice and historical background and this permission notice appear in supporting " documentation, and that the names of MIT, HIS, Bull or Bull HN not be used in advertising or publicity pertaining " to distribution of the programs without specific prior written permission. " Copyright 1972 by Massachusetts Institute of Technology and Honeywell Information Systems Inc. " Copyright 2006 by Bull HN Information Systems Inc. " Copyright 2006 by Bull SAS " All Rights Reserved " "