COMPILATION LISTING OF SEGMENT expression_parse Compiled by: Multics PL/I Compiler, Release 33c, of October 25, 1990 Compiled at: ACTC Technologies Inc. Compiled on: 92-04-24_1116.58_Fri_mdt 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 expression_parse: 12 procedure(i,cblock) recursive returns(pointer); 13 14 15 /* Parameters */ 16 17 dcl i fixed bin(15), 18 r ptr, 19 cblock ptr; 20 21 dcl (addr,binary,fixed,index,null,search,substr) builtin; 22 23 24 /* Automatic stuff. */ 25 26 dcl (j, k, si, n) fixed bin(15), 27 (eloc,oploc) fixed bin(15), 28 ch char(1), 29 opindex fixed bin(5), 30 q ptr, 31 type bit(9) aligned, 32 (r2,r3) ptr, 33 stack(0:12) ptr; 34 35 /* Constants. */ 36 37 dcl precedence(0:18) fixed bin(15) internal static 38 initial( 0, /* illegal */ 39 5, /* +, plus */ 40 5, /* -, minus */ 41 6, /* *, asterisk */ 42 6, /* /, slash */ 43 7, /* **, expon */ 44 7, /* ^, not */ 45 2, /* &, and */ 46 1, /* |, or */ 47 4, /* ||, cat */ 48 3, /* =, eq */ 49 3, /* ^=, ne */ 50 3, /* <, lt */ 51 3, /* >, gt */ 52 3, /* <=, le */ 53 3, /* >=, ge */ 54 3, /* ^>, ngt */ 55 3, /* ^<, nlt */ 56 3); /* =, assignment */ 57 58 dcl op_table(0:18) bit(9) aligned internal static options(constant) 59 initial( ""b, /* illegal */ 60 "000010001"b, /* +, plus */ 61 "000010010"b, /* -, minus */ 62 "000010011"b, /* *, asterisk */ 63 "000010100"b, /* /, slash */ 64 "100100100"b, /* **, expon */ 65 "000100100"b, /* ^, not */ 66 "000100001"b, /* &, and */ 67 "000100010"b, /* |, or */ 68 "000100101"b, /* ||, cat */ 69 "001000110"b, /* =, eq */ 70 "001000111"b, /* ^=, ne */ 71 "001000100"b, /* <, lt */ 72 "001000101"b, /* >, gt */ 73 "001001000"b, /* <=, le */ 74 "001001001"b, /* >=, ge */ 75 "001001000"b, /* ^>, ngt */ 76 "001001001"b, /* ^<, nlt */ 77 "001000110"b); /* =, assignment ( equal relational ) */ 78 79 /* t and tlist are used to get better accessing to token_list in 80* inner procedure "primitive". */ 81 82 dcl t ptr internal static, 83 tlist(3000) ptr based(t); 84 1 1 /* BEGIN INCLUDE FILE parse.incl.pl1 */ 1 2 1 3 1 4 /****^ HISTORY COMMENTS: 1 5* 1) change(91-01-09,Blackmore), approve(91-01-09,MCR8234), 1 6* audit(91-12-05,Huen), install(92-04-24,MR12.5-1011): 1 7* Change entry points for 'lex', 'lex$write_last_line', and 1 8* 'statement_type', for constant reference resolution fix. 1 9* END HISTORY COMMENTS */ 1 10 1 11 declare attribute_parse entry(ptr,ptr,fixed bin(15),bit(1) aligned); 1 12 /* parameter 1: (input) block node ptr */ 1 13 /* parameter 2: (input) symbol node ptr */ 1 14 /* parameter 3: (in/out) token index */ 1 15 /* parameter 4: (input) called while doing generic */ 1 16 1 17 declare context entry(ptr,ptr,fixed bin(15)); 1 18 /* parameter 1: (input) usually token node ptr */ 1 19 /* parameter 2: (input) block node ptr */ 1 20 /* parameter 3: (input) context type */ 1 21 1 22 declare data_list_parse entry(fixed bin(15),ptr,ptr) 1 23 returns(bit(1) aligned); 1 24 /* parameter 1: (in/out) token index */ 1 25 /* parameter 2: (input) block node ptr */ 1 26 /* parameter 3: (output) data list parse tree ptr */ 1 27 /* return: (output) valid parse bit */ 1 28 1 29 declare declare_label entry(ptr,ptr,ptr,bit(3) aligned); 1 30 /* parameter 1: (input) block node ptr */ 1 31 /* parameter 2: (input) statement node ptr */ 1 32 /* parameter 3: (input) label list ptr or null */ 1 33 /* parameter 4: (input) declare type */ 1 34 1 35 declare declare_parse entry(fixed bin(15),ptr,ptr); 1 36 /* parameter 1: (input) token index */ 1 37 /* parameter 2: (input) block node ptr */ 1 38 /* parameter 3: (input) label list ptr or null */ 1 39 1 40 declare declare_parse$abort entry(fixed bin(15),ptr); 1 41 /* parameter 1: (input) error number */ 1 42 /* parameter 2: (input) any node ptr */ 1 43 1 44 declare default_parse entry(fixed bin(15),ptr,ptr); 1 45 /* parameter 1: (input) token index */ 1 46 /* parameter 2: (input) block node ptr */ 1 47 /* parameter 3: (input) label list ptr or null */ 1 48 1 49 declare descriptor_parse entry(ptr,ptr,fixed bin(15)) 1 50 returns(ptr); 1 51 /* parameter 1: (input) block node ptr */ 1 52 /* parameter 2: (input) token node ptr or null */ 1 53 /* parameter 3: (in/out) token index */ 1 54 /* return: (output) symbol node ptr */ 1 55 1 56 declare do_parse entry(fixed bin(15),ptr,bit(12) aligned,ptr,ptr, 1 57 bit(1) aligned,bit(1) aligned,bit(1) aligned); 1 58 /* parameter 1: (in/out) token index */ 1 59 /* parameter 2: (input) label list ptr or null */ 1 60 /* parameter 3: (input) conditions */ 1 61 /* parameter 4: (input) father block node ptr */ 1 62 /* parameter 5: (output) end ptr */ 1 63 /* parameter 6: (input) entry bit */ 1 64 /* parameter 7: (input) return bit */ 1 65 /* parameter 8: (input) iterative do bit */ 1 66 1 67 declare evaluate entry(bit(9) aligned,ptr,ptr) returns(ptr); 1 68 /* parameter 1: (input) opcode */ 1 69 /* parameter 2: (input) left operand (token ptr) */ 1 70 /* parameter 3: (input) right operand (token ptr) */ 1 71 /* return: (output) ptr to result node */ 1 72 1 73 declare expression_parse entry(fixed bin(15),ptr) 1 74 returns(ptr); 1 75 /* parameter 1: (in/out) token index */ 1 76 /* parameter 2: (input) block node ptr */ 1 77 /* return: (output) expression parse tree ptr */ 1 78 1 79 declare format_list_parse entry(fixed bin(15),ptr,ptr,ptr) 1 80 returns(bit(1) aligned); 1 81 /* parameter 1: (in/out) token index */ 1 82 /* parameter 2: (input) block node ptr */ 1 83 /* parameter 3: (input) statement node ptr */ 1 84 /* parameter 4: (output) format list parse tree ptr */ 1 85 /* return: (output) valid parse bit */ 1 86 1 87 declare if_parse entry(fixed bin(15),ptr,bit(12) aligned,ptr,ptr, 1 88 bit(1) aligned); 1 89 /* parameter 1: (in/out) token index */ 1 90 /* parameter 2: (input) label list ptr or null */ 1 91 /* parameter 3: (input) conditions */ 1 92 /* parameter 4: (input) father block node ptr */ 1 93 /* parameter 5: (input) end ptr */ 1 94 /* parameter 6: (output) valid parse bit */ 1 95 1 96 declare io_statement_parse entry(fixed bin(15),ptr,bit(12) aligned,ptr,ptr, 1 97 bit(1) aligned,bit(9) aligned); 1 98 /* parameter 1: (in/out) token index */ 1 99 /* parameter 2: (input) label list ptr or null */ 1 100 /* parameter 3: (input) conditions */ 1 101 /* parameter 4: (input) father block node ptr */ 1 102 /* parameter 5: (output) end ptr */ 1 103 /* parameter 6: (output) valid parse bit */ 1 104 /* parameter 7: (output) statement type */ 1 105 1 106 declare lex entry(ptr); 1 107 /* parameter 1: (input) block node ptr */ 1 108 1 109 declare lex$write_last_line entry(ptr); 1 110 /* parameter 1: (input) block node ptr */ 1 111 1 112 declare lex$initialize_lex entry(ptr,fixed bin(15)); 1 113 /* parameter 1: (input) ptr to source */ 1 114 /* parameter 2: (input) length of source (chars) */ 1 115 1 116 declare on_parse entry(fixed bin(15),ptr,bit(12) aligned,ptr,ptr); 1 117 /* parameter 1: (in/out) token index */ 1 118 /* parameter 2: (input) label list ptr or null */ 1 119 /* parameter 3: (input) conditions */ 1 120 /* parameter 4: (input) father block node ptr */ 1 121 /* parameter 5: (output) end ptr (set to null) */ 1 122 1 123 declare on_parse$revert entry(fixed bin(15),ptr,ptr); 1 124 /* parameter 1: (input) token index */ 1 125 /* parameter 2: (input) statement node ptr */ 1 126 /* parameter 3: (input) block node ptr */ 1 127 1 128 declare parse entry(ptr,ptr,fixed bin(15)); 1 129 /* parameter 1: (output) root ptr */ 1 130 /* parameter 2 (input) source ptr */ 1 131 /* parameter 3: (input) source length */ 1 132 1 133 declare procedure_parse entry(fixed bin(15),ptr,bit(12) aligned,ptr,ptr, 1 134 bit(9) aligned,bit(1) aligned); 1 135 /* parameter 1: (in/out) token index */ 1 136 /* parameter 2: (input) label list ptr or null */ 1 137 /* parameter 3: (input) conditions */ 1 138 /* parameter 4: (input) father block node ptr */ 1 139 /* parameter 5: (output) end ptr */ 1 140 /* parameter 6: (input) block type */ 1 141 /* parameter 7: (input) no return statement bit */ 1 142 1 143 declare process_entry entry(fixed bin(15),bit(9) aligned,ptr,ptr,bit(12) aligned); 1 144 /* parameter 1: (in/out) token index */ 1 145 /* parameter 2: (input) statement type */ 1 146 /* parameter 3: (input) block node ptr */ 1 147 /* parameter 4: (input) label list ptr or null */ 1 148 /* parameter 5: (input) conditions */ 1 149 1 150 declare reference_parse entry(fixed bin(15),ptr) 1 151 returns(ptr); 1 152 /* parameter 1: (in/out) token index */ 1 153 /* parameter 2: (input) block node ptr */ 1 154 /* return: (output) reference parse tree ptr */ 1 155 1 156 declare reserve$rename_parse entry(fixed bin(15)) returns(bit(1) aligned); 1 157 /* parameter 1: (in/out) token index */ 1 158 /* return: (output) success bit */ 1 159 1 160 declare statement_parse entry(fixed bin(15),ptr,bit(12) aligned,ptr,fixed bin(15)); 1 161 /* parameter 1: (in/out) token index */ 1 162 /* parameter 2: (input) label list ptr or null */ 1 163 /* parameter 3: (input) conditions */ 1 164 /* parameter 4: (input) block node ptr */ 1 165 /* parameter 5: (input) statement type */ 1 166 1 167 declare statement_type entry(ptr,fixed bin(15),ptr,bit(12) aligned) 1 168 returns(fixed bin(15)); 1 169 /* parameter 1: (input) block node ptr */ 1 170 /* parameter 2: (in/out) token index */ 1 171 /* parameter 3: (output) label list ptr or null */ 1 172 /* parameter 4: (output) conditions */ 1 173 /* return: (output) statement type */ 1 174 2 1 /****^ ********************************************************* 2 2* * * 2 3* * Copyright, (C) BULL HN Information Systems Inc., 1989 * 2 4* * * 2 5* ********************************************************* */ 2 6 2 7 /* BEGIN INCLUDE FILE ... language_utility.incl.pl1 */ 2 8 2 9 2 10 /****^ HISTORY COMMENTS: 2 11* 1) change(89-07-10,RWaters), approve(89-07-10,MCR8118), audit(89-07-19,Vu), 2 12* install(89-07-31,MR12.3-1066): 2 13* Removed the obsolete parameter source_line from the dcl of error_(). 2 14* END HISTORY COMMENTS */ 2 15 2 16 /* Modified: 6 Jun 1979 by PG to add rank and byte 2 17* * Modified: 9 Jul 1989 by RW updated the declaration of error_ 2 18* */ 2 19 2 20 declare adjust_count entry(pointer); 2 21 /* parameter 1: (input) any node pointer */ 2 22 2 23 declare bindec entry(fixed bin(31)) reducible 2 24 returns(character(12) aligned); 2 25 /* parameter 1: (input) bin value */ 2 26 /* return: (output) character value with blanks */ 2 27 2 28 declare bindec$vs entry(fixed bin(31)) reducible 2 29 returns(character(12) aligned varying); 2 30 /* parameter 1: (input) binary value */ 2 31 /* return: (output) char value without blanks */ 2 32 2 33 declare binoct entry(fixed bin(31)) reducible 2 34 returns(char(12) aligned); 2 35 /* parameter 1: (input) binary value */ 2 36 /* return: (output) char value with blanks */ 2 37 2 38 declare binary_to_octal_string entry(fixed bin(31)) reducible 2 39 returns(char(12) aligned); 2 40 /* parameter 1: (input) binary value */ 2 41 /* return: (output) right-aligned char value */ 2 42 2 43 declare binary_to_octal_var_string entry(fixed bin(31)) reducible 2 44 returns(char(12) varying aligned); 2 45 /* parameter 1: (input) binary value */ 2 46 /* returns: (output) char value without blanks */ 2 47 2 48 declare compare_expression entry(pointer,pointer) reducible 2 49 returns(bit(1) aligned); 2 50 /* parameter 1: (input) any node pointer */ 2 51 /* parameter 2: (input) any node pointer */ 2 52 /* return: (output) compare bit */ 2 53 2 54 declare constant_length entry (pointer, fixed bin (71)) 2 55 returns (bit (1) aligned); 2 56 /* parameter 1: (input) reference node pointer */ 2 57 /* parameter 2: (input) value of constant length */ 2 58 /* return: (output) "1"b if constant length */ 2 59 2 60 declare convert entry(pointer,bit(36) aligned) 2 61 returns(pointer); 2 62 /* parameter 1: (input) any node pointer */ 2 63 /* parameter 2: (input) target type */ 2 64 /* return: (output) target value tree pointer */ 2 65 2 66 declare convert$to_integer entry(pointer,bit(36)aligned) 2 67 returns(pointer); 2 68 /* parameter 1: (input) any node pointer */ 2 69 /* parameter 2: (input) target type */ 2 70 /* return: (output) target value tree pointer */ 2 71 2 72 declare convert$from_builtin entry(pointer,bit(36) aligned) 2 73 returns(pointer); 2 74 /* parameter 1: (input) any node pointer */ 2 75 /* parameter 2: (input) target type */ 2 76 /* return: (output) target value tree pointer */ 2 77 2 78 declare convert$validate entry(pointer,pointer); 2 79 /* parameter 1: (input) source value tree pointer */ 2 80 /* parameter 2: (input) target reference node pointer */ 2 81 2 82 declare convert$to_target_fb entry(pointer,pointer) 2 83 returns(pointer); 2 84 /* parameter 1: (input) source value tree pointer */ 2 85 /* parameter 2: (input) target reference node pointer */ 2 86 /* return: (output) target value tree pointer */ 2 87 2 88 declare convert$to_target entry(pointer,pointer) 2 89 returns(pointer); 2 90 /* parameter 1: (input) source value tree pointer */ 2 91 /* parameter 2: (input) target reference node pointer */ 2 92 /* return: (output) target value tree pointer */ 2 93 2 94 declare copy_expression entry(pointer unaligned) 2 95 returns(pointer); 2 96 /* parameter 1: (input) any node pointer */ 2 97 /* return: (output) any node pointer */ 2 98 2 99 declare copy_expression$copy_sons entry(pointer,pointer); 2 100 /* parameter 1: (input) father symbol node pointer */ 2 101 /* parameter 2: (input) stepfather symbol node ptr */ 2 102 2 103 declare copy_unique_expression entry(pointer) 2 104 returns(pointer); 2 105 /* parameter 1: (input) any node pointer */ 2 106 /* return: (output) any node pointer */ 2 107 2 108 declare create_array entry() 2 109 returns(pointer); 2 110 /* return: (output) array node pointer */ 2 111 2 112 declare create_block entry(bit(9) aligned,pointer) 2 113 returns(pointer); 2 114 /* parameter 1: (input) block type */ 2 115 /* parameter 2: (input) father block node pointer */ 2 116 /* return: (output) block node pointer */ 2 117 2 118 declare create_bound entry() 2 119 returns(pointer); 2 120 /* return: (output) bound node pointer */ 2 121 2 122 declare create_context entry(pointer,pointer) 2 123 returns(pointer); 2 124 /* parameter 1: (input) block node pointer */ 2 125 /* parameter 2: (input) token pointer */ 2 126 /* return: (output) context node pointer */ 2 127 2 128 declare create_cross_reference entry() 2 129 returns(pointer); 2 130 /* return: (output) cross reference node pointer */ 2 131 2 132 declare create_default entry 2 133 returns(pointer); 2 134 /* return: (output) default node pointer */ 2 135 2 136 declare create_identifier entry() 2 137 returns(pointer); 2 138 /* return: (output) token node pointer */ 2 139 2 140 declare create_label entry(pointer,pointer,bit(3) aligned) 2 141 returns(pointer); 2 142 /* parameter 1: (input) block node pointer */ 2 143 /* parameter 2: (input) token node pointer */ 2 144 /* parameter 3: (input) declare type */ 2 145 /* return: (output) label node pointer */ 2 146 2 147 declare create_list entry(fixed bin(15)) 2 148 returns(pointer); 2 149 /* parameter 1: (input) number of list elements */ 2 150 /* return: (output) list node pointer */ 2 151 2 152 declare create_operator entry(bit(9) aligned,fixed bin(15)) 2 153 returns(pointer); 2 154 /* parameter 1: (input) operator type */ 2 155 /* parameter 2: (input) number of operands */ 2 156 /* return: (output) operator node pointer */ 2 157 2 158 declare create_reference entry(pointer) 2 159 returns(pointer); 2 160 /* parameter 1: (input) symbol node pointer */ 2 161 /* return: (output) reference node pointer */ 2 162 2 163 declare create_statement entry(bit(9) aligned,pointer,pointer,bit(12) aligned) 2 164 returns(pointer); 2 165 /* parameter 1: (input) statement type */ 2 166 /* parameter 2: (input) block node pointer */ 2 167 /* parameter 3: (input) label node pointer */ 2 168 /* parameter 4: (input) conditions */ 2 169 /* return: (output) statement node pointer */ 2 170 2 171 declare create_statement$prologue entry(bit(9) aligned,pointer,pointer,bit(12) aligned) 2 172 returns(pointer); 2 173 /* parameter 1: (input) statement type */ 2 174 /* parameter 2: (input) block node pointer */ 2 175 /* parameter 3: (input) label node pointer */ 2 176 /* parameter 4: (input) conditions */ 2 177 /* return: (output) statement node pointer */ 2 178 2 179 declare create_storage entry(fixed bin(15)) 2 180 returns(pointer); 2 181 /* parameter 1: (input) number of words */ 2 182 /* return: (output) storage block pointer */ 2 183 2 184 declare create_symbol entry(pointer,pointer,bit(3) aligned) 2 185 returns(pointer); 2 186 /* parameter 1: (input) block node pointer */ 2 187 /* parameter 2: (input) token node pointer */ 2 188 /* parameter 3: (input) declare type */ 2 189 /* return: (output) symbol node pointer */ 2 190 2 191 declare create_token entry (character (*), bit (9) aligned) 2 192 returns (ptr); 2 193 /* parameter 1: (input) token string */ 2 194 /* parameter 2: (input) token type */ 2 195 /* return: (output) token node ptr */ 2 196 2 197 declare create_token$init_hash_table entry (); 2 198 2 199 declare create_token$protected entry (char (*), bit (9) aligned, bit (18) aligned) 2 200 returns (ptr); 2 201 /* parameter 1: (input) token string */ 2 202 /* parameter 2: (input) token type */ 2 203 /* parameter 3: (input) protected flag */ 2 204 /* return: (output) token node ptr */ 2 205 2 206 declare decbin entry(character(*) aligned) reducible 2 207 returns(fixed bin(31)); 2 208 /* parameter 1: (input) decimal character string */ 2 209 /* return: (output) binary value */ 2 210 2 211 declare declare_constant entry(bit(*) aligned,bit(36) aligned,fixed bin(31),fixed bin(15)) 2 212 returns(pointer); 2 213 /* parameter 1: (input) value */ 2 214 /* parameter 2: (input) type */ 2 215 /* parameter 3: (input) size */ 2 216 /* parameter 4: (input) scale */ 2 217 /* return: (output) reference node pointer */ 2 218 2 219 declare declare_constant$bit entry(bit(*) aligned) 2 220 returns(pointer); 2 221 /* parameter 1: (input) bit */ 2 222 /* return: (output) reference node pointer */ 2 223 2 224 declare declare_constant$char entry(character(*) aligned) 2 225 returns(pointer); 2 226 /* parameter 1: (input) character */ 2 227 /* return: (output) reference node pointer */ 2 228 2 229 declare declare_constant$desc entry(bit(*) aligned) 2 230 returns(pointer); 2 231 /* parameter 1: (input) descriptor bit value */ 2 232 /* return: (output) reference node pointer */ 2 233 2 234 declare declare_constant$integer entry(fixed bin(31)) /* note...should really be fixed bin(24) */ 2 235 returns(pointer); 2 236 /* parameter 1: (input) integer */ 2 237 /* return: (output) reference node pointer */ 2 238 2 239 declare declare_descriptor entry(pointer,pointer,pointer,pointer,bit(2) aligned) 2 240 returns(pointer); 2 241 /* parameter 1: (input) block node pointer */ 2 242 /* parameter 2: (input) statement node pointer */ 2 243 /* parameter 3: (input) symbol node pointer */ 2 244 /* parameter 4: (input) loc pointer */ 2 245 /* parameter 5: (input) array descriptor bit 2 246* cross_section bit */ 2 247 /* return: (output) reference node pointer */ 2 248 2 249 declare declare_descriptor$ctl entry(pointer,pointer,pointer,pointer,bit(2) aligned) 2 250 returns(pointer); 2 251 /* parameter 1: (input) block node pointer */ 2 252 /* parameter 2: (input) statement node pointer */ 2 253 /* parameter 3: (input) symbol node pointer */ 2 254 /* parameter 4: (input) loc pointer */ 2 255 /* parameter 5: (input) array descriptor bit 2 256* cross_section bit */ 2 257 /* return: (output) reference node pointer */ 2 258 2 259 declare declare_descriptor$param entry(pointer,pointer,pointer,pointer,bit(2) aligned) 2 260 returns(pointer); 2 261 /* parameter 1: (input) block node pointer */ 2 262 /* parameter 2: (input) statement node pointer */ 2 263 /* parameter 3: (input) symbol node pointer */ 2 264 /* parameter 4: (input) loc pointer */ 2 265 /* parameter 5: (input) array descriptor bit 2 266* cross_section bit */ 2 267 /* return: (output) reference node pointer */ 2 268 2 269 declare declare_integer entry(pointer) 2 270 returns(pointer); 2 271 /* parameter 1: (input) block node pointer */ 2 272 /* return: (output) reference node pointer */ 2 273 2 274 declare declare_picture entry(char(*)aligned,pointer,fixed bin(15)); 2 275 /* parameter 1: (input) picture string */ 2 276 /* parameter 2: (input) symbol node pointer */ 2 277 /* parameter 3: (output) error code, if any */ 2 278 2 279 declare declare_picture_temp entry(char(*) aligned,fixed bin(31),bit(1) aligned,bit(1) aligned) 2 280 returns(pointer); 2 281 /* parameter 1: (input) picture string */ 2 282 /* parameter 2: (input) scalefactor of picture */ 2 283 /* parameter 3: (input) ="1"b => complex picture */ 2 284 /* parameter 4: (input) ="1"b => unaligned temp */ 2 285 /* return: (output) reference node pointer */ 2 286 2 287 declare declare_pointer entry(pointer) 2 288 returns(pointer); 2 289 /* parameter 1: (input) block node pointer */ 2 290 /* return: (output) reference node pointer */ 2 291 2 292 declare declare_temporary entry(bit(36) aligned,fixed bin(31),fixed bin(15),pointer) 2 293 returns(pointer); 2 294 /* parameter 1: (input) type */ 2 295 /* parameter 2: (input) precision */ 2 296 /* parameter 3: (input) scale */ 2 297 /* parameter 4: (input) length */ 2 298 /* return: (output) reference node pointer */ 2 299 2 300 declare decode_node_id entry(pointer,bit(1) aligned) 2 301 returns(char(120) varying); 2 302 /* parameter 1: (input) node pointer */ 2 303 /* parameter 2: (input) ="1"b => capitals */ 2 304 /* return: (output) source line id */ 2 305 2 306 declare decode_source_id entry( 3 1 1 structure unaligned, 3 2 2 /* file_number */ bit(8), 3 3 2 /* line_number */ bit(14), 3 4 2 /* stmt_number */ bit(5), 2 307 2 308 bit(1) aligned) 2 309 returns(char(120) varying); 2 310 /* parameter 1: (input) source id */ 2 311 /* parameter 2: (input) ="1"b => capitals */ 2 312 /* return: (output) source line id */ 2 313 2 314 declare error entry(fixed bin(15),pointer,pointer); 2 315 /* parameter 1: (input) error number */ 2 316 /* parameter 2: (input) statement node pointer or null*/ 2 317 /* parameter 3: (input) token node pointer */ 2 318 2 319 declare error$omit_text entry(fixed bin(15),pointer,pointer); 2 320 /* parameter 1: (input) error number */ 2 321 /* parameter 2: (input) statement node pointer or null*/ 2 322 /* parameter 3: (input) token node pointer */ 2 323 2 324 declare error_ entry(fixed bin(15), 4 1 1 structure unaligned, 4 2 2 /* file_number */ bit(8), 4 3 2 /* line_number */ bit(14), 4 4 2 /* stmt_number */ bit(5), 2 325 2 326 pointer,fixed bin(8),fixed bin(23),fixed bin(11)); 2 327 /* parameter 1: (input) error number */ 2 328 /* parameter 2: (input) statement id */ 2 329 /* parameter 3: (input) any node pointer */ 2 330 /* parameter 4: (input) source segment */ 2 331 /* parameter 5: (input) source starting character */ 2 332 /* parameter 6: (input) source length */ 2 333 2 334 declare error_$no_text entry(fixed bin(15), 5 1 1 structure unaligned, 5 2 2 /* file_number */ bit(8), 5 3 2 /* line_number */ bit(14), 5 4 2 /* stmt_number */ bit(5), 2 335 2 336 pointer); 2 337 /* parameter 1: (input) error number */ 2 338 /* parameter 2: (input) statement id */ 2 339 /* parameter 3: (input) any node pointer */ 2 340 2 341 declare error_$initialize_error entry(); 2 342 2 343 declare error_$finish entry(); 2 344 2 345 declare free_node entry(pointer); 2 346 /* parameter 1: any node pointer */ 2 347 2 348 declare get_array_size entry(pointer,fixed bin(3)); 2 349 /* parameter 1: (input) symbol node pointer */ 2 350 /* parameter 2: (input) units */ 2 351 2 352 declare get_size entry(pointer); 2 353 /* parameter 1: (input) symbol node pointer */ 2 354 2 355 declare merge_attributes external entry(pointer,pointer) 2 356 returns(bit(1) aligned); 2 357 /* parameter 1: (input) target symbol node pointer */ 2 358 /* parameter 2: (input) source symbol node pointer */ 2 359 /* return: (output) "1"b if merge was unsuccessful */ 2 360 2 361 declare optimizer entry(pointer); 2 362 /* parameter 1: (input) root pointer */ 2 363 2 364 declare parse_error entry(fixed bin(15),pointer); 2 365 /* parameter 1: (input) error number */ 2 366 /* parameter 2: (input) any node pointer */ 2 367 2 368 declare parse_error$no_text entry(fixed bin(15),pointer); 2 369 /* parameter 1: (input) error number */ 2 370 /* parameter 2: (input) any node pointer */ 2 371 2 372 declare pl1_error_print$write_out 2 373 entry(fixed bin(15), 6 1 1 structure unaligned, 6 2 2 /* file_number */ bit(8), 6 3 2 /* line_number */ bit(14), 6 4 2 /* stmt_number */ bit(5), 2 374 2 375 pointer,fixed bin(11),fixed bin(31),fixed bin(31),fixed bin(15)); 2 376 /* parameter 1: (input) error number */ 2 377 /* parameter 2: (input) statement identification */ 2 378 /* parameter 3: (input) any node pointer */ 2 379 /* parameter 4: (input) source segment */ 2 380 /* parameter 5: (input) source character index */ 2 381 /* parameter 6: (input) source length */ 2 382 /* parameter 7: (input) source line */ 2 383 2 384 declare pl1_error_print$listing_segment 2 385 entry(fixed bin(15), 7 1 1 structure unaligned, 7 2 2 /* file_number */ bit(8), 7 3 2 /* line_number */ bit(14), 7 4 2 /* stmt_number */ bit(5), 2 386 2 387 pointer); 2 388 /* parameter 1: (input) error number */ 2 389 /* parameter 2: (input) statement identification */ 2 390 /* parameter 3: (input) token node pointer */ 2 391 2 392 declare pl1_print$varying entry(character(*) aligned varying); 2 393 /* parameter 1: (input) string */ 2 394 2 395 declare pl1_print$varying_nl entry(character(*) aligned varying); 2 396 /* parameter 1: (input) string */ 2 397 2 398 declare pl1_print$non_varying entry(character(*) aligned,fixed bin(31)); 2 399 /* parameter 1: (input) string */ 2 400 /* parameter 2: (input) string length or 0 */ 2 401 2 402 declare pl1_print$non_varying_nl entry(character(*) aligned,fixed bin(31)); 2 403 /* parameter 1: (input) string */ 2 404 /* parameter 2: (input) string length or 0 */ 2 405 2 406 declare pl1_print$string_pointer entry(pointer,fixed bin(31)); 2 407 /* parameter 1: (input) string pointer */ 2 408 /* parameter 2: (input) string size */ 2 409 2 410 declare pl1_print$string_pointer_nl entry(pointer,fixed bin(31)); 2 411 /* parameter 1: (input) string pointer */ 2 412 /* parameter 2: (input) string length or 0 */ 2 413 2 414 declare pl1_print$unaligned_nl entry(character(*) unaligned,fixed bin(31)); 2 415 /* parameter 1: (input) string */ 2 416 /* parameter 2: (input) length */ 2 417 2 418 declare pl1_print$for_lex entry (ptr, fixed bin (14), fixed bin (21), fixed bin (21), bit (1) aligned, bit (1) aligned); 2 419 /* parameter 1: (input) ptr to base of source segment */ 2 420 /* parameter 2: (input) line number */ 2 421 /* parameter 3: (input) starting offset in source seg */ 2 422 /* parameter 4: (input) number of chars to copy */ 2 423 /* parameter 5: (input) ON iff shd print line number */ 2 424 /* parameter 6: (input) ON iff line begins in comment */ 2 425 2 426 declare refer_extent entry(pointer,pointer); 2 427 /* parameter 1: (input/output) null,ref node,op node pointer */ 2 428 /* parameter 2: (input) null,ref node,op node pointer */ 2 429 2 430 declare reserve$clear entry() 2 431 returns(pointer); 2 432 /* return: (output) pointer */ 2 433 2 434 declare reserve$declare_lib entry(fixed bin(15)) 2 435 returns(pointer); 2 436 /* parameter 1: (input) builtin function number */ 2 437 /* return: (output) pointer */ 2 438 2 439 declare reserve$read_lib entry(fixed bin(15)) 2 440 returns(pointer); 2 441 /* parameter 1: (input) builtin function number */ 2 442 /* return: (output) pointer */ 2 443 2 444 declare semantic_translator entry(); 2 445 2 446 declare semantic_translator$abort entry(fixed bin(15),pointer); 2 447 /* parameter 1: (input) error number */ 2 448 /* parameter 2: (input) any node pointer */ 2 449 2 450 declare semantic_translator$error entry(fixed bin(15),pointer); 2 451 /* parameter 1: (input) error number */ 2 452 /* parameter 2: (input) any node pointer */ 2 453 2 454 declare share_expression entry(ptr) 2 455 returns(ptr); 2 456 /* parameter 1: (input) usually operator node pointer */ 2 457 /* return: (output) tree pointer or null */ 2 458 2 459 declare token_to_binary entry(ptr) reducible 2 460 returns(fixed bin(31)); 2 461 /* parameter 1: (input) token node pointer */ 2 462 /* return: (output) converted binary value */ 2 463 2 464 /* END INCLUDE FILE ... language_utility.incl.pl1 */ 1 175 1 176 /* END INCLUDE FILE parse.incl.pl1 */ 85 8 1 dcl pl1_stat_$token_list_ptr ptr external static; /* pointer to token list */ 8 2 dcl token_list(token_list_length) ptr based(token_list_pointer); 8 3 dcl token_list_pointer ptr initial(pl1_stat_$token_list_ptr); /* for efficiency only */ 8 4 dcl token_list_length fixed(15) internal static initial(3000) options(constant); 8 5 8 6 dcl 1 pl1_stat_$statement_id external static, 8 7 2 file_number bit(8), 8 8 2 line_number bit(14), 8 9 2 statement_number bit(5); 8 10 8 11 dcl 1 t_table based(token_list(k)) aligned, 8 12 2 node_type bit(9) unaligned, 8 13 2 type bit(9) unaligned, 8 14 2 loc bit(18) unaligned, 8 15 2 declaration ptr unaligned, 8 16 2 next ptr unaligned, 8 17 2 size fixed(9), 8 18 2 string char(n refer(t_table.size)); 86 9 1 /* BEGIN INCLUDE FILE ... token.incl.pl1 */ 9 2 9 3 dcl 1 token based aligned, 9 4 2 node_type bit(9) unaligned, 9 5 2 type bit(9) unaligned, 9 6 2 loc bit(18) unaligned, /* symtab offset for identifiers, "p" flag for constants */ 9 7 2 declaration ptr unaligned, 9 8 2 next ptr unaligned, 9 9 2 size fixed(9), 9 10 2 string char(n refer(token.size)); 9 11 9 12 /* END INCLUDE FILE ... token.incl.pl1 */ 87 10 1 /* BEGIN INCLUDE FILE ... nodes.incl.pl1 */ 10 2 10 3 /* Modified: 26 Dec 1979 by PCK to implement by name assignment */ 10 4 10 5 dcl ( block_node initial("000000001"b), 10 6 statement_node initial("000000010"b), 10 7 operator_node initial("000000011"b), 10 8 reference_node initial("000000100"b), 10 9 token_node initial("000000101"b), 10 10 symbol_node initial("000000110"b), 10 11 context_node initial("000000111"b), 10 12 array_node initial("000001000"b), 10 13 bound_node initial("000001001"b), 10 14 format_value_node initial("000001010"b), 10 15 list_node initial("000001011"b), 10 16 default_node initial("000001100"b), 10 17 machine_state_node initial("000001101"b), 10 18 source_node initial("000001110"b), 10 19 label_node initial("000001111"b), 10 20 cross_reference_node initial("000010000"b), 10 21 sf_par_node initial("000010001"b), 10 22 temporary_node initial("000010010"b), 10 23 label_array_element_node initial("000010011"b), 10 24 by_name_agg_node initial("000010100"b)) 10 25 bit(9) internal static aligned options(constant); 10 26 10 27 dcl 1 node based aligned, 10 28 2 type unal bit(9), 10 29 2 source_id unal structure, 10 30 3 file_number bit(8), 10 31 3 line_number bit(14), 10 32 3 statement_number bit(5); 10 33 10 34 /* END INCLUDE FILE ... nodes.incl.pl1 */ 88 11 1 /* BEGIN INCLUDE FILE ... operator.incl.pl1 */ 11 2 11 3 /* Modified: 2 Apr 1980 by PCK to add max_number_of_operands */ 11 4 11 5 /* format: style3 */ 11 6 dcl 1 operator based aligned, 11 7 2 node_type bit (9) unaligned, 11 8 2 op_code bit (9) unaligned, 11 9 2 shared bit (1) unaligned, 11 10 2 processed bit (1) unaligned, 11 11 2 optimized bit (1) unaligned, 11 12 2 number fixed (14) unaligned, 11 13 2 operand dimension (n refer (operator.number)) ptr unaligned; 11 14 11 15 dcl max_number_of_operands 11 16 fixed bin (15) int static options (constant) initial (32767); 11 17 11 18 /* END INCLUDE FILE ... operator.incl.pl1 */ 89 12 1 /* BEGIN INCLUDE FILE ... op_codes.incl.pl1 */ 12 2 12 3 /* Modified: 25 Apr 1979 by PCK 4-bit decimal */ 12 4 /* Modified: 6 Jun 1979 by PG to add rank and byte */ 12 5 /* Modified: 26 Dec 1979 by PCK to add assign_by_name */ 12 6 /* Modified: 26 July 82 BIM wordno, segno */ 12 7 12 8 dcl ( add initial("000010001"b), /* opnd(1) <- opnd(2)+opnd(3) */ 12 9 sub initial("000010010"b), /* opnd(1) <- opnd(2)-opnd(3) */ 12 10 mult initial("000010011"b), /* opnd(1) <- opnd(2)*opnd(3) */ 12 11 div initial("000010100"b), /* opnd(1) <- opnd(2)/opnd(3) */ 12 12 negate initial("000010101"b), /* opnd(1) <- -opnd(2) */ 12 13 exp initial("000010110"b), /* opnd(1) <- opnd(2) ** opnd(3) */ 12 14 12 15 and_bits initial("000100001"b), /* opnd(1) <- opnd(2) & opnd(3) */ 12 16 or_bits initial("000100010"b), /* opnd(1) <- opnd(2)|opnd(3) */ 12 17 xor_bits initial("000100011"b), /* opnd(1) <- opnd(2) xor opnd(3) */ 12 18 not_bits initial("000100100"b), /* opnd(1) <- ^opnd(2) */ 12 19 cat_string initial("000100101"b), /* opnd(1) <- opnd(2)||opnd(3) */ 12 20 bool_fun initial("000100110"b), /* opnd(1) <- bool(opnd(2),opnd(3),opnd(4)) */ 12 21 12 22 assign initial("000110001"b), /* opnd(1) <- opnd(2) */ 12 23 assign_size_ck initial("000110010"b), /* opnd(1) <- opnd(2) */ 12 24 assign_zero initial("000110011"b), /* opnd(1) <- 0 */ 12 25 copy_words initial("000110100"b), /* move opnd(2) to opnd(1) by opnd(3) words */ 12 26 copy_string initial("000110101"b), /* move opnd(2) to opnd(1) by opnd(3) units */ 12 27 make_desc initial("000110110"b), /* opnd(1) <- descriptor(opnd(2),opnd(3)) */ 12 28 assign_round initial("000110111"b), /* opnd(1) <- opnd(2) rounded */ 12 29 pack initial("000111000"b), /* opnd(1) <- encode to picture opnd(2) */ 12 30 unpack initial("000111001"b), /* opnd(1) <- decode from picture opnd(2) */ 12 31 12 32 less_than initial("001000100"b), /* opnd(1) <- opnd(2) < opnd(3) */ 12 33 greater_than initial("001000101"b), /* opnd(1) <- opnd(2) > opnd(3) */ 12 34 equal initial("001000110"b), /* opnd(1) <- opnd(2) = opnd(3) */ 12 35 not_equal initial("001000111"b), /* opnd(1) <- opnd(2) ^= opnd(3) */ 12 36 less_or_equal initial("001001000"b), /* opnd(1) <- opnd(2) <= opnd(3) */ 12 37 greater_or_equal initial("001001001"b), /* opnd(1) <- opnd(2) >= opnd(3) */ 12 38 12 39 jump initial("001010001"b), /* go to opnd(1) unconditionally */ 12 40 jump_true initial("001010010"b), /* go to opnd(1) if opnd(2) is not 0 */ 12 41 jump_false initial("001010011"b), /* go to opnd(1) if opnd(2) is all 0 */ 12 42 jump_if_lt initial("001010100"b), /* go to opnd(1) if opnd(2) < opnd(3) */ 12 43 jump_if_gt initial("001010101"b), /* go to opnd(1) if opnd(2) > opnd(3) */ 12 44 jump_if_eq initial("001010110"b), /* go to opnd(1) if opnd(2) = opnd(3) */ 12 45 jump_if_ne initial("001010111"b), /* go to opnd(1) if opnd(2) ^= opnd(3) */ 12 46 jump_if_le initial("001011000"b), /* go to opnd(1) if opnd(2) <= opnd(3) */ 12 47 jump_if_ge initial("001011001"b), /* go to opnd(1) if opnd(2) >= opnd(3) */ 12 48 12 49 std_arg_list initial("001100001"b), /* opnd(1) <- arglist(opnd(2) desclist(opnd(3))) */ 12 50 return_words initial("001100010"b), /* return aggregate opnd(1), opnd(2) is length in words */ 12 51 std_call initial("001100011"b), /* opnd(1) <- call opnd(2) with opnd(3) */ 12 52 return_bits initial("001100100"b), /* return aggregate opnd(1), opnd(2) is length in bits */ 12 53 std_entry initial("001100101"b), /* entry(opnd(1)... opnd(n)) */ 12 54 return_string initial("001100110"b), /* return string opnd(1) */ 12 55 ex_prologue initial("001100111"b), /* execute the prologue -no operands- */ 12 56 allot_auto initial("001101000"b), /* opnd(1) <- addrel(stack,opnd(2)) */ 12 57 param_ptr initial("001101001"b), /* opnd(1) <- ptr to opnd(2) in block opnd(3) */ 12 58 param_desc_ptr initial("001101010"b), /* opnd(1) <- ptr to opnd(2) in block opnd(3) */ 12 59 std_return initial("001101011"b), /* return -no arguments- */ 12 60 allot_ctl initial("001101100"b), /* allocate opnd(1) , length in words is opnd(2) */ 12 61 free_ctl initial("001101101"b), /* free opnd(1) */ 12 62 stop initial("001101110"b), /* stop - terminate run unit */ 12 63 12 64 mod_bit initial("001110000"b), /* opnd(1) <- mod(opnd(3),36), 12 65* opnd(2) <- opnd(3) / 36 */ 12 66 mod_byte initial("001110001"b), /* opnd(1) <- mod(opnd(3),4), 12 67* opnd(2) <- opnd(3) / 4 */ 12 68 mod_half initial("001110010"b), /* opnd(1) <- mod(opnd(3),2), 12 69* opnd(2) <- opnd(3) / 2 */ 12 70 mod_word initial("001110011"b), /* TO BE DEFINED BY BLW */ 12 71 12 72 bit_to_char initial("010000000"b), /* opnd(1) <- (opnd(2)+8)/9 */ 12 73 bit_to_word initial("010000001"b), /* opnd(1) <- (opnd(2)+35)/36 */ 12 74 char_to_word initial("010000010"b), /* opnd(1) <- (opnd(2)+3)/4 */ 12 75 half_to_word initial("010000011"b), /* opnd(1) <- (opnd(2)+1)/2 */ 12 76 word_to_mod2 initial("010000100"b), /* opnd(1) <- (opnd(2)+1)/2*2 */ 12 77 word_to_mod4 initial("010000101"b), /* opnd(1) <- (opnd(2)+3)/4*4 */ 12 78 word_to_mod8 initial("010000110"b), /* opnd(1) <- (opnd(2)+7)/8*8 */ 12 79 rel_fun initial("010000111"b), /* opnd(1) <- rel(opnd(2)) */ 12 80 baseno_fun initial("010001000"b), /* opnd(1) <- baseno(opnd(2)) */ 12 81 desc_size initial("010001001"b), /* opnd(1) <- substr(opnd(2),13,24) */ 12 82 bit_pointer initial("010001010"b), /* opnd(1) <- bit offset of opnd(2) */ 12 83 index_before_fun initial("010001011"b), /* opnd(1) <- length of before(opnd(2),opnd(3)) */ 12 84 index_after_fun initial("010001100"b), /* opnd(1) <- offset of after(opnd(2),opnd(3)) in opnd(2) */ 12 85 verify_ltrim_fun initial("010001101"b), /* opnd(1) <- offset of ltrim(opnd(2),opnd(3)) in opnd(2) */ 12 86 verify_rtrim_fun initial("010001110"b), /* opnd(1) <- length(opnd(2))-length(rtrim(opnd(2),opnd(3))) */ 12 87 digit_to_bit initial("010001111"b), /* opnd(1) <- 9*opnd(2)/2 */ 12 88 12 89 ceil_fun initial("010010000"b), /* opnd(1) <- ceil(opnd(2)) */ 12 90 floor_fun initial("010010001"b), /* opnd(1) <- floor(opnd(2)) */ 12 91 round_fun initial("010010010"b), /* opnd(1) <- round(opnd(2)) */ 12 92 sign_fun initial("010010011"b), /* opnd(1) <- sign(opnd(2)) */ 12 93 abs_fun initial("010010100"b), /* opnd(1) <- abs(opnd(2)) */ 12 94 trunc_fun initial("010010101"b), /* opnd(1) <- trunc(opnd(2)) */ 12 95 byte_fun initial("010010110"b), /* opnd(1) <- byte(opnd(2)) */ 12 96 rank_fun initial("010010111"b), /* opnd(1) <- rank(opnd(2)) */ 12 97 index_rev_fun initial("010011000"b), /* opnd(1) <- index(reverse(opnd(2)),reverse(opnd(3))) */ 12 98 search_rev_fun initial("010011001"b), /* opnd(1) <- search(reverse(opnd(2)),opnd(3)) */ 12 99 verify_rev_fun initial("010011010"b), /* opnd(1) <- verify(reverse(opnd(2)),opnd(3)) */ 12 100 wordno_fun initial("010011011"b), /* opnd(1) <- wordno (opnd(2)) */ 12 101 segno_fun initial("010011100"b), /* opnd(1) <- segno (opnd(2)) */ 12 102 bitno_fun initial("010011101"b), /* opnd(1) <- bitno (opnd(2)) */ 12 103 charno_fun initial("010011110"b), /* opnd(1) <- charno (opnd(2)) */ 12 104 12 105 index_fun initial("010100000"b), /* opnd(1) <- index(opnd(2),opnd(3)) */ 12 106 off_fun initial("010100001"b), /* opnd(1) <- offset(opnd(2),opnd(3)) */ 12 107 complex_fun initial("010100010"b), /* opnd(1) <- complex(opnd(2),opnd(3)) */ 12 108 conjg_fun initial("010100011"b), /* opnd(1) <- conjg(opnd(2),opnd(3)) */ 12 109 mod_fun initial("010100100"b), /* opnd(1) <- mod(opnd(2),opnd(3)) */ 12 110 repeat_fun initial("010100101"b), /* opnd(1) <- repeat(opnd(2),opnd(3)) */ 12 111 verify_fun initial("010100110"b), /* opnd(1) <- verify(opnd(2),opnd(3)) */ 12 112 translate_fun initial("010100111"b), /* opnd(1) <- translate(opnd(2),opnd(3))*/ 12 113 real_fun initial("010101001"b), /* opnd(1) <- real(opnd(2)) */ 12 114 imag_fun initial("010101010"b), /* opnd(1) <- imag(opnd(2)) */ 12 115 length_fun initial("010101011"b), /* opnd(1) <- length(opnd(2)) */ 12 116 pl1_mod_fun initial("010101100"b), /* opnd(1) <- mod(opnd(2)) */ 12 117 search_fun initial("010101101"b), /* opnd(1) <- search(opnd(2),opnd(3)) */ 12 118 allocation_fun initial("010101110"b), /* opnd(1) <- allocation(opnd(2)) */ 12 119 reverse_fun initial("010101111"b), /* opnd(1) <- reverse(opnd(2)) */ 12 120 12 121 addr_fun initial("010110000"b), /* opnd(1) <- addr(opnd(2)) */ 12 122 addr_fun_bits initial("010110001"b), /* opnd(1) <- addr(opnd(2)) */ 12 123 ptr_fun initial("010110010"b), /* opnd(1) <- ptr(opnd(2),opnd(3)) */ 12 124 baseptr_fun initial("010110011"b), /* opnd(1) <- baseptr(opnd(2)) */ 12 125 addrel_fun initial("010110100"b), /* opnd(1) <- addrel(opnd(2),opnd(3)) */ 12 126 codeptr_fun initial("010110101"b), /* opnd(1) <- codeptr(opnd(2)) */ 12 127 environmentptr_fun initial("010110110"b), /* opnd(1) <- environmentptr(opnd(2)) */ 12 128 stackbaseptr_fun initial("010110111"b), /* opnd(1) is ptr to base of current stack */ 12 129 stackframeptr_fun initial("010111000"b), /* opnd(1) is ptr to current block's stack frame */ 12 130 setcharno_fun initial("010111001"b), /* opnd(1) <- opnd(2) with charno opnd(3) */ 12 131 addcharno_fun initial("010111010"b), /* opnd(1) <- opnd(2) with charno = charno + opnd(3) */ 12 132 setbitno_fun initial("010111011"b), /* setcharno for bitsno */ 12 133 addbitno_fun initial("010111100"b), /* addcharno for bitno */ 12 134 12 135 min_fun initial("011000000"b), /* opnd(1) <- min(opnd(1),opnd(2),...) */ 12 136 max_fun initial("011000001"b), /* opnd(1) <- max(opnd(1),opnd(2),...) */ 12 137 12 138 stack_ptr initial("011010001"b), /* opnd(1) <- stack frame ptr */ 12 139 empty_area initial("011010010"b), /* empty opnd(1), length in words is opnd(2) */ 12 140 enable_on initial("011010100"b), /* opnd(1) is the cond name 12 141* opnd(2) is the file name 12 142* opnd(3) is the block */ 12 143 revert_on initial("011010101"b), /* opnd(1) is the cond name, 12 144* opnd(2) is the file name */ 12 145 signal_on initial("011010110"b), /* opnd(1) is the cond name 12 146* opnd(2) is the file name */ 12 147 12 148 lock_fun initial("011010111"b), /* opnd(1) <- stac(opnd(2),opnd(3)) */ 12 149 stacq_fun initial("011011000"b), /* opnd(1) is result, opnd(2) is ptr to lock word, 12 150* opnd(3) is old value, (4) is new value. */ 12 151 clock_fun initial("011011001"b), /* opnd(1) is the clock time */ 12 152 vclock_fun initial("011011010"b), /* opnd(1) is the virtual clock time */ 12 153 12 154 bound_ck initial("011100000"b), /* opnd(1) <- opnd(2) if opnd(3) <= opnd(2) <= opnd(4) */ 12 155 range_ck initial("011100001"b), /* opnd(1) <- opnd(2) if opnd(3) <= opnd(2) <= opnd(4) */ 12 156 loop initial("011100010"b), /* do opnd(1) for opnd(2) from opnd(3) to opnd(4) by 1, 12 157* opnd(5) is the list */ 12 158 join initial("011100011"b), /* do opnd(1), opnd(2) ... opnd(n) */ 12 159 allot_based initial("011100100"b), /* allocate opnd(2) words in opnd(3), set opnd(1) */ 12 160 free_based initial("011100101"b), /* free opnd(1) in opnd(3), length is opnd(2) words */ 12 161 12 162 r_parn initial("011110001"b), /* format op code */ 12 163 l_parn initial("011110010"b), 12 164 r_format initial("011110011"b), 12 165 c_format initial("011110100"b), 12 166 f_format initial("011110101"b), 12 167 e_format initial("011110110"b), 12 168 b_format initial("011110111"b), 12 169 a_format initial("011111000"b), 12 170 x_format initial("011111001"b), 12 171 skip_format initial("011111010"b), 12 172 column_format initial("011111011"b), 12 173 page_format initial("011111100"b), 12 174 line_format initial("011111101"b), 12 175 picture_format initial("011111110"b), 12 176 bn_format initial("011111111"b), /* bit format, length(opnd(2)), radix factor(opnd(3)) */ 12 177 12 178 get_list_trans initial("100000000"b), /* getlist(opnd(2) with desc(opnd(1))) */ 12 179 get_edit_trans initial("100000001"b), /* getedit(opnd(2) with desc(opnd(1))) */ 12 180 get_data_trans initial("100000010"b), /* getdata(opnd(1) to opnd(n)) */ 12 181 put_list_trans initial("100000011"b), /* putlist(opnd(2) with desc(opnd(1))) */ 12 182 put_edit_trans initial("100000100"b), /* putedit(opnd(2) with desc(opnd(1))) */ 12 183 put_data_trans initial("100000101"b), /* putdata(opnd(2)) with subscript-list opnd(1) */ 12 184 terminate_trans initial("100000110"b), /* terminate stream transmission */ 12 185 stream_prep initial("100000111"b), /* initiate stream transmission */ 12 186 record_io initial("100001000"b), /* perform record io operation */ 12 187 fortran_read initial("100001001"b), /* A complete read statement */ 12 188 fortran_write initial("100001010"b), /* A complete write statement */ 12 189 ftn_file_manip initial("100001011"b), /* endfile,backspace,rewind,etc. */ 12 190 ftn_trans_loop initial("100001100"b), /* An implied do in i/o list */ 12 191 put_control initial("100001101"b), /* put control opnd(1) opnd(2) times */ 12 192 put_field initial("100001110"b), /* putlist(opnd(2)) of length(opnd(1)) */ 12 193 put_field_chk initial("100001111"b), /* putlist(op(2)) of len(op(1)) check char index(op(3)) */ 12 194 12 195 /* These operators are produced by the parse but are not used as input to the code generator. */ 12 196 /* They are processed by the semantic translator. */ 12 197 12 198 return_value initial("100010010"b), /* return(opnd(1)) */ 12 199 allot_var initial("100010011"b), /* allot opnd(1) in opnd(2) */ 12 200 free_var initial("100010100"b), /* free opnd(1) out of opnd(2) */ 12 201 get_file initial("100010101"b), /* opnd(1) is filename,opnd(2) is copy */ 12 202 /* opnd(3) is skip, opnd(4) is list */ 12 203 get_string initial("100010110"b), /* opnd(1) is string,opnd(2) is list */ 12 204 put_file initial("100010111"b), /* opnd(1) is filename,opnd(2) is page */ 12 205 /* opnd(3) is skip,opnd(4) is line */ 12 206 put_string initial("100011000"b), /* opnd(1) is string,opnd(2) is list */ 12 207 open_file initial("100011001"b), 12 208 close_file initial("100011010"b), 12 209 read_file initial("100011011"b), 12 210 write_file initial("100011100"b), 12 211 locate_file initial("100011101"b), 12 212 do_fun initial("100011110"b), /* opnd(1) is join of a list */ 12 213 /* opnd(2) is control variable ref */ 12 214 /* opnd(3) is specification operator */ 12 215 do_spec initial("100011111"b), /* opnd(1) to opnd(2) by opnd(3) */ 12 216 /* repeat opnd(4) while opnd(5) */ 12 217 /* opnd(6) is next specification */ 12 218 12 219 rewrite_file initial("100100000"b), 12 220 delete_file initial("100100001"b), 12 221 unlock_file initial("100100010"b), 12 222 lock_file initial("100100011"b), 12 223 refer initial("100100101"b), /* opnd(1) refer(opnd(2)) */ 12 224 prefix_plus initial("100100110"b), /* opnd(1) <- +opnd(2) */ 12 225 nop initial("100100111"b), /* no-op */ 12 226 assign_by_name initial("100101000"b), /* opnd(1) <- opnd(2),by name */ 12 227 12 228 /* These operators are produced by the semantic translator in processing the math 12 229* builtin functions and are used as input to the code generator */ 12 230 12 231 sqrt_fun initial("100110000"b), /* opnd(1) <- sqrt(opnd(2)) */ 12 232 sin_fun initial("100110001"b), /* opnd(1) <- sin(opnd(2)) */ 12 233 sind_fun initial("100110010"b), /* opnd(1) <- sind(opnd(2)) */ 12 234 cos_fun initial("100110011"b), /* opnd(1) <- cos(opnd(2)) */ 12 235 cosd_fun initial("100110100"b), /* opnd(1) <- cosd(opnd(2)) */ 12 236 tan_fun initial("100110101"b), /* opnd(1) <- tan(opnd(2)) */ 12 237 tand_fun initial("100110110"b), /* opnd(1) <- tand(opnd(2)) */ 12 238 asin_fun initial("100110111"b), /* opnd(1) <- asin(opnd(2)) */ 12 239 asind_fun initial("100111000"b), /* opnd(1) <- asind(opnd(2)) */ 12 240 acos_fun initial("100111001"b), /* opnd(1) <- acos(opnd(2)) */ 12 241 acosd_fun initial("100111010"b), /* opnd(1) <- acosd(opnd(2)) */ 12 242 atan_fun initial("100111011"b), /* opnd(1) <- atan(opnd(2)[,opnd(3)]) */ 12 243 atand_fun initial("100111100"b), /* opnd(1) <- atand(opnd(2)[,opnd(3)]) */ 12 244 log2_fun initial("100111101"b), /* opnd(1) <- log2(opnd(2)) */ 12 245 log_fun initial("100111110"b), /* opnd(1) <- log(opnd(2)) */ 12 246 log10_fun initial("100111111"b), /* opnd(1) <- log10(opnd(2)) */ 12 247 12 248 exp_fun initial("101000000"b)) /* opnd(1) <- exp(opnd(2)) */ 12 249 12 250 bit(9) aligned internal static options(constant); 12 251 12 252 /* END INCLUDE FILE ... op_codes.incl.pl1 */ 90 13 1 /* BEGIN INCLUDE FILE ... token_types.incl.pl1 */ 13 2 13 3 dcl ( no_token initial("000000000"b), /* token types */ 13 4 identifier initial("100000000"b), 13 5 isub initial("010000000"b), 13 6 plus initial("001000001"b), 13 7 minus initial("001000010"b), 13 8 asterisk initial("001000011"b), 13 9 slash initial("001000100"b), 13 10 expon initial("001000101"b), 13 11 not initial("001000110"b), 13 12 and initial("001000111"b), 13 13 or initial("001001000"b), 13 14 cat initial("001001001"b), 13 15 eq initial("001001010"b), 13 16 ne initial("001001011"b), 13 17 lt initial("001001100"b), 13 18 gt initial("001001101"b), 13 19 le initial("001001110"b), 13 20 ge initial("001001111"b), 13 21 ngt initial("001010000"b), 13 22 nlt initial("001010001"b), 13 23 assignment initial("001010010"b), 13 24 colon initial("001010011"b), 13 25 semi_colon initial("001010100"b), 13 26 comma initial("001010101"b), 13 27 period initial("001010110"b), 13 28 arrow initial("001010111"b), 13 29 left_parn initial("001011000"b), 13 30 right_parn initial("001011001"b), 13 31 percent initial("001011100"b), 13 32 bit_string initial("000100001"b), 13 33 char_string initial("000100010"b), 13 34 bin_integer initial("000110001"b), 13 35 dec_integer initial("000110011"b), 13 36 fixed_bin initial("000110000"b), 13 37 fixed_dec initial("000110010"b), 13 38 float_bin initial("000110100"b), 13 39 float_dec initial("000110110"b), 13 40 i_bin_integer initial("000111001"b), 13 41 i_dec_integer initial("000111011"b), 13 42 i_fixed_bin initial("000111000"b), 13 43 i_fixed_dec initial("000111010"b), 13 44 i_float_bin initial("000111100"b), 13 45 i_float_dec initial("000111110"b)) bit (9) aligned internal static options (constant); 13 46 13 47 dcl ( is_identifier initial ("100000000"b), /* token type masks */ 13 48 is_isub initial ("010000000"b), 13 49 is_delimiter initial ("001000000"b), 13 50 is_constant initial ("000100000"b), 13 51 is_arith_constant initial ("000010000"b), /* N.B. not really a mask...s/b "000110000"b */ 13 52 is_arithmetic_constant initial ("000110000"b), 13 53 is_imaginary_constant initial ("000111000"b), 13 54 is_float_constant initial ("000110100"b), 13 55 is_decimal_constant initial ("000110010"b), 13 56 is_integral_constant initial ("000110001"b) 13 57 ) bit(9) internal static aligned options(constant); 13 58 13 59 /* END INCLUDE FILE ... token_types.incl.pl1 */ 91 92 /* This procedure parses expressions using a simple operator 93* precedence technique. The syntax parsed is 94* 95* ::= [ ]... 96* 97* where the nth operator and its operands are stacked if the 98* n+1st operator has higher precedence. The primitive is parsed by 99* the internal entry called "primitive". The primitives include 100* parenthesized expressions, prefix operators, and exponentiation. */ 101 102 t = pl1_stat_$token_list_ptr; 103 k = i; 104 si = 0; 105 stack(0) = primitive(k); 106 107 fetchop: type = t_table.type; 108 109 checkop: if type & is_delimiter 110 then if type <= assignment 111 then do; 112 113 if type = not then goto fail; 114 115 if si ^= 0 /* If past first op then check prec. */ 116 then do; 117 118 opindex = binary(substr(stack(si-1) -> token.type,5,5)); 119 if precedence(opindex) >= 120 precedence(fixed(substr(type,5,5),5)) then go to unstack; 121 122 end; 123 124 stackop: si = si + 1; 125 stack(si) = token_list(k); 126 si = si + 1; 127 k = k + 1; 128 stack(si) = primitive(k); 129 130 go to fetchop; 131 132 end; 133 134 if si = 0 then go to succeed; 135 136 unstackop:opindex = binary(substr(stack(si-1) -> token.type,5,5)); 137 138 unstack: r2 = stack(si-2); 139 r3 = stack(si); 140 141 if opindex = 9 142 then do; 143 144 /* attempt to optimize cat (||) */ 145 146 if r2 -> node.type = token_node 147 then if r3 -> node.type = token_node 148 then if r2 -> token.type & r3 -> token.type & is_constant 149 then do; 150 q = evaluate(op_table(9),r2,r3); 151 go to pop; 152 end; 153 end; 154 155 if opindex >= 4 156 then do; 157 158 /* operator not + - or * */ 159 160 make_op: q = create_operator((op_table(opindex)),3); 161 q -> operator.operand(2) = r2; 162 q -> operator.operand(3) = r3; 163 164 pop: si = si - 2; 165 stack(si) = q; 166 167 go to checkop; 168 end; 169 170 if r2 -> node.type ^= token_node then goto make_op; 171 if r3 -> node.type ^= token_node then goto make_op; 172 173 /* Check for constants on both sides of operator */ 174 175 if (r2 -> token.type & is_arithmetic_constant) ^= is_arithmetic_constant then goto make_op; 176 if r2 -> token.type >= i_fixed_bin then goto make_op; 177 178 if (r3 -> token.type & is_arithmetic_constant) ^= is_arithmetic_constant then goto make_op; 179 180 if r2 -> token.loc ^= r3 -> token.loc then go to make_op; /* require both to have same "p" attribute */ 181 182 /* Check for "complex" constant */ 183 184 if r3 -> token.type >= i_fixed_bin 185 then do; 186 if opindex >= 3 then goto make_op; 187 188 oploc = search(substr(r3->token.string,2),"+-"); /* This block of code is to ensure */ 189 if oploc ^= 0 then do; /* that r3 points to an imaginary, */ 190 eloc = index(r3->token.string,"e"); /* not complex, number. */ 191 if eloc = 0 then goto make_op; 192 if oploc < eloc then goto make_op; 193 if search(substr(r3->token.string,eloc+2),"+-") ^= 0 then goto make_op; 194 end; 195 196 /* form new token representing the complex constant */ 197 198 if opindex = 1 /* addition */ 199 then if substr(r3 -> token.string,1,1) = "-" 200 then do; 201 j = 2; 202 ch = "-"; 203 end; 204 else do; 205 ch = "+"; 206 if substr(r3 -> token.string,1,1) = "+" then j = 2; else j = 1; 207 end; 208 else if substr(r3 -> token.string,1,1) = "-" 209 then do; 210 j = 2; 211 ch = "+"; 212 end; 213 else do; 214 ch = "-"; 215 if substr(r3 -> token.string,1,1) = "+" then j = 2; else j = 1; 216 end; 217 218 q = create_token$protected (r2 -> token.string || ch || substr (r3 ->token.string, j), (r3 -> token.type), (r2 -> token.loc)); 219 goto pop; 220 end; 221 222 /* have constant operands, evalute expression if possible */ 223 224 q = evaluate((op_table(opindex)),r2,r3); 225 goto pop; 226 227 fail: r = null; 228 go to ret; 229 230 succeed: r = stack(0); 231 i = k; 232 233 ret: return(r); 234 235 /* Primitive parses prefix expressions, exponentiation operators, 236* and parenthesized expressions. */ 237 238 primitive: proc(i) returns(ptr); 239 240 dcl (p,q) ptr, 241 i fixed bin(15), 242 (ttype, 243 type) bit(9) aligned; 244 245 type = tlist(i) -> token.type; 246 247 if type = plus 248 then do; 249 i = i + 1; 250 p = primitive(i); 251 if p -> node.type = token_node 252 then do; 253 ttype, type = p -> token.type; 254 if (type & is_arithmetic_constant) = is_arithmetic_constant 255 then if substr(p->token.string,1,1) = "-" | substr(p->token.string,1,1) = "+" 256 then q = p; 257 else q = create_token$protected ("+" || p -> token.string, ttype, (p -> token.loc)); 258 else go to plusop; 259 end; 260 else do; 261 plusop: 262 q = create_operator((prefix_plus),2); 263 q->operator.operand(2) = p; 264 end; 265 266 end; 267 268 else if type = minus 269 then do; 270 271 i = i + 1; 272 p = primitive(i); 273 if p -> node.type = token_node 274 then do; 275 276 ttype, type = p -> token.type; 277 278 if (type & is_arithmetic_constant) = is_arithmetic_constant 279 then if substr(p->token.string,1,1) = "-" 280 then q = create_token$protected (substr (p -> token.string, 2), ttype, (p -> token.loc)); 281 else if substr (p -> token.string, 1, 1) = "+" 282 then q = create_token$protected ("-" || substr (p -> token.string, 2), ttype, (p -> token.loc)); 283 else q = create_token$protected ("-" || p -> token.string, ttype, (p -> token.loc)); 284 else go to negop; 285 end; 286 else do; 287 288 negop: q = create_operator((negate), 2); 289 q -> operator.operand(2) = p; 290 291 end; 292 293 end; 294 295 else if type = not 296 then do; 297 298 i = i + 1; 299 q = create_operator((not_bits), 2); 300 q -> operator.operand(2) = primitive(i); 301 302 end; 303 304 else if type = left_parn 305 then do; 306 307 i = i + 1; 308 q = expression_parse(i,cblock); 309 if q = null then go to phail; 310 if tlist(i) -> token.type ^= right_parn then go to phail; 311 312 i = i + 1; 313 end; 314 315 else if type & is_constant 316 then do; 317 318 q = tlist(i); 319 i = i + 1; 320 321 end; 322 323 else do; 324 q = reference_parse(i,cblock); 325 if q = null then go to phail; 326 end; 327 328 if tlist(i) -> token.type = expon 329 then do; 330 331 i = i + 1; 332 p = q; 333 q = create_operator((exp), 3); 334 q -> operator.operand(2) = p; 335 q -> operator.operand(3) = primitive(i); 336 337 end; 338 339 return(q); 340 341 phail: go to fail; 342 343 end primitive; 344 end expression_parse; SOURCE FILES USED IN THIS COMPILATION. LINE NUMBER DATE MODIFIED NAME PATHNAME 0 04/24/92 1102.3 expression_parse.pl1 >spec>install>MR12.5-1011>expression_parse.pl1 85 1 04/24/92 1056.9 parse.incl.pl1 >spec>install>MR12.5-1011>parse.incl.pl1 1-175 2 08/01/89 1339.9 language_utility.incl.pl1 >ldd>incl>language_utility.incl.pl1 2-307 3 05/06/74 1846.9 source_id_descriptor.incl.pl1 >ldd>incl>source_id_descriptor.incl.pl1 2-325 4 05/06/74 1846.9 source_id_descriptor.incl.pl1 >ldd>incl>source_id_descriptor.incl.pl1 2-335 5 05/06/74 1846.9 source_id_descriptor.incl.pl1 >ldd>incl>source_id_descriptor.incl.pl1 2-374 6 05/06/74 1846.9 source_id_descriptor.incl.pl1 >ldd>incl>source_id_descriptor.incl.pl1 2-386 7 05/06/74 1846.9 source_id_descriptor.incl.pl1 >ldd>incl>source_id_descriptor.incl.pl1 86 8 09/14/77 1805.7 token_list.incl.pl1 >ldd>incl>token_list.incl.pl1 87 9 09/14/77 1805.7 token.incl.pl1 >ldd>incl>token.incl.pl1 88 10 07/21/80 1646.3 nodes.incl.pl1 >ldd>incl>nodes.incl.pl1 89 11 07/21/80 1646.3 operator.incl.pl1 >ldd>incl>operator.incl.pl1 90 12 04/07/83 1735.0 op_codes.incl.pl1 >ldd>incl>op_codes.incl.pl1 91 13 11/30/78 1327.4 token_types.incl.pl1 >ldd>incl>token_types.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. assignment constant bit(9) initial dcl 13-3 ref 109 binary builtin function dcl 21 ref 118 136 cblock parameter pointer dcl 17 set ref 11 308* 324* ch 000107 automatic char(1) packed unaligned dcl 26 set ref 202* 205* 211* 214* 218 create_operator 000020 constant entry external dcl 2-152 ref 160 261 288 299 333 create_token$protected 000022 constant entry external dcl 2-199 ref 218 257 278 281 283 eloc 000105 automatic fixed bin(15,0) dcl 26 set ref 190* 191 192 193 evaluate 000012 constant entry external dcl 1-67 ref 150 224 exp constant bit(9) initial dcl 12-8 ref 333 expon constant bit(9) initial dcl 13-3 ref 328 expression_parse 000014 constant entry external dcl 1-73 ref 308 fixed builtin function dcl 21 ref 119 i parameter fixed bin(15,0) dcl 240 in procedure "primitive" set ref 238 245 249* 249 250* 271* 271 272* 298* 298 300* 307* 307 308* 310 312* 312 318 319* 319 324* 328 331* 331 335* i parameter fixed bin(15,0) dcl 17 in procedure "expression_parse" set ref 11 103 231* i_fixed_bin constant bit(9) initial dcl 13-3 ref 176 184 index builtin function dcl 21 ref 190 is_arithmetic_constant constant bit(9) initial dcl 13-47 ref 175 175 178 178 254 254 278 278 is_constant constant bit(9) initial dcl 13-47 ref 146 315 is_delimiter constant bit(9) initial dcl 13-47 ref 109 j 000102 automatic fixed bin(15,0) dcl 26 set ref 201* 206* 206* 210* 215* 215* 218 k 000103 automatic fixed bin(15,0) dcl 26 set ref 103* 105* 107 125 127* 127 128* 231 left_parn constant bit(9) initial dcl 13-3 ref 304 loc 0(18) based bit(18) level 2 packed packed unaligned dcl 9-3 ref 180 180 218 257 278 281 283 minus constant bit(9) initial dcl 13-3 ref 268 negate constant bit(9) initial dcl 12-8 ref 288 node based structure level 1 dcl 10-27 not constant bit(9) initial dcl 13-3 ref 113 295 not_bits constant bit(9) initial dcl 12-8 ref 299 null builtin function dcl 21 ref 227 309 325 op_table 000000 constant bit(9) initial array dcl 58 set ref 150* 160 224 operand 1 based pointer array level 2 packed packed unaligned dcl 11-6 set ref 161* 162* 263* 289* 300* 334* 335* operator based structure level 1 dcl 11-6 opindex 000110 automatic fixed bin(5,0) dcl 26 set ref 118* 119 136* 141 155 160 186 198 224 oploc 000106 automatic fixed bin(15,0) dcl 26 set ref 188* 189 192 p 000100 automatic pointer dcl 240 set ref 250* 251 253 254 254 254 257 257 263 272* 273 276 278 278 278 278 281 281 281 283 283 289 332* 334 pl1_stat_$token_list_ptr 000024 external static pointer dcl 8-1 ref 102 8-3 plus constant bit(9) initial dcl 13-3 ref 247 precedence 000023 constant fixed bin(15,0) initial array dcl 37 ref 119 119 prefix_plus constant bit(9) initial dcl 12-8 ref 261 q 000102 automatic pointer dcl 240 in procedure "primitive" set ref 254* 257* 261* 263 278* 281* 283* 288* 289 299* 300 308* 309 318* 324* 325 332 333* 334 335 339 q 000112 automatic pointer dcl 26 in procedure "expression_parse" set ref 150* 160* 161 162 165 218* 224* r 000100 automatic pointer dcl 17 set ref 227* 230* 233 r2 000116 automatic pointer dcl 26 set ref 138* 146 146 150* 161 170 175 176 180 218 218 224* r3 000120 automatic pointer dcl 26 set ref 139* 146 146 150* 162 171 178 180 184 188 190 193 198 206 208 215 218 218 224* reference_parse 000016 constant entry external dcl 1-150 ref 324 right_parn constant bit(9) initial dcl 13-3 ref 310 search builtin function dcl 21 ref 188 193 si 000104 automatic fixed bin(15,0) dcl 26 set ref 104* 115 118 124* 124 125 126* 126 128 134 136 138 139 164* 164 165 size 3 based fixed bin(9,0) level 2 dcl 9-3 ref 188 190 193 198 206 208 215 218 218 254 254 257 278 278 278 281 281 283 stack 000122 automatic pointer array dcl 26 set ref 105* 118 125* 128* 136 138 139 165* 230 string 4 based char level 2 dcl 9-3 ref 188 190 193 198 206 208 215 218 218 254 254 257 278 278 278 281 281 283 substr builtin function dcl 21 ref 118 119 136 188 193 198 206 208 215 218 254 254 278 278 278 281 281 t 000010 internal static pointer dcl 82 set ref 102* 245 310 318 328 t_table based structure level 1 dcl 8-11 tlist based pointer array dcl 82 ref 245 310 318 328 token based structure level 1 dcl 9-3 token_list based pointer array dcl 8-2 ref 107 125 token_list_pointer 000154 automatic pointer initial dcl 8-3 set ref 107 125 8-3* token_node constant bit(9) initial dcl 10-5 ref 146 146 170 171 251 273 ttype 000104 automatic bit(9) dcl 240 set ref 253* 257* 276* 278* 281* 283* type 000114 automatic bit(9) dcl 26 in procedure "expression_parse" set ref 107* 109 109 113 119 type 0(09) based bit(9) level 2 in structure "t_table" packed packed unaligned dcl 8-11 in procedure "expression_parse" ref 107 type 0(09) based bit(9) level 2 in structure "token" packed packed unaligned dcl 9-3 in procedure "expression_parse" ref 118 136 146 146 175 176 178 184 218 245 253 276 310 328 type 000105 automatic bit(9) dcl 240 in procedure "primitive" set ref 245* 247 253* 254 268 276* 278 295 304 315 type based bit(9) level 2 in structure "node" packed packed unaligned dcl 10-27 in procedure "expression_parse" ref 146 146 170 171 251 273 NAMES DECLARED BY DECLARE STATEMENT AND NEVER REFERENCED. a_format internal static bit(9) initial dcl 12-8 abs_fun internal static bit(9) initial dcl 12-8 acos_fun internal static bit(9) initial dcl 12-8 acosd_fun internal static bit(9) initial dcl 12-8 add internal static bit(9) initial dcl 12-8 addbitno_fun internal static bit(9) initial dcl 12-8 addcharno_fun internal static bit(9) initial dcl 12-8 addr builtin function dcl 21 addr_fun internal static bit(9) initial dcl 12-8 addr_fun_bits internal static bit(9) initial dcl 12-8 addrel_fun internal static bit(9) initial dcl 12-8 adjust_count 000000 constant entry external dcl 2-20 allocation_fun internal static bit(9) initial dcl 12-8 allot_auto internal static bit(9) initial dcl 12-8 allot_based internal static bit(9) initial dcl 12-8 allot_ctl internal static bit(9) initial dcl 12-8 allot_var internal static bit(9) initial dcl 12-8 and internal static bit(9) initial dcl 13-3 and_bits internal static bit(9) initial dcl 12-8 array_node internal static bit(9) initial dcl 10-5 arrow internal static bit(9) initial dcl 13-3 asin_fun internal static bit(9) initial dcl 12-8 asind_fun internal static bit(9) initial dcl 12-8 assign internal static bit(9) initial dcl 12-8 assign_by_name internal static bit(9) initial dcl 12-8 assign_round internal static bit(9) initial dcl 12-8 assign_size_ck internal static bit(9) initial dcl 12-8 assign_zero internal static bit(9) initial dcl 12-8 asterisk internal static bit(9) initial dcl 13-3 atan_fun internal static bit(9) initial dcl 12-8 atand_fun internal static bit(9) initial dcl 12-8 attribute_parse 000000 constant entry external dcl 1-11 b_format internal static bit(9) initial dcl 12-8 baseno_fun internal static bit(9) initial dcl 12-8 baseptr_fun internal static bit(9) initial dcl 12-8 bin_integer internal static bit(9) initial dcl 13-3 binary_to_octal_string 000000 constant entry external dcl 2-38 binary_to_octal_var_string 000000 constant entry external dcl 2-43 bindec 000000 constant entry external dcl 2-23 bindec$vs 000000 constant entry external dcl 2-28 binoct 000000 constant entry external dcl 2-33 bit_pointer internal static bit(9) initial dcl 12-8 bit_string internal static bit(9) initial dcl 13-3 bit_to_char internal static bit(9) initial dcl 12-8 bit_to_word internal static bit(9) initial dcl 12-8 bitno_fun internal static bit(9) initial dcl 12-8 block_node internal static bit(9) initial dcl 10-5 bn_format internal static bit(9) initial dcl 12-8 bool_fun internal static bit(9) initial dcl 12-8 bound_ck internal static bit(9) initial dcl 12-8 bound_node internal static bit(9) initial dcl 10-5 by_name_agg_node internal static bit(9) initial dcl 10-5 byte_fun internal static bit(9) initial dcl 12-8 c_format internal static bit(9) initial dcl 12-8 cat internal static bit(9) initial dcl 13-3 cat_string internal static bit(9) initial dcl 12-8 ceil_fun internal static bit(9) initial dcl 12-8 char_string internal static bit(9) initial dcl 13-3 char_to_word internal static bit(9) initial dcl 12-8 charno_fun internal static bit(9) initial dcl 12-8 clock_fun internal static bit(9) initial dcl 12-8 close_file internal static bit(9) initial dcl 12-8 codeptr_fun internal static bit(9) initial dcl 12-8 colon internal static bit(9) initial dcl 13-3 column_format internal static bit(9) initial dcl 12-8 comma internal static bit(9) initial dcl 13-3 compare_expression 000000 constant entry external dcl 2-48 complex_fun internal static bit(9) initial dcl 12-8 conjg_fun internal static bit(9) initial dcl 12-8 constant_length 000000 constant entry external dcl 2-54 context 000000 constant entry external dcl 1-17 context_node internal static bit(9) initial dcl 10-5 convert 000000 constant entry external dcl 2-60 convert$from_builtin 000000 constant entry external dcl 2-72 convert$to_integer 000000 constant entry external dcl 2-66 convert$to_target 000000 constant entry external dcl 2-88 convert$to_target_fb 000000 constant entry external dcl 2-82 convert$validate 000000 constant entry external dcl 2-78 copy_expression 000000 constant entry external dcl 2-94 copy_expression$copy_sons 000000 constant entry external dcl 2-99 copy_string internal static bit(9) initial dcl 12-8 copy_unique_expression 000000 constant entry external dcl 2-103 copy_words internal static bit(9) initial dcl 12-8 cos_fun internal static bit(9) initial dcl 12-8 cosd_fun internal static bit(9) initial dcl 12-8 create_array 000000 constant entry external dcl 2-108 create_block 000000 constant entry external dcl 2-112 create_bound 000000 constant entry external dcl 2-118 create_context 000000 constant entry external dcl 2-122 create_cross_reference 000000 constant entry external dcl 2-128 create_default 000000 constant entry external dcl 2-132 create_identifier 000000 constant entry external dcl 2-136 create_label 000000 constant entry external dcl 2-140 create_list 000000 constant entry external dcl 2-147 create_reference 000000 constant entry external dcl 2-158 create_statement 000000 constant entry external dcl 2-163 create_statement$prologue 000000 constant entry external dcl 2-171 create_storage 000000 constant entry external dcl 2-179 create_symbol 000000 constant entry external dcl 2-184 create_token 000000 constant entry external dcl 2-191 create_token$init_hash_table 000000 constant entry external dcl 2-197 cross_reference_node internal static bit(9) initial dcl 10-5 data_list_parse 000000 constant entry external dcl 1-22 dec_integer internal static bit(9) initial dcl 13-3 decbin 000000 constant entry external dcl 2-206 declare_constant 000000 constant entry external dcl 2-211 declare_constant$bit 000000 constant entry external dcl 2-219 declare_constant$char 000000 constant entry external dcl 2-224 declare_constant$desc 000000 constant entry external dcl 2-229 declare_constant$integer 000000 constant entry external dcl 2-234 declare_descriptor 000000 constant entry external dcl 2-239 declare_descriptor$ctl 000000 constant entry external dcl 2-249 declare_descriptor$param 000000 constant entry external dcl 2-259 declare_integer 000000 constant entry external dcl 2-269 declare_label 000000 constant entry external dcl 1-29 declare_parse 000000 constant entry external dcl 1-35 declare_parse$abort 000000 constant entry external dcl 1-40 declare_picture 000000 constant entry external dcl 2-274 declare_picture_temp 000000 constant entry external dcl 2-279 declare_pointer 000000 constant entry external dcl 2-287 declare_temporary 000000 constant entry external dcl 2-292 decode_node_id 000000 constant entry external dcl 2-300 decode_source_id 000000 constant entry external dcl 2-306 default_node internal static bit(9) initial dcl 10-5 default_parse 000000 constant entry external dcl 1-44 delete_file internal static bit(9) initial dcl 12-8 desc_size internal static bit(9) initial dcl 12-8 descriptor_parse 000000 constant entry external dcl 1-49 digit_to_bit internal static bit(9) initial dcl 12-8 div internal static bit(9) initial dcl 12-8 do_fun internal static bit(9) initial dcl 12-8 do_parse 000000 constant entry external dcl 1-56 do_spec internal static bit(9) initial dcl 12-8 e_format internal static bit(9) initial dcl 12-8 empty_area internal static bit(9) initial dcl 12-8 enable_on internal static bit(9) initial dcl 12-8 environmentptr_fun internal static bit(9) initial dcl 12-8 eq internal static bit(9) initial dcl 13-3 equal internal static bit(9) initial dcl 12-8 error 000000 constant entry external dcl 2-314 error$omit_text 000000 constant entry external dcl 2-319 error_ 000000 constant entry external dcl 2-324 error_$finish 000000 constant entry external dcl 2-343 error_$initialize_error 000000 constant entry external dcl 2-341 error_$no_text 000000 constant entry external dcl 2-334 ex_prologue internal static bit(9) initial dcl 12-8 exp_fun internal static bit(9) initial dcl 12-8 f_format internal static bit(9) initial dcl 12-8 fixed_bin internal static bit(9) initial dcl 13-3 fixed_dec internal static bit(9) initial dcl 13-3 float_bin internal static bit(9) initial dcl 13-3 float_dec internal static bit(9) initial dcl 13-3 floor_fun internal static bit(9) initial dcl 12-8 format_list_parse 000000 constant entry external dcl 1-79 format_value_node internal static bit(9) initial dcl 10-5 fortran_read internal static bit(9) initial dcl 12-8 fortran_write internal static bit(9) initial dcl 12-8 free_based internal static bit(9) initial dcl 12-8 free_ctl internal static bit(9) initial dcl 12-8 free_node 000000 constant entry external dcl 2-345 free_var internal static bit(9) initial dcl 12-8 ftn_file_manip internal static bit(9) initial dcl 12-8 ftn_trans_loop internal static bit(9) initial dcl 12-8 ge internal static bit(9) initial dcl 13-3 get_array_size 000000 constant entry external dcl 2-348 get_data_trans internal static bit(9) initial dcl 12-8 get_edit_trans internal static bit(9) initial dcl 12-8 get_file internal static bit(9) initial dcl 12-8 get_list_trans internal static bit(9) initial dcl 12-8 get_size 000000 constant entry external dcl 2-352 get_string internal static bit(9) initial dcl 12-8 greater_or_equal internal static bit(9) initial dcl 12-8 greater_than internal static bit(9) initial dcl 12-8 gt internal static bit(9) initial dcl 13-3 half_to_word internal static bit(9) initial dcl 12-8 i_bin_integer internal static bit(9) initial dcl 13-3 i_dec_integer internal static bit(9) initial dcl 13-3 i_fixed_dec internal static bit(9) initial dcl 13-3 i_float_bin internal static bit(9) initial dcl 13-3 i_float_dec internal static bit(9) initial dcl 13-3 identifier internal static bit(9) initial dcl 13-3 if_parse 000000 constant entry external dcl 1-87 imag_fun internal static bit(9) initial dcl 12-8 index_after_fun internal static bit(9) initial dcl 12-8 index_before_fun internal static bit(9) initial dcl 12-8 index_fun internal static bit(9) initial dcl 12-8 index_rev_fun internal static bit(9) initial dcl 12-8 io_statement_parse 000000 constant entry external dcl 1-96 is_arith_constant internal static bit(9) initial dcl 13-47 is_decimal_constant internal static bit(9) initial dcl 13-47 is_float_constant internal static bit(9) initial dcl 13-47 is_identifier internal static bit(9) initial dcl 13-47 is_imaginary_constant internal static bit(9) initial dcl 13-47 is_integral_constant internal static bit(9) initial dcl 13-47 is_isub internal static bit(9) initial dcl 13-47 isub internal static bit(9) initial dcl 13-3 join internal static bit(9) initial dcl 12-8 jump internal static bit(9) initial dcl 12-8 jump_false internal static bit(9) initial dcl 12-8 jump_if_eq internal static bit(9) initial dcl 12-8 jump_if_ge internal static bit(9) initial dcl 12-8 jump_if_gt internal static bit(9) initial dcl 12-8 jump_if_le internal static bit(9) initial dcl 12-8 jump_if_lt internal static bit(9) initial dcl 12-8 jump_if_ne internal static bit(9) initial dcl 12-8 jump_true internal static bit(9) initial dcl 12-8 l_parn internal static bit(9) initial dcl 12-8 label_array_element_node internal static bit(9) initial dcl 10-5 label_node internal static bit(9) initial dcl 10-5 le internal static bit(9) initial dcl 13-3 length_fun internal static bit(9) initial dcl 12-8 less_or_equal internal static bit(9) initial dcl 12-8 less_than internal static bit(9) initial dcl 12-8 lex 000000 constant entry external dcl 1-106 lex$initialize_lex 000000 constant entry external dcl 1-112 lex$write_last_line 000000 constant entry external dcl 1-109 line_format internal static bit(9) initial dcl 12-8 list_node internal static bit(9) initial dcl 10-5 locate_file internal static bit(9) initial dcl 12-8 lock_file internal static bit(9) initial dcl 12-8 lock_fun internal static bit(9) initial dcl 12-8 log10_fun internal static bit(9) initial dcl 12-8 log2_fun internal static bit(9) initial dcl 12-8 log_fun internal static bit(9) initial dcl 12-8 loop internal static bit(9) initial dcl 12-8 lt internal static bit(9) initial dcl 13-3 machine_state_node internal static bit(9) initial dcl 10-5 make_desc internal static bit(9) initial dcl 12-8 max_fun internal static bit(9) initial dcl 12-8 max_number_of_operands internal static fixed bin(15,0) initial dcl 11-15 merge_attributes 000000 constant entry external dcl 2-355 min_fun internal static bit(9) initial dcl 12-8 mod_bit internal static bit(9) initial dcl 12-8 mod_byte internal static bit(9) initial dcl 12-8 mod_fun internal static bit(9) initial dcl 12-8 mod_half internal static bit(9) initial dcl 12-8 mod_word internal static bit(9) initial dcl 12-8 mult internal static bit(9) initial dcl 12-8 n automatic fixed bin(15,0) dcl 26 ne internal static bit(9) initial dcl 13-3 ngt internal static bit(9) initial dcl 13-3 nlt internal static bit(9) initial dcl 13-3 no_token internal static bit(9) initial dcl 13-3 nop internal static bit(9) initial dcl 12-8 not_equal internal static bit(9) initial dcl 12-8 off_fun internal static bit(9) initial dcl 12-8 on_parse 000000 constant entry external dcl 1-116 on_parse$revert 000000 constant entry external dcl 1-123 open_file internal static bit(9) initial dcl 12-8 operator_node internal static bit(9) initial dcl 10-5 optimizer 000000 constant entry external dcl 2-361 or internal static bit(9) initial dcl 13-3 or_bits internal static bit(9) initial dcl 12-8 pack internal static bit(9) initial dcl 12-8 page_format internal static bit(9) initial dcl 12-8 param_desc_ptr internal static bit(9) initial dcl 12-8 param_ptr internal static bit(9) initial dcl 12-8 parse 000000 constant entry external dcl 1-128 parse_error 000000 constant entry external dcl 2-364 parse_error$no_text 000000 constant entry external dcl 2-368 percent internal static bit(9) initial dcl 13-3 period internal static bit(9) initial dcl 13-3 picture_format internal static bit(9) initial dcl 12-8 pl1_error_print$listing_segment 000000 constant entry external dcl 2-384 pl1_error_print$write_out 000000 constant entry external dcl 2-372 pl1_mod_fun internal static bit(9) initial dcl 12-8 pl1_print$for_lex 000000 constant entry external dcl 2-418 pl1_print$non_varying 000000 constant entry external dcl 2-398 pl1_print$non_varying_nl 000000 constant entry external dcl 2-402 pl1_print$string_pointer 000000 constant entry external dcl 2-406 pl1_print$string_pointer_nl 000000 constant entry external dcl 2-410 pl1_print$unaligned_nl 000000 constant entry external dcl 2-414 pl1_print$varying 000000 constant entry external dcl 2-392 pl1_print$varying_nl 000000 constant entry external dcl 2-395 pl1_stat_$statement_id external static structure level 1 packed packed unaligned dcl 8-6 procedure_parse 000000 constant entry external dcl 1-133 process_entry 000000 constant entry external dcl 1-143 ptr_fun internal static bit(9) initial dcl 12-8 put_control internal static bit(9) initial dcl 12-8 put_data_trans internal static bit(9) initial dcl 12-8 put_edit_trans internal static bit(9) initial dcl 12-8 put_field internal static bit(9) initial dcl 12-8 put_field_chk internal static bit(9) initial dcl 12-8 put_file internal static bit(9) initial dcl 12-8 put_list_trans internal static bit(9) initial dcl 12-8 put_string internal static bit(9) initial dcl 12-8 r_format internal static bit(9) initial dcl 12-8 r_parn internal static bit(9) initial dcl 12-8 range_ck internal static bit(9) initial dcl 12-8 rank_fun internal static bit(9) initial dcl 12-8 read_file internal static bit(9) initial dcl 12-8 real_fun internal static bit(9) initial dcl 12-8 record_io internal static bit(9) initial dcl 12-8 refer internal static bit(9) initial dcl 12-8 refer_extent 000000 constant entry external dcl 2-426 reference_node internal static bit(9) initial dcl 10-5 rel_fun internal static bit(9) initial dcl 12-8 repeat_fun internal static bit(9) initial dcl 12-8 reserve$clear 000000 constant entry external dcl 2-430 reserve$declare_lib 000000 constant entry external dcl 2-434 reserve$read_lib 000000 constant entry external dcl 2-439 reserve$rename_parse 000000 constant entry external dcl 1-156 return_bits internal static bit(9) initial dcl 12-8 return_string internal static bit(9) initial dcl 12-8 return_value internal static bit(9) initial dcl 12-8 return_words internal static bit(9) initial dcl 12-8 reverse_fun internal static bit(9) initial dcl 12-8 revert_on internal static bit(9) initial dcl 12-8 rewrite_file internal static bit(9) initial dcl 12-8 round_fun internal static bit(9) initial dcl 12-8 search_fun internal static bit(9) initial dcl 12-8 search_rev_fun internal static bit(9) initial dcl 12-8 segno_fun internal static bit(9) initial dcl 12-8 semantic_translator 000000 constant entry external dcl 2-444 semantic_translator$abort 000000 constant entry external dcl 2-446 semantic_translator$error 000000 constant entry external dcl 2-450 semi_colon internal static bit(9) \HHN{G{ ;"ϣ`^4A.y  0/~{H{x ;"ϣ`^4A.y  0/~{\O\HVHz{TH2{L e;"yϣ`^4A.y  0/~{0Q+\HH{(H^{  @;"m.ϣ`^4A.y  0/~{Sa\HHzHz 9;"_ϣ`^4A.y  0/~zT\HHzHzȊ @;"Qϣ`^4A.y  0/~zV-\HH*zHz ;"D~ϣ`^4A.y  0/~zX\H2HVzxHzp z;"7ϣ`^4A.y  0/~zTY\H^HzLH:zD ;"(ϣ`^4A.y  0/~z([\HHz Hfz [;"Vϣ`^4A.y  0/~z]\HHzHz ;"^ϣ`^4A.y  0/~z_\HIzHz *;"ϣ`^4A.y  0/~z`V\II2zHz ;"6ϣ`^4A.y  0/~zxb\I:I^zpIzh ;"ϣ`^4A.y  0/~zLc\IfIzDIBz< j;"ٖϣ`^4A.y  0/~z eT\IIzInz @;"̮ϣ`^4A.y  0/~yg\IIyIy ;;"^ϣ`^4A.y  0/~yh\IIyIy ;"&ϣ`^4A.y  0/~yj"\II:yIy @;"ϣ`^4A.y  0/~yplm\IBIfyhIy` w@;"nϣ`^4A.y  0/~yDm\InIy\F"FF}E};#ϣ`^4A.y  0/~}d'\FNFr}\F*}Ta;#ϣ`^4A.y  0/~}8)\FzF}0FV}(;#^ϣ`^4A.y  0/~} F:}G@;#nϣ`^4A.y  0/~|-9\FF|F|؊;#ϣ`^4A.y  0/~|.\FF|F|;#vϣ`^4A.y  0/~|0\F"FF|F|;#uϣ`^4A.y  0/~|d2*\FNF|\F*|T;#hϣ`^4A.y  0/~|8FV|0Y@;#[ϣ`^4A.y  0/~|5\FF| Fz|@;#Nϣ`^4A.y  0/~|7 \FF|F|؊';#A^ϣ`^4A.y  0/~|8;\FG|F|;#4Fϣ`^4A.y  0/~|:~\G"GF|F|;#'fϣ`^4A.y  0/~|d;\GNGr|\G*|Te;#ϣ`^4A.y  0/~|8=.\GzG|0GV|(;# ϣ`^4A.y  0/~| ?d\GG|G{8;"ϣ`^4A.y  0/~{@\GG{G{Њ;"ϣ`^4A.y ----------------------------------------------------------- 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