COMPILATION LISTING OF SEGMENT ascevl_ Compiled by: Multics PL/I Compiler, Release 31a, of October 12, 1988 Compiled at: Honeywell Bull, Phoenix AZ, SysM Compiled on: 10/17/88 1008.3 mst Mon Options: optimize map 1 /****^ *********************************************************** 2* * * 3* * Copyright, (C) Honeywell Bull Inc., 1988 * 4* * * 5* * Copyright, (C) Honeywell Information Systems Inc., 1982 * 6* * * 7* * Copyright (c) 1972 by Massachusetts Institute of * 8* * Technology and Honeywell Information Systems, Inc. * 9* * * 10* *********************************************************** */ 11 12 13 /* ASCEVL_ - program to evaluate the ACI, ACC, and BCI pseudo-ops. 14* Returns the converted string and word count, and next break. */ 15 16 ascevl_$accevl: 17 procedure (rslts) returns (fixed binary); 18 19 /* Modified 3/6/77 by NIM to implement ac4 pseudo-op. 20* Modified 740830 by PG to allow optional length field to specify padding. Program was rewritten. 21* Modified on 01/15/73 at 01:59:12 by R F Mabee. 22* by R F Mabee on 15 January 1973 to add BCD strings. 23* by R F Mabee on 16 August 1972 to fix some bugs in listing ACC statements. 24* by RHG on 23 Sept 1970 to call inputs_$ascii_literal */ 25 26 /* PARAMETERS */ 27 28 declare rslts (42) fixed binary (35) parameter; 29 30 /* BUILTINS */ 31 32 declare (addr, bin, bit, ceil, copy, divide, floor, hbound, length, mod, substr) builtin; 33 34 /* EXTERNAL ENTRIES CALLED BY ASCEVL */ 35 36 declare inputs_$next external entry, 37 inputs_$ascii_literal external entry, 38 inputs_$nxtnb external entry, 39 varevl_ entry (fixed bin (26), fixed bin (26), fixed bin (26), fixed bin (26), fixed bin (26), 40 fixed bin (26)) returns (fixed bin (26)); 41 42 /* AUTOMATIC DATA USED BY ASCEVL */ 43 44 declare (pad_length, pad_start, delta, n_words, max_length, out, chars_per_word) fixed bin; 45 declare quote fixed binary (35); 46 declare (acc_type, too_long) bit (1) aligned; 47 declare (basno, value, admod, b29, iaddr) fixed bin (26); 48 declare string_ptr ptr; 49 50 /* BASED STRUCTURES */ 51 52 declare ascii (1:168) based (string_ptr) unaligned bit (9), 53 ascii_string char (168) based (string_ptr) unaligned, 54 bcd (1:252) based (string_ptr) unaligned bit (6), 55 bcd_string bit (252*6) based (string_ptr) unaligned, 56 asc4 bit (42*36) based (string_ptr) unaligned; 57 58 /* EXTERNAL DATA */ 59 60 declare eb_data_$bcd_table (0:127) external unaligned bit (6); 61 62 /* INCLUDE FILES FOR ASCEVL */ 63 1 1 /* Begin include file varcom.incl.pl1. */ 1 2 /* RHG added new variables 9/7/70. */ 1 3 /* RFM added new cells for new object segment format and first-reference trap, 27 March 1972. */ 1 4 /* RFM added include file stuff, then cross referencer stuff, 23 July 1972. */ 1 5 /* Last modified on 07/23/72 at 04:19:25 by R F Mabee. */ 1 6 1 7 declare 1 eb_data_$varcom external aligned, 1 8 2 (brk(2), nbrk(2), sym(8), dsym(8),old_locsym, pc, spc, tpc, 1 9 pclst, p2pcl, old_ndpcls, tvorg, tvcnt, tvlth, litorg, 1 10 litc, deforg, defc, defcnt, stkc, lnkc, lnkno, 1 11 litlst, old_ndltls, lnklst, old_ndlkls, explst, blklst, namlst, 1 12 trplst, xdflst, tvlst, begin_line, tpass1, tpass2, tpostp, 1 13 tinhib, tmmode, txonly, tmm2, txo2, tprot, tcall, 1 14 tmvdef, tpulnk, tfatal, calrho, lreter, passwd, binlin, 1 15 nboxes, box(0:210), myfil, mynam, myblk, mylnk, tpost1 ) fixed bin (26) , 1 16 2 source_printed bit(1) aligned, 1 17 2 (ndpcls, ndltls, ndlkls, ndtvls) ptr, 1 18 2 (basno, value, admod, b29, iaddr, symlnk ) fixed bin (26), 1 19 2 (itxtmod, ilnkmod, entrieslc, include_file_list, include_index, 1 20 first_ref_trap_proc_linkno, first_ref_trap_arg_linkno, 1 21 text_section_length) fixed binary (26), 1 22 2 (include_info_stack, include_name_list_base, include_name_list_top) pointer, 1 23 2 symbol_tree_rel fixed binary (26); 1 24 1 25 /* End of the include file varcom.incl.pl1. */ 64 2 1 2 2 2 3 2 4 /* include file for CONCOM */ 2 5 2 6 declare 1 eb_data_$concom ext aligned, 2 7 2 (ap, ab, bp, bb, lp, lb, sp, sb, 2 8 clunk, clint, clext, clbas, clstk, clndx, clmlc, fdef, 2 9 fmul, fphs, fset, frel, fabs, fbol, fcom, find, 2 10 flocrf, fequrf, fbolrf, fsetrf, fbasrf, fsegrf, fstkrf, fndxrf, 2 11 fmlcrf, onesev, twosev, thrsev, forsev, fivsev, sixsev, allsev, 2 12 symbas(8),mir, mri, mdu, mdl, mx0, mx1, mpc, 2 13 mpci, mfi, mits, mitb, ixtern, intern, iassgn, iserch, 2 14 ixvrvl, ixvrvp, invrvl, invrvp, ibvrvl, ibvrvp, iaccvl, iacivl, 2 15 mcmpq, mcmpx0, mldaq, mldq, mldx0, mnopdu, mstcd, mtra, 2 16 mtnc, mtnz, meabsp, meapap, meapbp, meaplp, meapsp, mstpap, 2 17 mstpbp, mstplp, mstpsp, i1542, i642, i3333, i66, ibb, 2 18 ibsp, nullf, smxer(2), sentry(2),sretrn(2), dzero(2) ) fixed bin (26) aligned ; 2 19 2 20 /* end of the include file for CONCOM */ 65 3 1 3 2 3 3 3 4 /* include file for CODTAB */ 3 5 3 6 declare 1 eb_data_$codtab ext aligned, 3 7 2 ( inul, isoh, istx, ietx, ieot, ienq, iack, ibel, 3 8 ibs, iht, inl, ivt, iff, icr, irrs, ibrs, 3 9 idle, irht, ihlf, irvt, ihlr, inak, isyn, ietb, 3 10 ican, iem, iss, iesc, ifs, igs, irs, ius, 3 11 isp, ixclm, iquot, ilb, idolr, ipcnt, iampr, iapos, 3 12 ilpar, irpar, istar, iplus, icomma, iminus, ipoint, islash, 3 13 inum, inum_pad(9), icol, isc, ilpb, iequal, irpb, iques, iat, 3 14 ilet, ilet_pad(25), ilsb, irslsh, irsb, icflx, iulin, igrv, illet,illet_pad(25), 3 15 ilbrc, ivlin, irbrc, itldf, idel ) fixed bin (17) ; 3 16 /* NA on June 26, 1970 at 1344 for padded arrays */ 66 4 1 4 2 /* Last modified by EBush on 2/5/81 to add prnta */ 4 3 4 4 4 5 declare 1 eb_data_$erflgs ext aligned, 4 6 2 flgvec (36) fixed bin (17) aligned ; 4 7 4 8 4 9 declare 1 eb_data_$erflgs_overlay ext aligned, /* overlays the FLGVEC */ 4 10 2 (prnte, prntf, prntm, prntn, prnto, prntp, 4 11 prntr, prnts, prntt, prntu, prntx, prntb, 4 12 prntc, prntd, prnta, prnt5, prnt6, prnt7, 4 13 tstsw(18) ) fixed bin (17) aligned ; 4 14 4 15 67 68 69 /* program */ 70 71 /* ACC pseudo-op. */ 72 chars_per_word = 4; 73 max_length = hbound (ascii (*), 1); 74 acc_type = "1"b; 75 go to begin; 76 77 ascevl_$acievl: /* ACI pseudo-op. */ 78 entry (rslts) returns (fixed binary); 79 chars_per_word = 4; 80 max_length = hbound (ascii (*), 1); 81 acc_type = "0"b; 82 go to begin; 83 84 ascevl_$ac4evl: /* AC4 pseudo-op. */ 85 entry (rslts) returns (fixed binary); 86 chars_per_word = 8; 87 max_length = divide (length (asc4), 4.5, 17, 0); 88 acc_type = "0"b; 89 go to begin; 90 91 ascevl_$bcdevl: /* BCI pseudo-op. */ 92 entry (rslts) returns (fixed binary); 93 chars_per_word = 6; 94 max_length = hbound (bcd (*), 1); 95 acc_type = "0"b; 96 97 begin: 98 too_long = "0"b; 99 100 if acc_type then 101 out = 2; 102 else 103 out = 1; /* skip over count position if acc */ 104 105 string_ptr = addr (rslts); /* where to store chars */ 106 107 call inputs_$nxtnb; 108 quote = brk (2); /* use the actual ASCII character as the bounding character in binary */ 109 110 do while ("1"b); 111 call inputs_$ascii_literal; /* get next character */ 112 if brk (2) = quote then do; /* if termination character */ 113 call inputs_$next; /* get next character */ 114 if brk (2) ^= quote then do; /* two termination chars in a row means insert one of them */ 115 116 /* check for optional length field. */ 117 if brk (1) = icomma then do; 118 if (varevl_ (invrvl, basno, value, admod, b29, iaddr) = 0) then 119 go to undefined_symbol_error; 120 121 if iaddr ^= 0 then 122 go to lc_error; 123 124 if value > max_length then do; 125 too_long = "1"b; 126 value = max_length; 127 end; 128 129 delta = value - out + 1; 130 131 if delta < 0 then 132 too_long = "1"b; 133 else if delta > 0 then do; /* avoid stupid IPR fault */ 134 if chars_per_word = 4 then 135 substr (ascii_string, out, delta) = " "; 136 else if chars_per_word = 6 then 137 substr (bcd_string, 6 * out - 5, 6 * delta) = copy ("20"b3, delta); 138 else do; 139 pad_start = floor (out * 4.5) - 3; 140 pad_length = ceil (value * 4.5) + 1 - pad_start; 141 substr (asc4, pad_start, pad_length) = "0"b; 142 end; 143 out = out + delta; 144 end; 145 end; 146 error_return: 147 n_words = divide (out - 1 + chars_per_word - 1, chars_per_word, 18, 0); 148 delta = chars_per_word * n_words - out + 1; 149 150 if delta > 0 then /* avoid IPR fault */ 151 if chars_per_word = 4 then 152 substr (ascii_string, out, delta) = (3) ""; /* \000 */ 153 else if chars_per_word = 6 then 154 substr (bcd_string, 6 * out - 5, 6 * delta) = (30)"0"b; 155 else 156 substr (asc4, floor (out * 4.5) - 3, floor (4.5 * delta)) = "0"b; 157 158 if acc_type then 159 ascii (1) = bit (bin (out - 2, 9), 9); 160 161 if too_long then 162 prnte = 1; 163 164 return (n_words); 165 end; 166 end; 167 168 if out > max_length then 169 too_long = "1"b; 170 else do; 171 if chars_per_word = 4 then /* put this char in result string */ 172 ascii (out) = bit (bin (brk (2), 9), 9); 173 else if chars_per_word = 6 then 174 bcd (out) = eb_data_$bcd_table (brk (2)); 175 else do; 176 pad_start = ceil (out * 4.5) - 3; 177 if mod (out, 2) ^= 0 then 178 substr (asc4, pad_start - 1, 1) = "0"b; 179 substr (asc4, pad_start, 4) = substr (unspec (brk (2)), 33, 4); 180 end; 181 out = out + 1; 182 end; 183 end; 184 185 lc_error: 186 prnte = 1; 187 go to error_return; 188 189 undefined_symbol_error: 190 prntu = 1; 191 go to error_return; 192 193 end ascevl_$accevl; SOURCE FILES USED IN THIS COMPILATION. LINE NUMBER DATE MODIFIED NAME PATHNAME 0 10/17/88 0938.0 ascevl_.pl1 >spec>install>1170>ascevl_.pl1 64 1 10/21/74 1242.9 varcom.incl.pl1 >ldd>include>varcom.incl.pl1 65 2 10/21/74 1243.0 concom.incl.pl1 >ldd>include>concom.incl.pl1 66 3 05/06/74 1741.0 codtab.incl.pl1 >ldd>include>codtab.incl.pl1 67 4 07/17/81 1911.5 erflgs.incl.pl1 >ldd>include>erflgs.incl.pl1 NAMES DECLARED IN THIS COMPILATION. IDENTIFIER OFFSET LOC STORAGE CLASS DATA TYPE ATTRIBUTES AND REFERENCES (* indicates a set context) NAMES DECLARED BY DECLARE STATEMENT. acc_type 000110 automatic bit(1) dcl 46 set ref 74* 81* 88* 95* 100 158 addr builtin function dcl 32 ref 105 admod 000114 automatic fixed bin(26,0) dcl 47 set ref 118* asc4 based bit(1512) packed unaligned dcl 52 set ref 87 141* 155* 177* 179* ascii based bit(9) array packed unaligned dcl 52 set ref 73 80 158* 171* ascii_string based char(168) packed unaligned dcl 52 set ref 134* 150* b29 000115 automatic fixed bin(26,0) dcl 47 set ref 118* basno 000112 automatic fixed bin(26,0) dcl 47 set ref 118* bcd based bit(6) array packed unaligned dcl 52 set ref 94 173* bcd_string based bit(1512) packed unaligned dcl 52 set ref 136* 153* bin builtin function dcl 32 ref 158 171 bit builtin function dcl 32 ref 158 171 brk 000022 external static fixed bin(26,0) array level 2 dcl 1-7 ref 108 112 114 117 171 173 179 ceil builtin function dcl 32 ref 140 176 chars_per_word 000106 automatic fixed bin(17,0) dcl 44 set ref 72* 79* 86* 93* 134 136 146 146 148 150 153 171 173 copy builtin function dcl 32 ref 136 delta 000102 automatic fixed bin(17,0) dcl 44 set ref 129* 131 133 134 136 136 143 148* 150 150 153 155 divide builtin function dcl 32 ref 87 146 eb_data_$bcd_table 000020 external static bit(6) array packed unaligned dcl 60 ref 173 eb_data_$codtab 000026 external static structure level 1 dcl 3-6 eb_data_$concom 000024 external static structure level 1 dcl 2-6 eb_data_$erflgs_overlay 000030 external static structure level 1 dcl 4-9 eb_data_$varcom 000022 external static structure level 1 dcl 1-7 floor builtin function dcl 32 ref 139 155 155 hbound builtin function dcl 32 ref 73 80 94 iaddr 000116 automatic fixed bin(26,0) dcl 47 set ref 118* 121 icomma 54 000026 external static fixed bin(17,0) level 2 dcl 3-6 ref 117 inputs_$ascii_literal 000012 constant entry external dcl 36 ref 111 inputs_$next 000010 constant entry external dcl 36 ref 113 inputs_$nxtnb 000014 constant entry external dcl 36 ref 107 invrvl 101 000024 external static fixed bin(26,0) level 2 dcl 2-6 set ref 118* length builtin function dcl 32 ref 87 max_length 000104 automatic fixed bin(17,0) dcl 44 set ref 73* 80* 87* 94* 124 126 168 mod builtin function dcl 32 ref 177 n_words 000103 automatic fixed bin(17,0) dcl 44 set ref 146* 148 164 out 000105 automatic fixed bin(17,0) dcl 44 set ref 100* 102* 129 134 136 139 143* 143 146 148 150 153 155 158 168 171 173 176 177 181* 181 pad_length 000100 automatic fixed bin(17,0) dcl 44 set ref 140* 141 pad_start 000101 automatic fixed bin(17,0) dcl 44 set ref 139* 140 141 176* 177 179 prnte 000030 external static fixed bin(17,0) level 2 dcl 4-9 set ref 161* 185* prntu 11 000030 external static fixed bin(17,0) level 2 dcl 4-9 set ref 189* quote 000107 automatic fixed bin(35,0) dcl 45 set ref 108* 112 114 rslts parameter fixed bin(35,0) array dcl 28 set ref 16 77 84 91 105 string_ptr 000120 automatic pointer dcl 48 set ref 73 80 87 94 105* 134 136 141 150 153 155 158 171 173 177 179 substr builtin function dcl 32 set ref 134* 136* 141* 150* 153* 155* 177* 179* 179 too_long 000111 automatic bit(1) dcl 46 set ref 97* 125* 131* 161 168* value 000113 automatic fixed bin(26,0) dcl 47 set ref 118* 124 126* 129 140 varevl_ 000016 constant entry external dcl 36 ref 118 NAME DECLARED BY DECLARE STATEMENT AND NEVER REFERENCED. eb_data_$erflgs external static structure level 1 dcl 4-5 NAMES DECLARED BY EXPLICIT CONTEXT. ascevl_$ac4evl 000045 constant entry external dcl 84 ascevl_$accevl 000012 constant entry external dcl 16 ascevl_$acievl 000030 constant entry external dcl 77 ascevl_$bcdevl 000065 constant entry external dcl 91 begin 000077 constant label dcl 97 ref 75 82 89 error_return 000302 constant label dcl 146 ref 187 191 lc_error 000503 constant label dcl 185 ref 121 undefined_symbol_error 000507 constant label dcl 189 ref 118 NAME DECLARED BY CONTEXT OR IMPLICATION. unspec builtin function ref 179 STORAGE REQUIREMENTS FOR THIS PROGRAM. Object Text Link Symbol Defs Static Start 0 0 710 742 520 720 Length 1204 520 32 225 167 0 BLOCK NAME STACK SIZE TYPE WHY NONQUICK/WHO SHARES STACK FRAME ascevl_$accevl 100 external procedure is an external procedure. STORAGE FOR AUTOMATIC VARIABLES. STACK FRAME LOC IDENTIFIER BLOCK NAME ascevl_$accevl 000100 pad_length ascevl_$accevl 000101 pad_start ascevl_$accevl 000102 delta ascevl_$accevl 000103 n_words ascevl_$accevl 000104 max_length ascevl_$accevl 000105 out ascevl_$accevl 000106 chars_per_word ascevl_$accevl 000107 quote ascevl_$accevl 000110 acc_type ascevl_$accevl 000111 too_long ascevl_$accevl 000112 basno ascevl_$accevl 000113 value ascevl_$accevl 000114 admod ascevl_$accevl 000115 b29 ascevl_$accevl 000116 iaddr ascevl_$accevl 000120 string_ptr ascevl_$accevl THE FOLLOWING EXTERNAL OPERATORS ARE USED BY THIS PROGRAM. call_ext_out return_mac mdfx1 shorten_stack ext_entry ceil_fx1 floor_fx1 repeat set_bits_eis divide_fx1 THE FOLLOWING EXTERNAL ENTRIES ARE CALLED BY THIS PROGRAM. inputs_$ascii_literal inputs_$next inputs_$nxtnb varevl_ THE FOLLOWING EXTERNAL VARIABLES ARE USED BY THIS PROGRAM. eb_data_$bcd_table eb_data_$codtab eb_data_$concom eb_data_$erflgs_overlay eb_data_$varcom LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC 16 000006 72 000017 73 000021 74 000023 75 000025 77 000026 79 000035 80 000037 81 000041 82 000042 84 000043 86 000052 87 000054 88 000061 89 000062 91 000063 93 000072 94 000074 95 000076 97 000077 100 000100 102 000105 105 000107 107 000112 108 000117 110 000123 111 000124 112 000131 113 000136 114 000142 117 000147 118 000153 121 000200 124 000202 125 000205 126 000207 129 000211 131 000214 133 000220 134 000221 136 000233 138 000256 139 000257 140 000265 141 000273 143 000300 146 000302 148 000310 150 000321 153 000334 155 000350 158 000365 161 000402 164 000407 168 000413 171 000421 173 000440 176 000455 177 000463 179 000474 181 000501 183 000502 185 000503 187 000506 189 000507 191 000513 ----------------------------------------------------------- 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