COMPILATION LISTING OF SEGMENT get_line_length_ Compiled by: Multics PL/I Compiler, Release 27d, of October 11, 1982 Compiled at: Honeywell LISD Phoenix, System M Compiled on: 11/04/82 1841.0 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 /* GET_LINE_LENGTH_ - subroutine to return the line length of a given 12* stream or switch. 13* 14* Written 750206 by PG from a program by the SIPB 15* Modified 801104 (election day) by JRD to use mode_string_$parse (MCR 4721) 16**/ 17 18 /* format: style3,ll122,idind30,ifthenstmt */ 19 20 get_line_length_: 21 procedure (P_stream) returns (fixed bin (17)); 22 23 declare P_stream char (*) parameter, 24 P_switch_ptr ptr parameter, 25 P_status fixed bin (35) parameter; 26 27 declare (addr, null) builtin; 28 29 declare mode_string char (512), 30 switch_ptr ptr, 31 have_code bit (1) aligned, 32 status fixed bin (35); 33 34 declare 1 mv aligned like mode_value; 35 36 declare error_table_$action_not_performed 37 fixed bin (35) external; 38 39 declare mode_string_$get_mode entry (char (*), char (*), ptr, fixed bin (35)); 40 1 1 /* --------------- BEGIN include file iox_dcls.incl.pl1 --------------- */ 1 2 1 3 /* Written 05/04/78 by C. D. Tavares */ 1 4 /* Fixed declaration of iox_$find_iocb_n 05/07/80 by R. Holmstedt */ 1 5 1 6 dcl iox_$attach_name entry (char (*), pointer, char (*), pointer, fixed bin (35)), 1 7 iox_$attach_ptr entry (pointer, char (*), pointer, fixed bin (35)), 1 8 iox_$close entry (pointer, fixed bin (35)), 1 9 iox_$control entry (pointer, char (*), pointer, fixed bin (35)), 1 10 iox_$delete_record entry (pointer, fixed bin (35)), 1 11 iox_$destroy_iocb entry (pointer, fixed bin (35)), 1 12 iox_$detach_iocb entry (pointer, fixed bin (35)), 1 13 iox_$err_not_attached entry options (variable), 1 14 iox_$err_not_closed entry options (variable), 1 15 iox_$err_no_operation entry options (variable), 1 16 iox_$err_not_open entry options (variable), 1 17 iox_$find_iocb entry (char (*), pointer, fixed bin (35)), 1 18 iox_$find_iocb_n entry (fixed bin, ptr, fixed bin(35)), 1 19 iox_$get_chars entry (pointer, pointer, fixed bin (21), fixed bin (21), fixed bin (35)), 1 20 iox_$get_line entry (pointer, pointer, fixed bin (21), fixed bin (21), fixed bin (35)), 1 21 iox_$look_iocb entry (char (*), pointer, fixed bin (35)), 1 22 iox_$modes entry (pointer, char (*), char (*), fixed bin (35)), 1 23 iox_$move_attach entry (pointer, pointer, fixed bin (35)), 1 24 iox_$open entry (pointer, fixed bin, bit (1) aligned, fixed bin (35)), 1 25 iox_$position entry (pointer, fixed bin, fixed bin (21), fixed bin (35)), 1 26 iox_$propagate entry (pointer), 1 27 iox_$put_chars entry (pointer, pointer, fixed bin (21), fixed bin (35)), 1 28 iox_$read_key entry (pointer, char (256) varying, fixed bin (21), fixed bin (35)), 1 29 iox_$read_length entry (pointer, fixed bin (21), fixed bin (35)), 1 30 iox_$read_record entry (pointer, pointer, fixed bin (21), fixed bin (21), fixed bin (35)), 1 31 iox_$rewrite_record entry (pointer, pointer, fixed bin (21), fixed bin (35)), 1 32 iox_$seek_key entry (pointer, char (256) varying, fixed bin (21), fixed bin (35)), 1 33 iox_$write_record entry (pointer, pointer, fixed bin (21), fixed bin (35)) ; 1 34 1 35 dcl (iox_$user_output, 1 36 iox_$user_input, 1 37 iox_$user_io, 1 38 iox_$error_output) external static pointer; 1 39 1 40 /* ---------------- END include file iox_dcls.incl.pl1 ---------------- */ 41 42 2 1 /* BEGIN INCLUDE FILE mode_string_info.incl.pl1 */ 2 2 2 3 /* Structure for parse_mode_string_ JRDavis 20 October 1980 2 4* Last modified 12 January 1981 by J. Spencer Love for version 2, make char_value varying string */ 2 5 2 6 declare mode_value_ptr ptr, 2 7 number_of_modes fixed bin; 2 8 2 9 declare 1 mode_string_info aligned based (mode_string_info_ptr), 2 10 2 version fixed bin, 2 11 2 number fixed bin, 2 12 2 modes (number_of_modes refer (mode_string_info.number)) like mode_value; 2 13 2 14 declare mode_string_info_ptr ptr; 2 15 2 16 declare 1 mode_value aligned based (mode_value_ptr), 2 17 2 version fixed bin, 2 18 2 mode_name char (32) unaligned, 2 19 2 flags, 2 20 3 boolean_valuep bit (1) unaligned, 2 21 3 numeric_valuep bit (1) unaligned, 2 22 3 char_valuep bit (1) unaligned, 2 23 3 boolean_value bit (1) unaligned, 2 24 3 pad1 bit (32) unaligned, 2 25 2 numeric_value fixed bin (35), 2 26 2 char_value char (32) varying, 2 27 2 code fixed bin (35), 2 28 2 pad2 bit (36); 2 29 2 30 declare mode_string_info_version_2 fixed bin static options (constant) initial (2), 2 31 mode_value_version_3 fixed bin static options (constant) initial (3); 2 32 2 33 /* END INCLUDE FILE mode_string_info.incl.pl1 */ 43 44 45 /* get_line_length_: 46* procedure (P_stream) returns (fixed bin (17)); */ 47 48 have_code = "0"b; 49 goto STREAM_JOIN; 50 51 get_line_length_$stream: 52 entry (P_stream, P_status) returns (fixed bin (17)); 53 54 have_code = "1"b; 55 56 57 STREAM_JOIN: 58 if P_stream = "" 59 then switch_ptr = iox_$user_output; 60 else do; 61 call iox_$look_iocb (P_stream, switch_ptr, status); 62 if status ^= 0 then go to RETURN_CODE; 63 end; 64 65 go to JOIN; 66 67 68 get_line_length_$switch: 69 entry (P_switch_ptr, P_status) returns (fixed bin (17)); 70 71 have_code = "1"b; 72 switch_ptr = P_switch_ptr; 73 if switch_ptr = null () then switch_ptr = iox_$user_output; 74 75 JOIN: 76 call iox_$modes (switch_ptr, "", mode_string, status); 77 if status ^= 0 then go to RETURN_CODE; 78 79 mv.version = mode_value_version_3; 80 call mode_string_$get_mode (mode_string, "ll", addr (mv), status); 81 if status ^= 0 then goto RETURN_CODE; 82 83 if ^mv.numeric_valuep then goto RETURN_NO_ACTION; 84 85 if have_code then P_status = 0; 86 87 return (mv.numeric_value); 88 89 RETURN_NO_ACTION: 90 status = error_table_$action_not_performed; 91 92 RETURN_CODE: 93 if have_code then P_status = status; 94 95 return (72); /* return default line length (policy decision) */ 96 97 end get_line_length_; SOURCE FILES USED IN THIS COMPILATION. LINE NUMBER DATE MODIFIED NAME PATHNAME 0 11/04/82 1631.5 get_line_length_.pl1 >dumps>old>recomp>get_line_length_.pl1 41 1 07/22/80 1335.1 iox_dcls.incl.pl1 >ldd>include>iox_dcls.incl.pl1 43 2 03/19/81 1206.8 mode_string_info.incl.pl1 >ldd>include>mode_string_info.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. P_status parameter fixed bin(35,0) dcl 23 set ref 51 68 85* 92* P_stream parameter char unaligned dcl 23 set ref 20 51 57 61* P_switch_ptr parameter pointer dcl 23 ref 68 72 addr builtin function dcl 27 ref 80 80 error_table_$action_not_performed 000010 external static fixed bin(35,0) dcl 36 ref 89 flags 11 000304 automatic structure level 2 dcl 34 have_code 000302 automatic bit(1) dcl 29 set ref 48* 54* 71* 85 92 iox_$look_iocb 000014 constant entry external dcl 1-6 ref 61 iox_$modes 000016 constant entry external dcl 1-6 ref 75 iox_$user_output 000020 external static pointer dcl 1-35 ref 57 73 mode_string 000100 automatic char(512) unaligned dcl 29 set ref 75* 80* mode_string_$get_mode 000012 constant entry external dcl 39 ref 80 mode_value based structure level 1 dcl 2-16 mode_value_version_3 constant fixed bin(17,0) initial dcl 2-30 ref 79 mv 000304 automatic structure level 1 dcl 34 set ref 80 80 null builtin function dcl 27 ref 73 numeric_value 12 000304 automatic fixed bin(35,0) level 2 dcl 34 set ref 87 numeric_valuep 11(01) 000304 automatic bit(1) level 3 packed unaligned dcl 34 set ref 83 status 000303 automatic fixed bin(35,0) dcl 29 set ref 61* 62 75* 77 80* 81 89* 92 switch_ptr 000300 automatic pointer dcl 29 set ref 57* 61* 72* 73 73* 75* version 000304 automatic fixed bin(17,0) level 2 dcl 34 set ref 79* NAMES DECLARED BY DECLARE STATEMENT AND NEVER REFERENCED. iox_$attach_name 000000 constant entry external dcl 1-6 iox_$attach_ptr 000000 constant entry external dcl 1-6 iox_$close 000000 constant entry external dcl 1-6 iox_$control 000000 constant entry external dcl 1-6 iox_$delete_record 000000 constant entry external dcl 1-6 iox_$destroy_iocb 000000 constant entry external dcl 1-6 iox_$detach_iocb 000000 constant entry external dcl 1-6 iox_$err_no_operation 000000 constant entry external dcl 1-6 iox_$err_not_attached 000000 constant entry external dcl 1-6 iox_$err_not_closed 000000 constant entry external dcl 1-6 iox_$err_not_open 000000 constant entry external dcl 1-6 iox_$error_output external static pointer dcl 1-35 iox_$find_iocb 000000 constant entry external dcl 1-6 iox_$find_iocb_n 000000 constant entry external dcl 1-6 iox_$get_chars 000000 constant entry external dcl 1-6 iox_$get_line 000000 constant entry external dcl 1-6 iox_$move_attach 000000 constant entry external dcl 1-6 iox_$open 000000 constant entry external dcl 1-6 iox_$position 000000 constant entry external dcl 1-6 iox_$propagate 000000 constant entry external dcl 1-6 iox_$put_chars 000000 constant entry external dcl 1-6 iox_$read_key 000000 constant entry external dcl 1-6 iox_$read_length 000000 constant entry external dcl 1-6 iox_$read_record 000000 constant entry external dcl 1-6 iox_$rewrite_record 000000 constant entry external dcl 1-6 iox_$seek_key 000000 constant entry external dcl 1-6 iox_$user_input external static pointer dcl 1-35 iox_$user_io external static pointer dcl 1-35 iox_$write_record 000000 constant entry external dcl 1-6 mode_string_info based structure level 1 dcl 2-9 mode_string_info_ptr automatic pointer dcl 2-14 mode_string_info_version_2 internal static fixed bin(17,0) initial dcl 2-30 mode_value_ptr automatic pointer dcl 2-6 number_of_modes automatic fixed bin(17,0) dcl 2-6 NAMES DECLARED BY EXPLICIT CONTEXT. JOIN 000155 constant label dcl 75 ref 65 RETURN_CODE 000256 constant label dcl 92 ref 62 77 81 RETURN_NO_ACTION 000253 constant label dcl 89 ref 83 STREAM_JOIN 000062 constant label dcl 57 ref 49 get_line_length_ 000016 constant entry external dcl 20 get_line_length_$stream 000042 constant entry external dcl 51 get_line_length_$switch 000127 constant entry external dcl 68 THERE WERE NO NAMES DECLARED BY CONTEXT OR IMPLICATION. STORAGE REQUIREMENTS FOR THIS PROGRAM. Object Text Link Symbol Defs Static Start 0 0 422 444 265 432 Length 656 265 22 176 134 0 BLOCK NAME STACK SIZE TYPE WHY NONQUICK/WHO SHARES STACK FRAME get_line_length_ 256 external procedure is an external procedure. STORAGE FOR AUTOMATIC VARIABLES. STACK FRAME LOC IDENTIFIER BLOCK NAME get_line_length_ 000100 mode_string get_line_length_ 000300 switch_ptr get_line_length_ 000302 have_code get_line_length_ 000303 status get_line_length_ 000304 mv get_line_length_ THE FOLLOWING EXTERNAL OPERATORS ARE USED BY THIS PROGRAM. call_ext_out_desc return ext_entry ext_entry_desc THE FOLLOWING EXTERNAL ENTRIES ARE CALLED BY THIS PROGRAM. iox_$look_iocb iox_$modes mode_string_$get_mode THE FOLLOWING EXTERNAL VARIABLES ARE USED BY THIS PROGRAM. error_table_$action_not_performed iox_$user_output LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC 20 000012 48 000034 49 000035 51 000036 54 000060 57 000062 61 000076 62 000120 65 000122 68 000123 71 000137 72 000141 73 000145 75 000155 77 000202 79 000204 80 000206 81 000237 83 000241 85 000244 87 000250 89 000253 92 000256 95 000262 ----------------------------------------------------------- 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