COMPILATION LISTING OF SEGMENT compile_link Compiled by: Multics PL/I Compiler, Release 28d, of September 14, 1983 Compiled at: Honeywell LCPD Phoenix, System M Compiled on: 10/03/83 1627.7 mst Mon 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 /* Procedure to generate a link 12* 13* Modified: 16 October 1972 by BLW for standard object segment 14* Modified: 1 June 1976 by RAB for *system links */ 15 16 compile_link: proc(string,grow,type) returns(fixed bin(18)); 17 18 dcl string char(*) aligned, 19 grow bit(18) aligned, 20 type fixed bin(15); 21 22 dcl (def_pos,link_pos,n) fixed bin(18), 23 (p,def_ptr,def_reloc_ptr,link_ptr,link_reloc_ptr) ptr, 24 (block_type,seg_name,ent_name) bit(18) aligned; 25 26 dcl (cg_static_$def_base,cg_static_$link_base, 27 cg_static_$def_reloc_base,cg_static_$link_reloc_base) ptr ext, 28 cg_static_$zero_def bit(18) ext, 29 cg_static_$use_type_6 bit(1) ext, 30 (cg_static_$def_pos,cg_static_$link_pos) fixed bin(18) ext; 31 32 dcl name_assign entry(char(*) aligned) returns(bit(18) aligned), 33 reserve$read_lib entry(fixed bin(15)) returns(ptr); 34 35 dcl (addrel,fixed,index,length,substr) builtin; 36 37 dcl word(0:2) bit(36) aligned based; 38 39 dcl reloc(0:2) bit(36) aligned based; 40 41 dcl address fixed bin(35) based; 42 43 dcl 1 fault_pair aligned based, 44 2 unused unal bit(30), 45 2 tag unal bit(6); 46 1 1 /* BEGIN INCLUDE FILE ... token.incl.pl1 */ 1 2 1 3 dcl 1 token based aligned, 1 4 2 node_type bit(9) unaligned, 1 5 2 type bit(9) unaligned, 1 6 2 loc bit(18) unaligned, /* symtab offset for identifiers, "p" flag for constants */ 1 7 2 declaration ptr unaligned, 1 8 2 next ptr unaligned, 1 9 2 size fixed(9), 1 10 2 string char(n refer(token.size)); 1 11 1 12 /* END INCLUDE FILE ... token.incl.pl1 */ 47 2 1 /* BEGIN INCLUDE FILE relbts.incl.pl1 */ 2 2 2 3 /* This include file defines the relocation bits as bit (18) entities. See 2 4* also relocation_bits.incl.pl1 and reloc_lower.incl.pl1. */ 2 5 2 6 dcl ( rc_a initial("0"b), /* absolute */ 2 7 rc_t initial("000000000000010000"b), /* text */ 2 8 rc_nt initial("000000000000010001"b), /* negative text */ 2 9 rc_lp18 initial("000000000000010010"b), /* linkage, 18 bit */ 2 10 rc_nlp18 initial("000000000000010011"b), /* negative link, 18 bit */ 2 11 rc_lp15 initial("000000000000010100"b), /* linkage, 15 bit */ 2 12 rc_dp initial("000000000000010101"b), /* def section */ 2 13 rc_s initial("000000000000010110"b), /* symbol segment */ 2 14 rc_ns initial("000000000000010111"b), /* negative symbol */ 2 15 rc_is18 initial("000000000000011000"b), /* internal static 18 */ 2 16 rc_is15 initial("000000000000011001"b), /* internal static 15 */ 2 17 rc_lb initial("000000000000011000"b), /* link block */ 2 18 rc_nlb initial("000000000000011001"b), /* negative link block */ 2 19 rc_sr initial("000000000000011010"b), /* self relative */ 2 20 rc_e initial("000000000000011111"b)) /* escape */ 2 21 bit(18) internal static options(constant); 2 22 2 23 dcl ( rc_dp_dp initial("000000000000010101000000000000010101"b), /* def section, def section */ 2 24 rc_a_dp initial("000000000000000000000000000000010101"b)) /* absolute, def section */ 2 25 bit(36) internal static options(constant); 2 26 2 27 /* END INCLUDE FILE relbts.incl.pl1 */ 48 49 50 n = index(string,"$"); 51 52 if n = length(string) 53 then do; 54 55 /* have seg_name$ */ 56 57 ent_name = cg_static_$zero_def; 58 seg_name = name_assign(substr(string,1,length(string)-1)); 59 60 if grow then block_type = "000000000000000110"b; 61 else block_type = "000000000000000011"b; 62 63 end; 64 else do; 65 66 if grow 67 then if cg_static_$use_type_6 68 then block_type = "000000000000000110"b; 69 else block_type = "000000000000000101"b; 70 else block_type = "000000000000000100"b; 71 72 if n = 0 73 then do; 74 75 /* no $ in external name */ 76 77 if type = 0 then seg_name, ent_name = name_assign(string); 78 else do; 79 80 if block_type = "000000000000000110"b 81 then do; 82 83 /* name is stat_$alpha format */ 84 85 p = reserve$read_lib(2); 86 seg_name = name_assign(p -> token.string); 87 end; 88 89 else do; 90 91 /* have *system link */ 92 93 seg_name = "000000000000000101"b; 94 end; 95 96 ent_name = name_assign(string); 97 98 end; 99 end; 100 else do; 101 102 /* have a$b form of name */ 103 104 seg_name = name_assign(substr(string,1,n-1)); 105 ent_name = name_assign(substr(string,n+1)); 106 107 end; 108 end; 109 110 def_pos = cg_static_$def_pos; 111 def_ptr = addrel(cg_static_$def_base,def_pos); 112 def_reloc_ptr = addrel(cg_static_$def_reloc_base,def_pos); 113 114 link_pos = cg_static_$link_pos; 115 link_ptr = addrel(cg_static_$link_base,link_pos); 116 link_reloc_ptr = addrel(cg_static_$link_reloc_base,link_pos); 117 118 def_ptr -> word(0) = block_type || grow; 119 if grow then def_reloc_ptr -> reloc(0) = rc_a_dp; 120 121 def_ptr -> word(1) = seg_name || ent_name; 122 def_reloc_ptr -> reloc(1) = rc_dp_dp; 123 124 def_ptr -> word(2) = bit(def_pos,18); 125 def_reloc_ptr -> reloc(2) = rc_dp; 126 127 link_ptr -> address = -link_pos * 262144; /* put in left half of word */ 128 link_ptr -> fault_pair.tag = "100110"b; /* fi mod = 46 octal */ 129 link_reloc_ptr -> reloc(0) = rc_nlb; 130 131 link_ptr -> word(1) = bit(fixed(def_pos+2,18),18); 132 link_reloc_ptr -> reloc(1) = rc_dp; 133 134 cg_static_$def_pos = def_pos + 3; 135 cg_static_$link_pos = link_pos + 2; 136 137 return(link_pos); 138 end; SOURCE FILES USED IN THIS COMPILATION. LINE NUMBER DATE MODIFIED NAME PATHNAME 0 10/03/83 1008.0 compile_link.pl1 >spec>on>pl128d>compile_link.pl1 47 1 09/14/77 1705.7 token.incl.pl1 >ldd>include>token.incl.pl1 48 2 10/30/80 1648.7 relbts.incl.pl1 >ldd>include>relbts.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. addrel builtin function dcl 35 ref 111 112 115 116 address based fixed bin(35,0) dcl 41 set ref 127* block_type 000116 automatic bit(18) dcl 22 set ref 60* 61* 66* 69* 70* 80 118 cg_static_$def_base 000010 external static pointer dcl 26 ref 111 cg_static_$def_pos 000024 external static fixed bin(18,0) dcl 26 set ref 110 134* cg_static_$def_reloc_base 000014 external static pointer dcl 26 ref 112 cg_static_$link_base 000012 external static pointer dcl 26 ref 115 cg_static_$link_pos 000026 external static fixed bin(18,0) dcl 26 set ref 114 135* cg_static_$link_reloc_base 000016 external static pointer dcl 26 ref 116 cg_static_$use_type_6 000022 external static bit(1) unaligned dcl 26 ref 66 cg_static_$zero_def 000020 external static bit(18) unaligned dcl 26 ref 57 def_pos 000100 automatic fixed bin(18,0) dcl 22 set ref 110* 111 112 124 131 134 def_ptr 000106 automatic pointer dcl 22 set ref 111* 118 121 124 def_reloc_ptr 000110 automatic pointer dcl 22 set ref 112* 119 122 125 ent_name 000120 automatic bit(18) dcl 22 set ref 57* 77* 96* 105* 121 fault_pair based structure level 1 dcl 43 fixed builtin function dcl 35 ref 131 grow parameter bit(18) dcl 18 ref 16 60 66 118 119 index builtin function dcl 35 ref 50 length builtin function dcl 35 ref 52 58 58 link_pos 000101 automatic fixed bin(18,0) dcl 22 set ref 114* 115 116 127 135 137 link_ptr 000112 automatic pointer dcl 22 set ref 115* 127 128 131 link_reloc_ptr 000114 automatic pointer dcl 22 set ref 116* 129 132 n 000102 automatic fixed bin(18,0) dcl 22 set ref 50* 52 72 104 104 105 105 name_assign 000030 constant entry external dcl 32 ref 58 77 86 96 104 105 p 000104 automatic pointer dcl 22 set ref 85* 86 rc_a_dp constant bit(36) initial unaligned dcl 2-23 ref 119 rc_dp constant bit(18) initial unaligned dcl 2-6 ref 125 132 rc_dp_dp 000000 constant bit(36) initial unaligned dcl 2-23 ref 122 rc_nlb constant bit(18) initial unaligned dcl 2-6 ref 129 reloc based bit(36) array dcl 39 set ref 119* 122* 125* 129* 132* reserve$read_lib 000032 constant entry external dcl 32 ref 85 seg_name 000117 automatic bit(18) dcl 22 set ref 58* 77* 86* 93* 104* 121 size 3 based fixed bin(9,0) level 2 dcl 1-3 ref 86 86 string 4 based char level 2 in structure "token" dcl 1-3 in procedure "compile_link" set ref 86* string parameter char dcl 18 in procedure "compile_link" set ref 16 50 52 58 58 58 58 77* 96* 104 104 105 105 substr builtin function dcl 35 ref 58 58 104 104 105 105 tag 0(30) based bit(6) level 2 packed unaligned dcl 43 set ref 128* token based structure level 1 dcl 1-3 type parameter fixed bin(15,0) dcl 18 ref 16 77 word based bit(36) array dcl 37 set ref 118* 121* 124* 131* NAMES DECLARED BY DECLARE STATEMENT AND NEVER REFERENCED. rc_a internal static bit(18) initial unaligned dcl 2-6 rc_e internal static bit(18) initial unaligned dcl 2-6 rc_is15 internal static bit(18) initial unaligned dcl 2-6 rc_is18 internal static bit(18) initial unaligned dcl 2-6 rc_lb internal static bit(18) initial unaligned dcl 2-6 rc_lp15 internal static bit(18) initial unaligned dcl 2-6 rc_lp18 internal static bit(18) initial unaligned dcl 2-6 rc_nlp18 internal static bit(18) initial unaligned dcl 2-6 rc_ns internal static bit(18) initial unaligned dcl 2-6 rc_nt internal static bit(18) initial unaligned dcl 2-6 rc_s internal static bit(18) initial unaligned dcl 2-6 rc_sr internal static bit(18) initial unaligned dcl 2-6 rc_t internal static bit(18) initial unaligned dcl 2-6 NAME DECLARED BY EXPLICIT CONTEXT. compile_link 000014 constant entry external dcl 16 NAME DECLARED BY CONTEXT OR IMPLICATION. bit builtin function ref 124 131 STORAGE REQUIREMENTS FOR THIS PROGRAM. Object Text Link Symbol Defs Static Start 0 0 550 604 421 560 Length 1014 421 34 174 127 0 BLOCK NAME STACK SIZE TYPE WHY NONQUICK/WHO SHARES STACK FRAME compile_link 96 external procedure is an external procedure. STORAGE FOR AUTOMATIC VARIABLES. STACK FRAME LOC IDENTIFIER BLOCK NAME compile_link 000100 def_pos compile_link 000101 link_pos compile_link 000102 n compile_link 000104 p compile_link 000106 def_ptr compile_link 000110 def_reloc_ptr compile_link 000112 link_ptr compile_link 000114 link_reloc_ptr compile_link 000116 block_type compile_link 000117 seg_name compile_link 000120 ent_name compile_link THE FOLLOWING EXTERNAL OPERATORS ARE USED BY THIS PROGRAM. alloc_cs call_ext_out_desc call_ext_out return shorten_stack ext_entry_desc THE FOLLOWING EXTERNAL ENTRIES ARE CALLED BY THIS PROGRAM. name_assign reserve$read_lib THE FOLLOWING EXTERNAL VARIABLES ARE USED BY THIS PROGRAM. cg_static_$def_base cg_static_$def_pos cg_static_$def_reloc_base cg_static_$link_base cg_static_$link_pos cg_static_$link_reloc_base cg_static_$use_type_6 cg_static_$zero_def LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC 16 000007 50 000027 52 000042 57 000044 58 000046 60 000073 61 000103 63 000105 66 000106 69 000116 70 000121 72 000123 77 000125 80 000150 85 000152 86 000164 87 000205 93 000206 96 000210 99 000227 104 000230 105 000254 107 000306 110 000307 111 000312 112 000316 114 000322 115 000324 116 000330 118 000334 119 000342 121 000347 122 000357 124 000361 125 000366 127 000370 128 000373 129 000375 131 000377 132 000406 134 000410 135 000413 137 000416 ----------------------------------------------------------- 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