COMPILATION LISTING OF SEGMENT cv_mode_ Compiled by: Multics PL/I Compiler, Release 27d, of October 11, 1982 Compiled at: Honeywell LISD Phoenix, System M Compiled on: 11/04/82 1756.2 mst Thu Options: optimize map 1 /* *********************************************************** 2* * * 3* * Copyright, (C) Honeywell Information Systems Inc., 1982 * 4* * * 5* * Copyright (c) 1972 by Massachusetts Institute of * 6* * Technology and Honeywell Information Systems, Inc. * 7* * * 8* *********************************************************** */ 9 10 11 cv_mode_: procedure (chars, bits, code); 12 13 14 /* 15* 16* This procedure converts standard mode characters (rew, null, n) 17* into the corresponding binary attribute string as found in an acl 18* entry. Mode characters in the input string may be in any order, 19* and embedded blanks are ignored. If the string is "null" or "n", 20* "0"b is returned. 21* 22* P. Bos, May 1972 23* 24* Modified by Peter B. Kelley, Apr. 26, 1973 to implement new ACL/RB primitives. 25* Effect of change was to change "trewa" modes to "rewa" modes. 26* Modified by P. B. Kelley, Jun. 1973 to ignore "a" _s_e_g_m_e_n_t mode representation. 27* -added entry cv_dir_mode_ and associated mode representations. 28* 29**/ 30 31 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ 32 33 34 dcl chars char(*), /* input string ("rew", "null", "n") */ 35 bits bit(*), /* binary mode corresponding to chars */ 36 code fixed bin(35); /* status code for bad mode */ 37 38 dcl (addr, length, null) builtin; 39 40 dcl error_table_$bad_acl_mode ext fixed bin(35); 41 42 dcl (bp, cp, mp) ptr; 43 44 dcl (i, j, l) fixed bin; 45 46 dcl mode bit(3) aligned; /* internal temp for "bits" */ 47 48 dcl chr char(1) aligned; 49 50 dcl 1 s aligned int static, 51 2 mchr (3) char(1) init ("r", "e", "w"); 52 53 dcl 1 d aligned int static, 54 2 mchr (3) char(1) init ("s", "m", "a"); 55 56 dcl 1 M aligned based (mp), 57 2 mchr (3) char(1); 58 59 dcl 1 b based (bp), /* bit array */ 60 2 bit(3) bit(1) unal; 61 62 dcl 1 c based (cp), /* char array */ 63 2 char(l) char(1) unal; 64 65 /* */ 66 67 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ 68 69 70 mp = addr(s); /* point to segment modes */ 71 goto COMMON; 72 73 cv_dir_mode_: entry (chars, bits, code); 74 75 mp = addr(d); /* point to directory modes */ 76 77 COMMON: 78 code = 0; /* reset status code */ 79 bits, 80 mode = ""b; /* zero return string and bit temporary */ 81 bp = addr (mode); /* used to reference string as bit array */ 82 cp = addr (chars); /* .. char array */ 83 if chars ^= "null" then if chars ^= "n" then do; /* chars is real mode specification */ 84 l = length (chars); /* get length of input string */ 85 do i = 1 to l; /* scan char by char */ 86 chr = c.char(i); /* copy char for efficiency */ 87 if chr = " " then /* ignore blanks */ 88 go to next; /* get next char */ 89 do j = 1 to 3; /* search mode char table */ 90 if chr = mp->M.mchr(j) then do; /* found char in table? */ 91 b.bit(j) = "1"b; /* yes, set corresponding bit in mode string */ 92 go to next; /* go get next char */ 93 end; 94 end; 95 code = error_table_$bad_acl_mode; /* illegal character in mode specification */ 96 return; /* return with bits = "0"b */ 97 next: end; 98 bits = mode; /* give mode string to user */ 99 end; 100 return; /* finis */ 101 102 end cv_mode_; SOURCE FILES USED IN THIS COMPILATION. LINE NUMBER DATE MODIFIED NAME PATHNAME 0 11/04/82 1624.4 cv_mode_.pl1 >dumps>old>recomp>cv_mode_.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. M based structure level 1 dcl 56 addr builtin function dcl 38 ref 70 75 81 82 b based structure level 1 packed unaligned dcl 59 bit based bit(1) array level 2 packed unaligned dcl 59 set ref 91* bits parameter bit unaligned dcl 34 set ref 11 73 79* 98* bp 000100 automatic pointer dcl 42 set ref 81* 91 c based structure level 1 packed unaligned dcl 62 char based char(1) array level 2 packed unaligned dcl 62 ref 86 chars parameter char unaligned dcl 34 set ref 11 73 82 83 83 84 chr 000112 automatic char(1) dcl 48 set ref 86* 87 90 code parameter fixed bin(35,0) dcl 34 set ref 11 73 77* 95* cp 000102 automatic pointer dcl 42 set ref 82* 86 d 000013 internal static structure level 1 dcl 53 set ref 75 error_table_$bad_acl_mode 000016 external static fixed bin(35,0) dcl 40 ref 95 i 000106 automatic fixed bin(17,0) dcl 44 set ref 85* 86* j 000107 automatic fixed bin(17,0) dcl 44 set ref 89* 90 91* l 000110 automatic fixed bin(17,0) dcl 44 set ref 84* 85 length builtin function dcl 38 ref 84 mchr based char(1) array level 2 dcl 56 ref 90 mode 000111 automatic bit(3) dcl 46 set ref 79* 81 98 mp 000104 automatic pointer dcl 42 set ref 70* 75* 90 s 000010 internal static structure level 1 dcl 50 set ref 70 NAME DECLARED BY DECLARE STATEMENT AND NEVER REFERENCED. null builtin function dcl 38 NAMES DECLARED BY EXPLICIT CONTEXT. COMMON 000060 constant label dcl 77 ref 71 cv_dir_mode_ 000035 constant entry external dcl 73 cv_mode_ 000010 constant entry external dcl 11 next 000152 constant label dcl 97 ref 87 92 THERE WERE NO NAMES DECLARED BY CONTEXT OR IMPLICATION. STORAGE REQUIREMENTS FOR THIS PROGRAM. Object Text Link Symbol Defs Static Start 0 0 232 252 164 242 Length 414 164 20 125 46 6 BLOCK NAME STACK SIZE TYPE WHY NONQUICK/WHO SHARES STACK FRAME cv_mode_ 78 external procedure is an external procedure. STORAGE FOR INTERNAL STATIC VARIABLES. LOC IDENTIFIER BLOCK NAME 000010 s cv_mode_ 000013 d cv_mode_ STORAGE FOR AUTOMATIC VARIABLES. STACK FRAME LOC IDENTIFIER BLOCK NAME cv_mode_ 000100 bp cv_mode_ 000102 cp cv_mode_ 000104 mp cv_mode_ 000106 i cv_mode_ 000107 j cv_mode_ 000110 l cv_mode_ 000111 mode cv_mode_ 000112 chr cv_mode_ THE FOLLOWING EXTERNAL OPERATORS ARE USED BY THIS PROGRAM. return ext_entry_desc NO EXTERNAL ENTRIES ARE CALLED BY THIS PROGRAM. THE FOLLOWING EXTERNAL VARIABLES ARE USED BY THIS PROGRAM. error_table_$bad_acl_mode LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC 11 000004 70 000030 71 000032 73 000033 75 000055 77 000060 79 000062 81 000070 82 000072 83 000074 84 000106 85 000107 86 000115 87 000122 89 000125 90 000132 91 000136 92 000142 94 000143 95 000145 96 000151 97 000152 98 000154 100 000162 ----------------------------------------------------------- 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