COMPILATION LISTING OF SEGMENT linus_lila_term Compiled by: Multics PL/I Compiler, Release 28e, of February 14, 1985 Compiled at: Honeywell Multics Op. - System M Compiled on: 07/29/86 1004.4 mst Tue Options: optimize map 1 /* *********************************************************** 2* * * 3* * * 4* * Copyright, (C) Honeywell Information Systems Inc., 1981 * 5* * * 6* * * 7* *********************************************************** */ 8 9 /* ****************************************************** 10* * * 11* * * 12* * Copyright (c) 1972 by Massachusetts Institute of * 13* * Technology and Honeywell Information Systems, Inc. * 14* * * 15* * * 16* ****************************************************** */ 17 18 linus_lila_term: 19 proc (lcb_ptr, lsh_ptr, td_ptr, code); 20 21 /* DESCRIPTION: 22* 23* This procedure processes a LINUS term and produces a MRDS term string. 24* 25* 26* 27* HISTORY: 28* 29* 77-08-01 J. A. Weeldreyer: Initially written. 30* 31* 78-04-01 J. A. Weeldreyer: Modified to give better diagnostics for 32* constant expr. of scalar funs. 33* 34* 78-08-01 J. A. Weeldreyer: Modified to conform to new token data. 35* 36* 80-03-13 Rickie E. Brinegar: Modified to use a work area defined on 37* lcb.lila_area_ptr instead of getting system free area. 38* 39* 81-07-15 Rickie E. Brinegar: Removed useless cleanup condition handler. 40* 41* 81-11-03 DJ Schimke: Modified to allow constant -> op -> column_spec 42* ordering for expressions rather than only column_spec -> op -> constant. 43**/ 44 1 1 /* BEGIN INCLUDE FILE linus_lcb.incl.pl1 -- jaw 8/30/77 */ 1 2 1 3 1 4 1 5 /****^ HISTORY COMMENTS: 1 6* 1) change(86-04-23,Dupuis), approve(86-05-23,MCR7188), audit(86-07-23,GWMay), 1 7* install(86-07-29,MR12.0-1106): 1 8* Added general_work_area_ptr and renamed sfr_ptr to 1 9* force_retrieve_scope_ptr. 1 10* END HISTORY COMMENTS */ 1 11 1 12 1 13 /* HISTORY: 1 14* 1 15* 78-09-29 J. C. C. Jagernauth: Modified for MR7.0. 1 16* 1 17* 81-05-11 Rickie E. Brinegar: added security bit and andministrator bit as 1 18* a part of the attribute level control work. 1 19* 1 20* 81-06-17 Rickie E. Brinegar: deleted the sd_ptr as a part of removing the 1 21* scope_data structure from LINUS. LINUS now depends totally on MRDS for 1 22* scope information. 1 23* 1 24* 81-11-11 Rickie E. Brinegar: added the timing bit and three fields for 1 25* retaining various vcpu times to be collected when in timing mode. The 1 26* times to be collected are: LINUS parsing time, LINUS processing time, and 1 27* MRDS processing time. 1 28* 1 29* 82-01-15 DJ Schimke: Added the build_increment and build_start fields as 1 30* part of the line numbering implementation. This allows for possible later 1 31* LINUS control of the build defaults. 1 32* 1 33* 82-03-01 Paul W. Benjamin: Removed linus_prompt_chars_ptr, as that 1 34* information is now retained by ssu_. Removed parse_timer as no longer 1 35* meaningful. Added linus_version. Added iteration bit. Added 6 entry 1 36* variables for ssu_ replaceable procedures. Added actual_input_iocbp. 1 37* 1 38* 82-06-23 Al Dupuis: Added subsystem_control_info_ptr, 1 39* subsystem_invocation_level, and selection_expression_identifier. 1 40* 1 41* 82-08-26 DJ Schimke: Added report_control_info_ptr, and 1 42* table_control_info_ptr. 1 43* 1 44* 82-10-19 DJ Schimke: Added ssu_abort_line. 1 45* 1 46* 83-06-06 Bert Moberg: Added print_search_order (pso) and no_optimize (no_ot) 1 47* 1 48* 83-04-07 DJ Schimke: Added temp_seg_info_ptr. 1 49* 1 50* 83-08-26 Al Dupuis: Added query_temp_segment_ptr. 1 51**/ 1 52 1 53 dcl 1 lcb aligned based (lcb_ptr), /* LINUS control block */ 1 54 2 db_index fixed bin (35), /* index of open data base, or 0 */ 1 55 2 rb_len fixed bin (21), /* length of request buffer */ 1 56 2 lila_count fixed bin (35), /* number of LILA text lines */ 1 57 2 lila_chars fixed bin (35), /* number of LILA source test chars */ 1 58 2 trans_id fixed bin (35), /* used by checkpoint and rollback facilities (MR7.0) */ 1 59 2 lila_fn char (32) unal, /* entry name of lila data file */ 1 60 2 prompt_flag bit (1) unal, /* on if in prompt mode */ 1 61 2 test_flag bit (1) unal, /* on if in test mode */ 1 62 2 new_version bit (1) unal init (1), /* on for new version data base (MR7.0) */ 1 63 2 secured_db bit (1) unal, /* on if the db is in a secure state */ 1 64 2 administrator bit (1) unal, /* on if the user is a db administrator */ 1 65 2 timing_mode bit (1) unal, /* on if timing is to be done */ 1 66 2 iteration bit (1) unal, /* interpret parens as iteration sets */ 1 67 2 pso_flag bit (1) unal, /* add print_search_order to select */ 1 68 2 no_ot_flag bit (1) unal, /* add no_optimize to select */ 1 69 2 reserved bit (27) unal, 1 70 2 liocb_ptr ptr, /* iocb ptr for lila file */ 1 71 2 rb_ptr ptr, /* ptr to request buffer */ 1 72 2 is_ptr ptr, /* iocb ptr for currentinput stream switch */ 1 73 2 cal_ptr ptr, /* ptr to current arg list for invoke (or null) */ 1 74 2 ttn_ptr ptr, /* pointer to table info structure */ 1 75 2 force_retrieve_scope_info_ptr ptr, /* structure pointer to force retrieve scope operation */ 1 76 2 lv_ptr ptr, /* pointer linus variables */ 1 77 2 si_ptr ptr, /* pointer to select_info structure */ 1 78 2 setfi_ptr ptr, /* pointer to set function information */ 1 79 2 sclfi_ptr ptr, /* pointer to user declared scalar fun. names */ 1 80 2 ivs_ptr ptr, /* pointer to stack of invoke iocb pointers */ 1 81 2 lit_ptr ptr, /* pointer to literal pool */ 1 82 2 lvv_ptr ptr, /* pointer to linus variable alloc. pool */ 1 83 2 rd_ptr ptr, /* point to readied files mode information (MR7.0) */ 1 84 2 rt_ptr ptr, /* point to table of relation names and their readied modes 1 85* (MR7.0) */ 1 86 2 actual_input_iocbp ptr, /* ptr to input while in macros */ 1 87 2 lila_promp_chars_ptr ptr, /* pointer to the prompt characters for lila */ 1 88 2 linus_area_ptr ptr, /* LINUS temporary segment pointer */ 1 89 2 lila_area_ptr ptr, /* LILA temporary segment pointer */ 1 90 2 i_o_area_ptr ptr, /* temporary segment pointer used by write, print, create_list */ 1 91 2 rel_array_ptr ptr, /* ptr to array of names rslt info structure 1 92* for current lila expression */ 1 93 2 unused_timer float bin (63), /* future expansion */ 1 94 2 request_time float bin (63), /* How much request time was spent 1 95* in LINUS. (-1 = user has just enabled 1 96* timing, do not report) */ 1 97 2 mrds_time float bin (63), /* How much time was spent in MRDS */ 1 98 2 build_increment fixed bin, /* default increment for build mode */ 1 99 2 build_start fixed bin, /* default start count for build mode */ 1 100 2 linus_version char (4), /* current version of LINUS */ 1 101 2 subsystem_control_info_ptr ptr, /* the same ptr passed by ssu_ to each request procedure */ 1 102 2 subsystem_invocation_level fixed bin, /* identifies this invocation of LINUS */ 1 103 2 selection_expression_identifier fixed bin, /* identifies the current processed selection expression */ 1 104 2 report_control_info_ptr ptr, /* pointer to linus_report_control_info structure */ 1 105 2 table_control_info_ptr ptr, /* pointer to linus_table control structure */ 1 106 2 temp_seg_info_ptr ptr, /* pointer to linus_temp_seg_mgr control structure */ 1 107 2 query_temp_segment_ptr ptr, /* points to temp seg used for manipulating query */ 1 108 2 general_work_area_ptr ptr, /* a freeing area for general use */ 1 109 2 word_pad (6) bit (36) unal, 1 110 /* procedures that will be optionally */ 1 111 /* replaced by the user. Saved so they */ 1 112 /* can be reinstated if desired. */ 1 113 2 ssu_abort_line entry options (variable), 1 114 2 ssu_post_request_line variable entry (ptr), 1 115 2 ssu_pre_request_line variable entry (ptr), 1 116 1 117 2 curr_lit_offset fixed bin (35), /* index of first free bit in lit. pool */ 1 118 2 curr_lv_val_offset fixed bin (35), /* index of first free bit lv. val. pool */ 1 119 2 static_area area (sys_info$max_seg_size - fixed (rel (addr (lcb.static_area))) + 1); 1 120 1 121 dcl lcb_ptr ptr; 1 122 1 123 /* END INCLUDE FILE linus_lcb.incl.pl1 */ 45 46 2 1 /* BEGIN INCLUDE FILE linus_ef_data.incl.pl1 -- jaw 7/21/77 */ 2 2 2 3 dcl 1 ef_data aligned based (ed_ptr), /* structure for passing expr. and fun. data among programs */ 2 4 2 var_name char (32), /* name of tuple variable */ 2 5 2 bit_length fixed bin (35), /* bit length of result */ 2 6 2 desc bit (36), /* descriptor of result */ 2 7 2 assn_ptr ptr, /* pointer to result value */ 2 8 2 assn_type fixed bin, /* assign_ type code of result */ 2 9 2 assn_len fixed bin (35), /* assign_ length */ 2 10 2 nmrds_items fixed bin, /* number of mrds items returned */ 2 11 2 mrds_items (linus_data_$max_expr_items), /* previously unselected mrds items referenced 2 12* in the expression */ 2 13 3 attr_name char (32), /* name of attribute */ 2 14 3 domain_name char (32), /* domain of attribute */ 2 15 3 bit_length fixed bin (35), /* attrib. bit length */ 2 16 3 desc bit (36), /* attrib. descriptor */ 2 17 3 assn_ptr ptr, /* pointer to receiving field of attr. */ 2 18 3 assn_type fixed bin, /* assign_ type code of attr */ 2 19 3 assn_len fixed bin (35), /* assign_ length for attr. */ 2 20 2 ef_ptr ptr; /* pointer to expr. status */ 2 21 2 22 dcl ed_ptr ptr; 2 23 2 24 /* END INCLUDE FILE linus_ef_data.incl.pl1 */ 47 48 3 1 /* BEGIN INCLUDE FILE linus_ls_header.incl.pl1 -- jaw 7/28/77 */ 3 2 3 3 dcl 1 ls_header aligned based (lsh_ptr), /* header for LILA stack */ 4 1 /* BEGIN INCLUDE FILE linus_ls_common.incl.pl1 -- jaw 7/12/77 */ 4 2 4 3 2 type fixed bin, /* type of frame: 4 4* 1 => header, 4 5* 2 => set value, 4 6* 3 => lila set, 4 7* 4 => lila block */ 4 8 2 back_ptr ptr, /* pointer to previous frame */ 4 9 2 fwd_ptr ptr, /* pointer to next frame */ 4 10 4 11 /* END INCLUDE FILE linus_ls_common.incl.pl1 */ 3 4 3 5 2 cur_ptr ptr, /* pointer to current frame */ 3 6 2 src_ptr ptr, /* pointer to LILA source string */ 3 7 2 trans_failed bit (1) unal, /* on if translate failed */ 3 8 2 from_token bit (1) unal, /* on if the calling routine is linus_lila_from */ 3 9 2 reserved bit (34) unal, 3 10 2 cur_pos fixed bin (35), /* current position in source string */ 3 11 2 line_data (0 : lcb.lila_count), /* data for each source line */ 3 12 3 lno char (4), /* line number */ 3 13 3 last_char fixed bin (35); /* index of last char */ 3 14 3 15 dcl lsh_ptr ptr; 3 16 3 17 /* END INCLUDE FILE linus_ls_header.incl.pl1 */ 49 50 5 1 /* BEGIN INCLUDE FILE linus_ls_set.incl.pl1 -- jaw 7/27/78 */ 5 2 5 3 dcl 1 ls_set aligned based (lss_ptr), /* lila stack frame for lila set */ 6 1 /* BEGIN INCLUDE FILE linus_ls_common.incl.pl1 -- jaw 7/12/77 */ 6 2 6 3 2 type fixed bin, /* type of frame: 6 4* 1 => header, 6 5* 2 => set value, 6 6* 3 => lila set, 6 7* 4 => lila block */ 6 8 2 back_ptr ptr, /* pointer to previous frame */ 6 9 2 fwd_ptr ptr, /* pointer to next frame */ 6 10 6 11 /* END INCLUDE FILE linus_ls_common.incl.pl1 */ 5 4 5 5 2 nselects fixed bin, /* number of items selected */ 5 6 2 nblocks fixed bin, /* number of lila blocks in stack */ 5 7 2 nops fixed bin, /* number of set operators in stack */ 5 8 2 op_stack (linus_data_$max_set_stack_size), /* the set op stack */ 5 9 3 br_cnt fixed bin (17) unal, /* bracket count of oper. */ 5 10 3 key fixed bin (17) unal, /* token key of operator */ 5 11 2 br_cnt fixed bin, /* current bracket count */ 5 12 2 dup_flag bit (1) unal, /* on if DUP encountered */ 5 13 2 unique_flag bit (1) unal, /* on if UNIQUE encountered */ 5 14 2 rb_flag bit (1) unal, /* on if right bracket allowed */ 5 15 2 lb_flag bit (1) unal, /* on if left bracket allowed */ 5 16 2 setop_flag bit (1) unal, /* on if set op allowed */ 5 17 2 select_flag bit (1) unal, /* on if lila block allowed */ 5 18 2 end_flag bit (1) unal, /* on if end of set allowed */ 5 19 2 first_block bit (1) unal, /* on if no lila block yet processed */ 5 20 2 inv_setop bit (1) unal, /* on if a lila block cannot be included in a set oper. */ 5 21 2 reserved bit (9) unal, 5 22 2 var_ind fixed bin (17) unal, /* number for next generated variable */ 5 23 2 domain_info (mrds_data_$max_select_items), /* domain info for each selected attr. */ 5 24 3 name char (32), /* domain name */ 5 25 3 bit_length fixed bin (35), /* bit length of domain */ 5 26 3 desc bit (36), /* descriptor for domain */ 5 27 3 assn_ptr ptr, /* ptr to receiving field for this attr. */ 5 28 3 assn_type fixed bin, /* assign_ type code for this domain */ 5 29 3 assn_len fixed bin (35), /* assign_ length for this domain */ 5 30 2 si_ptr ptr, /* pointer to select info structure */ 5 31 2 blk_hd_ptr ptr; /* pointer to top item of block stack */ 5 32 5 33 dcl lss_ptr ptr; 5 34 5 35 /* END INCLUDE FILE linus_ls_set.incl.pl1 */ 51 52 7 1 /* BEGIN INCLUDE FILE linus_ls_block.incl.pl1 -- jaw 8/7/78 */ 7 2 7 3 dcl 1 ls_block aligned based (lsb_ptr), /* lila stack frame for outer lila block */ 8 1 /* BEGIN INCLUDE FILE linus_ls_common.incl.pl1 -- jaw 7/12/77 */ 8 2 8 3 2 type fixed bin, /* type of frame: 8 4* 1 => header, 8 5* 2 => set value, 8 6* 3 => lila set, 8 7* 4 => lila block */ 8 8 2 back_ptr ptr, /* pointer to previous frame */ 8 9 2 fwd_ptr ptr, /* pointer to next frame */ 8 10 8 11 /* END INCLUDE FILE linus_ls_common.incl.pl1 */ 7 4 7 5 2 reserved bit (36) unal, 7 6 2 ib_level fixed bin, /* current depth of inner blocks */ 7 7 2 nrs_chars fixed bin, /* total chars. in range strings */ 7 8 2 nritems fixed bin, /* current number of range items */ 7 9 2 range_items (linus_data_$max_range_items), 7 10 3 tup_var char (32) var, /* name of linus tuple variable */ 7 11 3 mrds_var char (32) var, /* name of mrds tuple variable */ 7 12 3 rel_name char (32) var, /* name of relation */ 7 13 3 rel_index fixed bin (35), /* rel. index if temp tab */ 7 14 3 level fixed bin, /* level of block generating item */ 7 15 3 arg_ptr ptr, 7 16 3 desc_ptr ptr, 7 17 2 nselects fixed bin, /* number of select items currently defined */ 7 18 2 sel_items (mrds_data_$max_select_items) char (mrds_data_$max_token_size) var, /* the mrds select items */ 7 19 2 nprops fixed bin, /* number of operators in pred stack */ 7 20 2 pred_op_stack (linus_data_$max_pred_stack_size), 7 21 3 key fixed bin (17) unal, 7 22 3 p_cnt fixed bin (17) unal, /* current paren count */ 7 23 2 pred_pcnt fixed bin, /* current paren. count in predicate */ 7 24 2 term_op fixed bin, /* rel. op. for current term */ 7 25 2 nterms fixed bin, /* no. of terms currently in term stack */ 7 26 2 dflt_ritem fixed bin, /* index of range item to be used for default */ 7 27 2 nrange_args fixed bin, /* no. of args for temp rel indexes */ 7 28 2 rs_hd_ptr ptr, /* pointer to head of range strings */ 7 29 2 term_hd_ptr ptr, /* pointer to top item in term stack */ 7 30 2 leaf_ptr (2) ptr; /* ptr to mrds block for each leaf of current term */ 7 31 7 32 dcl lsb_ptr ptr; 7 33 7 34 /* END INCLUDE FILE linus_ls_block.incl.pl1 */ 53 54 9 1 /* BEGIN INCLUDE FILE linus_mrds_block.incl.pl1 -- jaw 7/21/77 */ 9 2 9 3 dcl 1 mrds_block aligned based (mblk_ptr), /* partial mrds selection expr */ 9 4 2 fwd_ptr ptr, /* pointer to previous item in stack */ 9 5 2 sel_offset fixed bin (35), /* offset of first select item in mrds_string */ 9 6 2 sel_length fixed bin (35), /* length of first select list in mrds string */ 9 7 2 nval_args fixed bin, /* number of value args */ 9 8 2 val_args (nval_args_init refer (mrds_block.nval_args)), 9 9 3 arg_ptr ptr, 9 10 3 desc_ptr ptr, 9 11 2 ms_len fixed bin (35), /* length of the mrds string */ 9 12 2 mrds_string char (ms_len_init refer (mrds_block.ms_len)) var; 9 13 9 14 dcl nval_args_init fixed bin; 9 15 dcl ms_len_init fixed bin (35); 9 16 dcl mblk_ptr ptr; 9 17 9 18 /* END INCLUDE FILE linus_mrds_block.incl.pl1 */ 55 56 10 1 /* BEGIN INCLUDE FILE linus_set_fn.incl.pl1 -- jaw 7/13/77 10 2* 10 3* 81-10-26 Rickie E. Brinegar: Modified to have entry variables instead of 10 4* entry pointers. This change included the addition of bit switches inorder 10 5* to be able to tell if the entry variable had been set yet. Also changed 10 6* the name of the structure from set_fn to linus_set_fn and the name of the 10 7* variable that it was based on from setf_ptr to linus_set_fn_ptr. 10 8* 10 9* 81-11-05 Rickie E. Brinegar: Changed the entry pointers to entry variables 10 10* and added bit switches to determine when the entries have or have not been 10 11* set. Renamed set_fn sturcture to linus_set_fn, setf_ptr to 10 12* linus_set_fn_ptr, and nset_fn_init_args to 10 13* initial_number_of_linus_set_fn_args. 10 14* 10 15**/ 10 16 10 17 dcl 1 linus_set_fn aligned based (linus_set_fn_ptr), /* internal rep. of set fun. */ 10 18 2 fwd_ptr ptr, /* pointer to next set function to be eval. 10 19* at this level */ 10 20 2 prior_ptr ptr, /* pointer to head of list of set functions 10 21* to be evaluated prior to this one */ 10 22 2 assign_entry entry variable, /* pointer to assign entry */ 10 23 2 calc_entry entry variable, /* pointer to calc entry */ 10 24 2 init_entry entry variable, /* pointer to initialization entry */ 10 25 2 assign_al_ptr ptr, /* pointer to assign entry arg list */ 10 26 2 calc_al_ptr ptr, /* pointer to calc entry arg list */ 10 27 2 rtrv_al_ptr ptr, /* pointer to arg list for dsl_$retrieve */ 10 28 2 flags, 10 29 3 assign_entry_set bit (1) unaligned, /* 0 => null, 1 => not null */ 10 30 3 calc_entry_set bit (1) unaligned, /* 0 => null, 1 => not null */ 10 31 3 init_entry_set bit (1) unaligned, /* 0 => null, 1 => not null */ 10 32 3 pad_bits bit (33) unaligned, 10 33 2 rslt_desc bit (36), /* descriptor for result */ 10 34 2 nargs fixed bin, /* number of input args to calc entry */ 10 35 2 arg (initial_number_of_linus_set_fn_args refer (linus_set_fn.nargs)), 10 36 3 type fixed bin (4) unal, /* 1 => constant 10 37* 2 => linus variable 10 38* 3 => scalar function 10 39* 4 => set function 10 40* 5 => expression 10 41* 6 => data base item */ 10 42 3 must_convert bit (1) unal, /* on if must convert prior to call */ 10 43 3 reserved bit (30) unal, 10 44 3 desc bit (36), /* descriptor of source data */ 10 45 3 assn_ptr ptr, /* assign_ ptr for source data */ 10 46 3 assn_type fixed bin, /* assign_ type for source data */ 10 47 3 assn_len fixed bin (35), /* assign_ length for source data */ 10 48 3 arg_desc bit (36), /* descriptor for converted arg */ 10 49 3 arg_assn_ptr ptr, /* assign_ ptr for converted arg */ 10 50 3 arg_assn_type fixed bin, /* assign_ type code for converted arg */ 10 51 3 arg_assn_len fixed bin (35), /* assign_ length for converted arg */ 10 52 3 ef_ptr ptr; /* pointer to express. or function structure */ 10 53 10 54 dcl initial_number_of_linus_set_fn_args fixed bin; 10 55 dcl linus_set_fn_ptr ptr; 10 56 10 57 /* END INCLUDE FILE linus_set_fn.incl.pl1 */ 57 58 11 1 /* BEGIN INCLUDE FILE linus_token_data.incl.pl1 -- jaw 8/7/78 */ 11 2 11 3 dcl 1 token_data aligned based (td_ptr), /* data for lila tokens */ 11 4 2 key fixed bin (17) unal, /* key of token */ 11 5 2 must_free bit (1) unal, /* on if value must be freed */ 11 6 2 temp_tab bit (1) unal, /* on if temporary table */ 11 7 2 reserved bit (16) unal, 11 8 2 mvar char (32) var, /* mrds variable if identifier */ 11 9 2 lvar char (32) var, /* linus variable if identifier */ 11 10 2 length fixed bin (35), /* char length of token value */ 11 11 2 t_ptr ptr; /* points to token value */ 11 12 11 13 dcl ((NULL init (0)), 11 14 (RP init (1)), 11 15 (COL_SPEC init (2)), 11 16 (LINUS_VAR init (3)), 11 17 (CONST init (4)), 11 18 (SET_FN init (5)), 11 19 (SCAL_FN init (6)), 11 20 (LP init (7)), 11 21 (STAR init (8)), 11 22 (DIV init (9)), 11 23 (PLUS init (10)), 11 24 (MINUS init (11)), 11 25 (TAB_NAME init (12)), 11 26 (ROW_TAB_PAIR init (13)), 11 27 (UNION init (14)), 11 28 (INTER init (15)), 11 29 (DIFFER init (16)), 11 30 (ROW_DES init (17)), 11 31 (LB init (18)), 11 32 (RB init (19)), 11 33 (SELECT init (20)), 11 34 (NOT init (21)), 11 35 (AND init (22)), 11 36 (OR init (23)), 11 37 (EQ init (24)), 11 38 (NE init (25)), 11 39 (GT init (26)), 11 40 (GE init (27)), 11 41 (LT init (28)), 11 42 (LE init (29)), 11 43 (FROM init (30)), 11 44 (WHERE init (31)), 11 45 (DUP init (32)), 11 46 (UNIQUE init (33)), 11 47 (COMMA init (34))) fixed bin int static options (constant); 11 48 11 49 dcl td_ptr ptr; 11 50 11 51 /* END INCLUDE FILE linus_token_data.incl.pl1 */ 59 60 12 1 /* BEGIN INCLUDE FILE linus_variables.incl.pl1 -- jaw 7/19/77 */ 12 2 12 3 dcl 1 variables aligned based (lv_ptr), /* info for all variables */ 12 4 2 nvars_alloc fixed bin, /* no. var. slots alloc. */ 12 5 2 nvars fixed bin, /* no. of variables currently defined */ 12 6 2 var_info (nvars_init refer (variables.nvars_alloc)), 12 7 3 name char (32), /* name of variable */ 12 8 3 var_ptr ptr, /* ptr to curr. value */ 12 9 3 bit_len fixed bin (35), /* bit length of current value */ 12 10 3 assn_type fixed bin, /* assign_ type code of current value */ 12 11 3 assn_len fixed bin (35), /* assign_ length of current value */ 12 12 3 desc bit (36); /* descrptor of current value */ 12 13 12 14 dcl lv_ptr ptr; 12 15 dcl nvars_init fixed bin; 12 16 12 17 /* END INCLUDE FILE linus_variables.incl.pl1 */ 61 62 13 1 /* BEGIN mdbm_descriptor.incl.pl1 -- jaw 5/31/78 */ 13 2 /* modified by Jim Gray - - Nov. 1979, to change type from fixed bin(5) to 13 3* unsigned fixed bin(6), so new packed decimal data types could be handled. 13 4* also the duplicate mrds_descriptor.incl.pl1 was eliminated. */ 13 5 13 6 dcl 1 descriptor based (desc_ptr), /* map of Multics descriptor */ 13 7 2 version bit (1) unal, /* DBM handles vers. 1 only */ 13 8 2 type unsigned fixed bin (6) unal, /* data type */ 13 9 2 packed bit (1) unal, /* on if data item is packed */ 13 10 2 number_dims bit (4) unal, /* dimensions */ 13 11 2 size, /* size for string data */ 13 12 3 scale bit (12) unal, /* scale for num. data */ 13 13 3 precision bit (12) unal, /* prec. for num. data */ 13 14 2 array_info (num_dims), 13 15 3 lower_bound fixed bin (35), /* lower bound of dimension */ 13 16 3 upper_bound fixed bin (35), /* upper bound of dimension */ 13 17 3 multiplier fixed bin (35); /* element separation */ 13 18 13 19 dcl desc_ptr ptr; 13 20 dcl num_dims fixed bin init (0) ; /* more useful form of number_dims */ 13 21 13 22 /* END mdbm_descriptor.incl.pl1 */ 13 23 13 24 63 64 65 dcl ( 66 code, /* Output: return code */ 67 icode, /* internal status code */ 68 temp_pos 69 ) fixed bin (35); /* temp cur_pos for look ahead */ 70 71 dcl ( 72 expr_flag, /* on if expr OK */ 73 atom_flag, /* on if atom OK */ 74 rop_flag, /* on if rel. op. OK */ 75 end_flag, /* on if end OK */ 76 done 77 ) bit (1) unal; /* completion flag */ 78 79 dcl (i, leaf_no) fixed bin; /* no. of leaf we are working on */ 80 81 dcl si_ptr ptr; /* pointer to select_info_structure */ 82 dcl token char (token_data.length) based (token_data.t_ptr); 83 dcl mrds_rop (24:29) char (4) var int static options (constant) 84 init (" = ", " ^= ", " > ", " >= ", " < ", " <= "); 85 dcl work_area area (sys_info$max_seg_size) based (lcb.lila_area_ptr); 86 87 dcl 1 temp_token aligned like token_data; /* for look-ahead */ 88 dcl 1 expr_data aligned like ef_data; 89 90 dcl ( 91 linus_error_$where_syntax, 92 linus_error_$incomplete_where, 93 linus_error_$const_expr_fn, 94 linus_data_$max_set_stack_size, 95 linus_data_$max_range_items, 96 linus_data_$max_expr_items, 97 linus_data_$max_pred_stack_size, 98 mrds_data_$max_token_size, 99 mrds_data_$max_select_items, 100 sys_info$max_seg_size 101 ) fixed bin (35) ext; 102 103 dcl (addr, fixed, null, length, addrel, rel) builtin; 104 105 dcl linus_lila_get_token entry (ptr, ptr, fixed bin (35), ptr, fixed bin (35)); 106 dcl linus_lila_error entry (ptr, ptr, fixed bin (35), char (*)); 107 dcl linus_lila_set_fn entry (ptr, ptr, ptr, ptr, fixed bin (35)); 108 dcl linus_lila_build_expr_str 109 entry (ptr, ptr, ptr, ptr, char (*), fixed bin (35)); 110 dcl linus_lila_block entry (ptr, ptr, ptr, fixed bin (35)); 111 112 call init; /* initialize */ 113 114 if token_data.key = NULL then do; /* if need new token */ 115 call 116 linus_lila_get_token (lcb_ptr, lsh_ptr, ls_header.cur_pos, td_ptr, 117 icode); 118 if icode ^= 0 then 119 call linus_lila_error (lcb_ptr, lsh_ptr, icode, token); 120 end; 121 122 expr_flag = "1"b; 123 rop_flag, /* init. state flags */ 124 atom_flag, end_flag = "0"b; 125 126 done = "0"b; /* init for loop */ 127 128 do while (^done); /* main processing loop */ 129 130 go to token_proc (token_data.key); 131 132 token_proc (0): /* null */ 133 token_proc (1): /* ) */ 134 token_proc (8): /* * */ 135 token_proc (9): /* / */ 136 token_proc (10): /* + */ 137 token_proc (11): /* - */ 138 token_proc (12): /* table name */ 139 token_proc (13): /* row table pair */ 140 token_proc (14): /* union */ 141 token_proc (15): /* inter */ 142 token_proc (16): /* differ */ 143 token_proc (17): /* row designator */ 144 token_proc (19): /* } */ 145 token_proc (20): /* select */ 146 token_proc (21): /* ^ */ 147 token_proc (22): /* & */ 148 token_proc (23): /* | */ 149 token_proc (30): /* from */ 150 token_proc (31): /* where */ 151 token_proc (32): /* dup */ 152 token_proc (33): /* unique */ 153 token_proc (34): /* , */ 154 if ^end_flag then /* cant have end of term now */ 155 call 156 linus_lila_error (lcb_ptr, lsh_ptr, 157 linus_error_$incomplete_where, token); 158 call build_term_block; /* build mrds term block and put in stack */ 159 done = "1"b; 160 go to next; 161 162 token_proc (2): /* column specification */ 163 if ^atom_flag & ^expr_flag then /* if not expected */ 164 call 165 linus_lila_error (lcb_ptr, lsh_ptr, linus_error_$where_syntax, 166 token); 167 168 temp_pos = ls_header.cur_pos; /* look ahead for operator */ 169 call 170 linus_lila_get_token (lcb_ptr, lsh_ptr, temp_pos, addr (temp_token), 171 icode); 172 if icode ^= 0 then do; /* reset token pos. ind. prior to error call */ 173 token_data = temp_token; 174 ls_header.cur_pos = temp_pos; 175 call linus_lila_error (lcb_ptr, lsh_ptr, icode, token); 176 end; 177 if temp_token.key >= STAR & temp_token.key <= MINUS then 178 /* if is expr. */ 179 call process_expr; 180 else do; /* is not expression */ 181 call 182 store_leaf (token_data.mvar || "." || token, 183 token_data.must_free); 184 token_data.key = NULL; /* force new token */ 185 end; /* if col. spec. */ 186 187 if expr_flag then do; /* if was first leaf, expect rel. op. */ 188 expr_flag, atom_flag, end_flag = "0"b; 189 rop_flag = "1"b; 190 end; 191 else do; /* if was second leaf, expect end */ 192 expr_flag, atom_flag, rop_flag = "0"b; 193 end_flag = "1"b; 194 end; 195 go to next; 196 197 token_proc (3): /* linus variable */ 198 if ^atom_flag then /* if not expected */ 199 call 200 linus_lila_error (lcb_ptr, lsh_ptr, linus_error_$where_syntax, 201 token); 202 203 lv_ptr = lcb.lv_ptr; /* find info for lin. var. */ 204 do i = 1 to variables.nvars 205 while (token ^= variables.var_info.name (i)); 206 end; /* we know we will find it */ 207 call 208 add_val_leaf (variables.var_info.var_ptr (i), 209 addr (variables.var_info.desc (i))); 210 end_flag = "1"b; 211 atom_flag, /* reset state flags */ 212 rop_flag, expr_flag = "0"b; 213 token_data.key = NULL; /* force new token */ 214 go to next; 215 216 /* 81-11-03 DJ Schimke: Begin Change *************************************** */ 217 token_proc (4): /* constant */ 218 if ^atom_flag & ^expr_flag then /* if not expected */ 219 call 220 linus_lila_error (lcb_ptr, lsh_ptr, linus_error_$where_syntax, 221 token); 222 223 temp_pos = ls_header.cur_pos; /* look ahead for operator */ 224 call 225 linus_lila_get_token (lcb_ptr, lsh_ptr, temp_pos, addr (temp_token), 226 icode); 227 if icode ^= 0 then do; /* reset token pos. ind. prior to error call */ 228 token_data = temp_token; 229 ls_header.cur_pos = temp_pos; 230 call linus_lila_error (lcb_ptr, lsh_ptr, icode, token); 231 end; 232 if temp_token.key >= STAR & temp_token.key <= MINUS then 233 /* if is expr. */ 234 call process_expr; 235 else do; /* is not expression */ 236 call store_leaf (token, token_data.must_free); 237 token_data.key = NULL; /* force new token */ 238 end; /* if constant */ 239 240 if expr_flag then do; /* if was first leaf, expect rel. op. */ 241 expr_flag, atom_flag, end_flag = "0"b; 242 rop_flag = "1"b; 243 end; 244 else do; /* if was second leaf, expect end */ 245 expr_flag, atom_flag, rop_flag = "0"b; 246 end_flag = "1"b; 247 end; 248 go to next; 249 250 /* 81-11-03 DJ Schimke: End Change ***************************************** */ 251 252 token_proc (5): /* set function */ 253 if ^atom_flag then /* if not expected */ 254 call 255 linus_lila_error (lcb_ptr, lsh_ptr, linus_error_$where_syntax, 256 token); 257 call 258 linus_lila_set_fn (lcb_ptr, lsh_ptr, td_ptr, addr (expr_data), 259 icode); 260 if icode ^= 0 then 261 call linus_lila_error (lcb_ptr, lsh_ptr, icode, token); 262 call 263 add_val_leaf (expr_data.assn_ptr, 264 addr (expr_data.ef_ptr -> linus_set_fn.rslt_desc)); 265 end_flag = "1"b; /* reset state flags */ 266 rop_flag, expr_flag, atom_flag = "0"b; 267 go to next; 268 269 token_proc (6): /* scalar function */ 270 token_proc (7): /* ( */ 271 if ^expr_flag & ^atom_flag then /* if not expected */ 272 call 273 linus_lila_error (lcb_ptr, lsh_ptr, linus_error_$where_syntax, 274 token); 275 call process_expr; /* these tokens imply an expression */ 276 if expr_flag then do; /* if expr, then look for rel. op. */ 277 rop_flag = "1"b; 278 expr_flag, atom_flag, end_flag = "0"b; 279 end; 280 else do; /* if atom, look for end */ 281 end_flag = "1"b; 282 expr_flag, rop_flag, atom_flag = "0"b; 283 end; 284 go to next; 285 286 token_proc (18): /* { */ 287 if ^atom_flag then /* if not expected */ 288 call 289 linus_lila_error (lcb_ptr, lsh_ptr, linus_error_$where_syntax, 290 token); 291 292 ls_block.pred_pcnt = ls_block.pred_pcnt + 1; /* implied paren at start of blockk */ 293 ls_set.br_cnt = ls_set.br_cnt + 1; /* increment bracket count */ 294 295 call linus_lila_block (lcb_ptr, lsh_ptr, td_ptr, icode); 296 /* process the inner block */ 297 if icode ^= 0 then 298 call linus_lila_error (lcb_ptr, lsh_ptr, icode, token); 299 300 if token_data.key ^= RB then /* last token must be } */ 301 call 302 linus_lila_error (lcb_ptr, lsh_ptr, linus_error_$where_syntax, 303 token); 304 ls_set.br_cnt = ls_set.br_cnt - 1; /* decrement bracket count */ 305 306 token_data.key = NULL; /* force new token */ 307 end_flag = "1"b; /* reset state flags */ 308 rop_flag, atom_flag, expr_flag = "0"b; 309 go to next; 310 311 token_proc (24): /* = */ 312 token_proc (25): /* ^= */ 313 token_proc (26): /* > */ 314 token_proc (27): /* >= */ 315 token_proc (28): /* < */ 316 token_proc (29): /* <= */ 317 if ^rop_flag then /* if rel. op. not expected */ 318 call 319 linus_lila_error (lcb_ptr, lsh_ptr, linus_error_$where_syntax, 320 token); 321 ls_block.term_op = token_data.key; /* save rel. op. */ 322 atom_flag = "1"b; /* reset state flags */ 323 end_flag, rop_flag, expr_flag = "0"b; 324 token_data.key = NULL; 325 go to next; 326 327 next: 328 if token_data.key = NULL then do; /* get next token */ 329 call 330 linus_lila_get_token (lcb_ptr, lsh_ptr, ls_header.cur_pos, 331 td_ptr, icode); 332 if icode ^= 0 then 333 call linus_lila_error (lcb_ptr, lsh_ptr, icode, token); 334 end; 335 end; /* main processing loop */ 336 337 code = 0; /* made it! */ 338 return; 339 340 stack_term: 341 entry (lcb_ptr, lsh_ptr); 342 343 /* Entry called by linus_lila_select to cause completed term to be added to 344* term stack. */ 345 346 call init; /* initialize */ 347 call build_term_block; /* do the work */ 348 return; 349 350 build_term_block: 351 proc; 352 353 /* Procedure to build a MRDS term string from the term info stored in the ls_block. */ 354 355 dcl i fixed bin; 356 357 if ls_block.term_op > 0 then do; /* only if there is an unbuilt term */ 358 ms_len_init = 359 length (ls_block.leaf_ptr (1) -> mrds_block.mrds_string) 360 + length (ls_block.leaf_ptr (2) -> mrds_block.mrds_string) 361 + length (mrds_rop (ls_block.term_op)); /* alloc. term block */ 362 nval_args_init = 363 ls_block.leaf_ptr (1) -> mrds_block.nval_args 364 + ls_block.leaf_ptr (2) -> mrds_block.nval_args; 365 allocate mrds_block in (work_area); 366 367 mrds_block.fwd_ptr = ls_block.term_hd_ptr; /* fill in the term block */ 368 mrds_block.mrds_string = 369 ls_block.leaf_ptr (1) -> mrds_block.mrds_string 370 || mrds_rop (ls_block.term_op) 371 || ls_block.leaf_ptr (2) -> mrds_block.mrds_string; 372 ls_block.term_op = 0; /* indicate no term */ 373 374 do i = 1 to ls_block.leaf_ptr (1) -> mrds_block.nval_args; 375 /* fill in args from first leaf */ 376 mrds_block.val_args.arg_ptr (i) = 377 ls_block.leaf_ptr (1) -> mrds_block.arg_ptr (i); 378 mrds_block.val_args.desc_ptr (i) = 379 ls_block.leaf_ptr (1) -> mrds_block.desc_ptr (i); 380 end; 381 do i = ls_block.leaf_ptr (1) -> mrds_block.nval_args + 1 382 to mrds_block.nval_args; /* add args from second leaf */ 383 mrds_block.val_args.arg_ptr (i) = 384 ls_block.leaf_ptr (2) 385 -> mrds_block.val_args 386 .arg_ptr (i - ls_block.leaf_ptr (1) -> mrds_block.nval_args); 387 mrds_block.val_args.desc_ptr (i) = 388 ls_block.leaf_ptr (2) 389 -> mrds_block.val_args 390 .desc_ptr (i - ls_block.leaf_ptr (1) -> mrds_block.nval_args); 391 end; 392 393 ls_block.term_hd_ptr = mblk_ptr; 394 mblk_ptr = null; 395 ls_block.nterms = ls_block.nterms + 1; 396 ls_block.leaf_ptr (1) = null; 397 ls_block.leaf_ptr (2) = null; 398 end; /* if there was unbuilt term */ 399 400 end build_term_block; 401 402 process_expr: 403 proc; 404 405 /* Procedure to handle where clause expressions. */ 406 407 dcl var char (32); 408 409 var = ""; 410 call 411 linus_lila_build_expr_str (lcb_ptr, lsh_ptr, td_ptr, mblk_ptr, var, 412 icode); /* build mrds string for this expr. */ 413 if icode ^= 0 then 414 call linus_lila_error (lcb_ptr, lsh_ptr, icode, token); 415 if var = "" then 416 call 417 linus_lila_error (lcb_ptr, lsh_ptr, linus_error_$const_expr_fn, 418 ""); 419 if expr_flag then 420 leaf_no = 1; 421 else leaf_no = 2; 422 ls_block.leaf_ptr (leaf_no) = mblk_ptr; 423 mblk_ptr = null; 424 425 end process_expr; 426 427 store_leaf: 428 proc (string, must_free); 429 430 /* procedure to store a leaf into the current term in the ls_block */ 431 432 dcl string char (*); 433 dcl must_free bit (1); 434 435 if expr_flag then 436 leaf_no = 1; 437 else leaf_no = 2; 438 439 ms_len_init = length (string); /* make and fill in mrds block for leaf */ 440 nval_args_init = 0; 441 allocate mrds_block in (work_area); 442 mrds_block.fwd_ptr = null; 443 mrds_block.mrds_string = string; 444 ls_block.leaf_ptr (leaf_no) = mblk_ptr; /* put in leaf */ 445 mblk_ptr = null; 446 token_data.t_ptr = null; 447 448 end store_leaf; 449 450 add_val_leaf: 451 proc (arg_ptr, desc_ptr); 452 453 /* Procedure to add a .V. type of leaf to the current term. */ 454 455 dcl (arg_ptr, desc_ptr) ptr; 456 dcl is_var (22) bit (1) int static unal options (constant) 457 init ((19) (1)"0"b, "1"b, "0"b, "1"b); 458 459 ms_len_init = 3; /* make and fill in mrds block for leaf */ 460 nval_args_init = 1; 461 allocate mrds_block in (work_area); 462 mrds_block.fwd_ptr = null; 463 mrds_block.mrds_string = ".V."; 464 if is_var (desc_ptr -> descriptor.type) then 465 mrds_block.val_args.arg_ptr (1) = addrel (arg_ptr, 1); 466 else mrds_block.val_args.arg_ptr (1) = arg_ptr; 467 mrds_block.val_args.desc_ptr (1) = desc_ptr; 468 ls_block.leaf_ptr (2) = mblk_ptr; /* this type of leaf is always second */ 469 mblk_ptr = null; 470 471 end add_val_leaf; 472 473 init: 474 proc; 475 476 /* Procedure to initialize for both entries. */ 477 478 lsb_ptr = ls_header.cur_ptr; 479 lss_ptr = ls_block.back_ptr; 480 si_ptr = ls_set.si_ptr; 481 mblk_ptr = null; 482 num_dims = 0; 483 484 end init; 485 486 end linus_lila_term; SOURCE FILES USED IN THIS COMPILATION. LINE NUMBER DATE MODIFIED NAME PATHNAME 0 07/29/86 0939.9 linus_lila_term.pl1 >special_ldd>install>MR12.0-1106>linus_lila_term.pl1 45 1 07/29/86 0937.8 linus_lcb.incl.pl1 >special_ldd>install>MR12.0-1106>linus_lcb.incl.pl1 47 2 03/27/82 0434.5 linus_ef_data.incl.pl1 >ldd>include>linus_ef_data.incl.pl1 49 3 11/23/82 1327.2 linus_ls_header.incl.pl1 >ldd>include>linus_ls_header.incl.pl1 3-4 4 03/27/82 0434.5 linus_ls_common.incl.pl1 >ldd>include>linus_ls_common.incl.pl1 51 5 03/27/82 0434.5 linus_ls_set.incl.pl1 >ldd>include>linus_ls_set.incl.pl1 5-4 6 03/27/82 0434.5 linus_ls_common.incl.pl1 >ldd>include>linus_ls_common.incl.pl1 53 7 03/27/82 0434.5 linus_ls_block.incl.pl1 >ldd>include>linus_ls_block.incl.pl1 7-4 8 03/27/82 0434.5 linus_ls_common.incl.pl1 >ldd>include>linus_ls_common.incl.pl1 55 9 03/27/82 0434.5 linus_mrds_block.incl.pl1 >ldd>include>linus_mrds_block.incl.pl1 57 10 11/23/82 1327.2 linus_set_fn.incl.pl1 >ldd>include>linus_set_fn.incl.pl1 59 11 03/27/82 0434.5 linus_token_data.incl.pl1 >ldd>include>linus_token_data.incl.pl1 61 12 03/27/82 0434.5 linus_variables.incl.pl1 >ldd>include>linus_variables.incl.pl1 63 13 10/14/83 1608.6 mdbm_descriptor.incl.pl1 >ldd>include>mdbm_descriptor.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. MINUS constant fixed bin(17,0) initial dcl 11-13 ref 177 232 NULL constant fixed bin(17,0) initial dcl 11-13 ref 114 184 213 237 306 324 327 RB constant fixed bin(17,0) initial dcl 11-13 ref 300 STAR constant fixed bin(17,0) initial dcl 11-13 ref 177 232 addr builtin function dcl 103 ref 169 169 207 207 224 224 257 257 262 262 addrel builtin function dcl 103 ref 464 arg_ptr 6 based pointer array level 3 in structure "mrds_block" dcl 9-3 in procedure "linus_lila_term" set ref 376* 376 383* 383 464* 466* arg_ptr parameter pointer dcl 455 in procedure "add_val_leaf" ref 450 464 466 assn_ptr 12 000154 automatic pointer level 2 dcl 88 set ref 262* atom_flag 000116 automatic bit(1) unaligned dcl 71 set ref 123* 162 188* 192* 197 211* 217 241* 245* 252 266* 269 278* 282* 286 308* 322* back_ptr 2 based pointer level 2 dcl 7-3 ref 479 br_cnt based fixed bin(17,0) level 2 dcl 5-3 set ref 293* 293 304* 304 code parameter fixed bin(35,0) dcl 65 set ref 18 337* cur_pos 13 based fixed bin(35,0) level 2 dcl 3-3 set ref 115* 168 174* 223 229* 329* cur_ptr 6 based pointer level 2 dcl 3-3 ref 478 desc 17 based bit(36) array level 3 dcl 12-3 set ref 207 207 desc_ptr 10 based pointer array level 3 in structure "mrds_block" dcl 9-3 in procedure "linus_lila_term" set ref 378* 378 387* 387 467* desc_ptr parameter pointer dcl 455 in procedure "add_val_leaf" ref 450 464 467 descriptor based structure level 1 unaligned dcl 13-6 done 000121 automatic bit(1) unaligned dcl 71 set ref 126* 128 159* ef_data based structure level 1 dcl 2-3 ef_ptr 000154 automatic pointer level 2 dcl 88 set ref 262 262 end_flag 000120 automatic bit(1) unaligned dcl 71 set ref 123* 132 188* 193* 210* 241* 246* 265* 278* 281* 307* 323* expr_data 000154 automatic structure level 1 dcl 88 set ref 257 257 expr_flag 000115 automatic bit(1) unaligned dcl 71 set ref 122* 162 187 188* 192* 211* 217 240 241* 245* 266* 269 276 278* 282* 308* 323* 419 435 fwd_ptr based pointer level 2 dcl 9-3 set ref 367* 442* 462* i 000166 automatic fixed bin(17,0) dcl 355 in procedure "build_term_block" set ref 374* 376 376 378 378* 381* 383 383 387 387* i 000122 automatic fixed bin(17,0) dcl 79 in procedure "linus_lila_term" set ref 204* 204* 207 207 207 icode 000113 automatic fixed bin(35,0) dcl 65 set ref 115* 118 118* 169* 172 175* 224* 227 230* 257* 260 260* 295* 297 297* 329* 332 332* 410* 413 413* is_var 000043 constant bit(1) initial array unaligned dcl 456 ref 464 key based fixed bin(17,0) level 2 in structure "token_data" packed unaligned dcl 11-3 in procedure "linus_lila_term" set ref 114 130 184* 213* 237* 300 306* 321 324* 327 key 000126 automatic fixed bin(17,0) level 2 in structure "temp_token" packed unaligned dcl 87 in procedure "linus_lila_term" set ref 177 177 232 232 lcb based structure level 1 dcl 1-53 lcb_ptr parameter pointer dcl 1-121 set ref 18 115* 118* 132* 162* 169* 175* 197* 203 217* 224* 230* 252* 257* 260* 269* 286* 295* 297* 300* 311* 329* 332* 340 365 410* 413* 415* 441 461 leaf_no 000123 automatic fixed bin(17,0) dcl 79 set ref 419* 421* 422 435* 437* 444 leaf_ptr based pointer array level 2 dcl 7-3 set ref 358 358 362 362 368 368 374 376 378 381 383 383 387 387 396* 397* 422* 444* 468* length builtin function dcl 103 in procedure "linus_lila_term" ref 358 358 358 439 length 23 based fixed bin(35,0) level 2 in structure "token_data" dcl 11-3 in procedure "linus_lila_term" set ref 118 118 132 132 162 162 175 175 181 197 197 204 217 217 230 230 236 236 252 252 260 260 269 269 286 286 297 297 300 300 311 311 332 332 413 413 lila_area_ptr 62 based pointer level 2 dcl 1-53 ref 365 441 461 linus_data_$max_expr_items 000022 external static fixed bin(35,0) dcl 90 ref 88 linus_data_$max_pred_stack_size 000024 external static fixed bin(35,0) dcl 90 ref 292 292 321 357 358 358 358 362 362 367 368 368 368 372 374 376 378 381 383 383 387 387 393 395 395 396 397 422 444 468 linus_data_$max_range_items 000020 external static fixed bin(35,0) dcl 90 ref 292 292 321 357 358 358 358 362 362 367 368 368 368 372 374 376 378 381 383 383 387 387 393 395 395 396 397 422 444 468 linus_data_$max_set_stack_size 000016 external static fixed bin(35,0) dcl 90 ref 293 293 304 304 480 linus_error_$const_expr_fn 000014 external static fixed bin(35,0) dcl 90 set ref 415* linus_error_$incomplete_where 000012 external static fixed bin(35,0) dcl 90 set ref 132* linus_error_$where_syntax 000010 external static fixed bin(35,0) dcl 90 set ref 162* 197* 217* 252* 269* 286* 300* 311* linus_lila_block 000042 constant entry external dcl 110 ref 295 linus_lila_build_expr_str 000040 constant entry external dcl 108 ref 410 linus_lila_error 000034 constant entry external dcl 106 ref 118 132 162 175 197 217 230 252 260 269 286 297 300 311 332 413 415 linus_lila_get_token 000032 constant entry external dcl 105 ref 115 169 224 329 linus_lila_set_fn 000036 constant entry external dcl 107 ref 257 linus_set_fn based structure level 1 dcl 10-17 ls_block based structure level 1 dcl 7-3 ls_header based structure level 1 dcl 3-3 ls_set based structure level 1 dcl 5-3 lsb_ptr 000102 automatic pointer dcl 7-32 set ref 292 292 321 357 358 358 358 362 362 367 368 368 368 372 374 376 378 381 383 383 387 387 393 395 395 396 397 422 444 468 478* 479 lsh_ptr parameter pointer dcl 3-15 set ref 18 115* 115 118* 132* 162* 168 169* 174 175* 197* 217* 223 224* 229 230* 252* 257* 260* 269* 286* 295* 297* 300* 311* 329* 329 332* 340 410* 413* 415* 478 lss_ptr 000100 automatic pointer dcl 5-33 set ref 293 293 304 304 479* 480 lv_ptr 000110 automatic pointer dcl 12-14 in procedure "linus_lila_term" set ref 203* 204 204 207 207 207 lv_ptr 32 based pointer level 2 in structure "lcb" dcl 1-53 in procedure "linus_lila_term" ref 203 mblk_ptr 000106 automatic pointer dcl 9-16 set ref 365* 367 368 376 378 381 383 387 393 394* 410* 422 423* 441* 442 443 444 445* 461* 462 463 464 466 467 468 469* 481* mrds_block based structure level 1 dcl 9-3 set ref 365 441 461 mrds_data_$max_select_items 000030 external static fixed bin(35,0) dcl 90 ref 292 292 321 357 358 358 358 362 362 367 368 368 368 372 374 376 378 381 383 383 387 387 393 395 395 396 397 422 444 468 480 mrds_data_$max_token_size 000026 external static fixed bin(35,0) dcl 90 ref 292 292 321 357 358 358 358 362 362 367 368 368 368 372 374 376 378 381 383 383 387 387 393 395 395 396 397 422 444 468 mrds_rop 000044 constant varying char(4) initial array dcl 83 ref 358 368 mrds_string based varying char level 2 dcl 9-3 set ref 358 358 368* 368 368 443* 463* ms_len based fixed bin(35,0) level 2 dcl 9-3 set ref 365* 368 441* 443 461* 463 ms_len_init 000105 automatic fixed bin(35,0) dcl 9-15 set ref 358* 365 365 439* 441 441 459* 461 461 must_free parameter bit(1) unaligned dcl 433 in procedure "store_leaf" ref 427 must_free 0(18) based bit(1) level 2 in structure "token_data" packed unaligned dcl 11-3 in procedure "linus_lila_term" set ref 181* 236* mvar 1 based varying char(32) level 2 dcl 11-3 set ref 181 name 2 based char(32) array level 3 dcl 12-3 ref 204 nterms based fixed bin(17,0) level 2 dcl 7-3 set ref 395* 395 null builtin function dcl 103 ref 394 396 397 423 442 445 446 462 469 481 num_dims 000112 automatic fixed bin(17,0) initial dcl 13-20 set ref 13-20* 482* nval_args 4 based fixed bin(17,0) level 2 dcl 9-3 set ref 358 358 362 362 365* 365 368 368 368 368 374 381 381 383 387 441* 441 443 443 461* 461 463 463 nval_args_init 000104 automatic fixed bin(17,0) dcl 9-14 set ref 362* 365 365 440* 441 441 460* 461 461 nvars 1 based fixed bin(17,0) level 2 dcl 12-3 ref 204 pred_pcnt based fixed bin(17,0) level 2 dcl 7-3 set ref 292* 292 rop_flag 000117 automatic bit(1) unaligned dcl 71 set ref 123* 189* 192* 211* 242* 245* 266* 277* 282* 308* 311 323* rslt_desc 27 based bit(36) level 2 dcl 10-17 set ref 262 262 si_ptr 000124 automatic pointer dcl 81 in procedure "linus_lila_term" set ref 480* si_ptr based pointer level 2 in structure "ls_set" dcl 5-3 in procedure "linus_lila_term" ref 480 string parameter char unaligned dcl 432 ref 427 439 443 t_ptr 24 based pointer level 2 dcl 11-3 set ref 118 132 162 175 181 197 204 217 230 236 252 260 269 286 297 300 311 332 413 446* td_ptr parameter pointer dcl 11-49 set ref 18 114 115* 118 118 118 130 132 132 132 162 162 162 173 175 175 175 181 181 181 181 184 197 197 197 204 204 213 217 217 217 228 230 230 230 236 236 236 236 237 252 252 252 257* 260 260 260 269 269 269 286 286 286 295* 297 297 297 300 300 300 300 306 311 311 311 321 324 327 329* 332 332 332 410* 413 413 413 446 temp_pos 000114 automatic fixed bin(35,0) dcl 65 set ref 168* 169* 174 223* 224* 229 temp_token 000126 automatic structure level 1 dcl 87 set ref 169 169 173 224 224 228 term_hd_ptr based pointer level 2 dcl 7-3 set ref 367 393* term_op based fixed bin(17,0) level 2 dcl 7-3 set ref 321* 357 358 368 372* token based char unaligned dcl 82 set ref 118* 132* 162* 175* 181 197* 204 217* 230* 236* 252* 260* 269* 286* 297* 300* 311* 332* 413* token_data based structure level 1 dcl 11-3 set ref 173* 228* type 0(01) based fixed bin(6,0) level 2 packed unsigned unaligned dcl 13-6 ref 464 val_args 6 based structure array level 2 dcl 9-3 var 000200 automatic char(32) unaligned dcl 407 set ref 409* 410* 415 var_info 2 based structure array level 2 dcl 12-3 var_ptr 12 based pointer array level 3 dcl 12-3 set ref 207* variables based structure level 1 dcl 12-3 work_area based area dcl 85 ref 365 441 461 NAMES DECLARED BY DECLARE STATEMENT AND NEVER REFERENCED. AND internal static fixed bin(17,0) initial dcl 11-13 COL_SPEC internal static fixed bin(17,0) initial dcl 11-13 COMMA internal static fixed bin(17,0) initial dcl 11-13 CONST internal static fixed bin(17,0) initial dcl 11-13 DIFFER internal static fixed bin(17,0) initial dcl 11-13 DIV internal static fixed bin(17,0) initial dcl 11-13 DUP internal static fixed bin(17,0) initial dcl 11-13 EQ internal static fixed bin(17,0) initial dcl 11-13 FROM internal static fixed bin(17,0) initial dcl 11-13 GE internal static fixed bin(17,0) initial dcl 11-13 GT internal static fixed bin(17,0) initial dcl 11-13 INTER internal static fixed bin(17,0) initial dcl 11-13 LB internal static fixed bin(17,0) initial dcl 11-13 LE internal static fixed bin(17,0) initial dcl 11-13 LINUS_VAR internal static fixed bin(17,0) initial dcl 11-13 LP internal static fixed bin(17,0) initial dcl 11-13 LT internal static fixed bin(17,0) initial dcl 11-13 NE internal static fixed bin(17,0) initial dcl 11-13 NOT internal static fixed bin(17,0) initial dcl 11-13 OR internal static fixed bin(17,0) initial dcl 11-13 PLUS internal static fixed bin(17,0) initial dcl 11-13 ROW_DES internal static fixed bin(17,0) initial dcl 11-13 ROW_TAB_PAIR internal static fixed bin(17,0) initial dcl 11-13 RP internal static fixed bin(17,0) initial dcl 11-13 SCAL_FN internal static fixed bin(17,0) initial dcl 11-13 SELECT internal static fixed bin(17,0) initial dcl 11-13 SET_FN internal static fixed bin(17,0) initial dcl 11-13 TAB_NAME internal static fixed bin(17,0) initial dcl 11-13 UNION internal static fixed bin(17,0) initial dcl 11-13 UNIQUE internal static fixed bin(17,0) initial dcl 11-13 WHERE internal static fixed bin(17,0) initial dcl 11-13 desc_ptr automatic pointer dcl 13-19 ed_ptr automatic pointer dcl 2-22 fixed builtin function dcl 103 initial_number_of_linus_set_fn_args automatic fixed bin(17,0) dcl 10-54 linus_set_fn_ptr automatic pointer dcl 10-55 nvars_init automatic fixed bin(17,0) dcl 12-15 rel builtin function dcl 103 sys_info$max_seg_size external static fixed bin(35,0) dcl 90 NAMES DECLARED BY EXPLICIT CONTEXT. add_val_leaf 002713 constant entry internal dcl 450 ref 207 262 build_term_block 001644 constant entry internal dcl 350 ref 158 347 init 003046 constant entry internal dcl 473 ref 112 346 linus_lila_term 000115 constant entry external dcl 18 next 001541 constant label dcl 327 ref 160 195 214 248 267 284 309 325 process_expr 002355 constant entry internal dcl 402 ref 177 232 275 stack_term 001633 constant entry external dcl 340 store_leaf 002550 constant entry internal dcl 427 ref 181 236 token_proc 000000 constant label array(0:34) dcl 132 ref 130 THERE WERE NO NAMES DECLARED BY CONTEXT OR IMPLICATION. STORAGE REQUIREMENTS FOR THIS PROGRAM. Object Text Link Symbol Defs Static Start 0 0 3354 3420 3123 3364 Length 4152 3123 44 515 231 0 BLOCK NAME STACK SIZE TYPE WHY NONQUICK/WHO SHARES STACK FRAME linus_lila_term 227 external procedure is an external procedure. build_term_block internal procedure shares stack frame of external procedure linus_lila_term. process_expr internal procedure shares stack frame of external procedure linus_lila_term. store_leaf 68 internal procedure is called during a stack extension. add_val_leaf internal procedure shares stack frame of external procedure linus_lila_term. init internal procedure shares stack frame of external procedure linus_lila_term. STORAGE FOR AUTOMATIC VARIABLES. STACK FRAME LOC IDENTIFIER BLOCK NAME linus_lila_term 000100 lss_ptr linus_lila_term 000102 lsb_ptr linus_lila_term 000104 nval_args_init linus_lila_term 000105 ms_len_init linus_lila_term 000106 mblk_ptr linus_lila_term 000110 lv_ptr linus_lila_term 000112 num_dims linus_lila_term 000113 icode linus_lila_term 000114 temp_pos linus_lila_term 000115 expr_flag linus_lila_term 000116 atom_flag linus_lila_term 000117 rop_flag linus_lila_term 000120 end_flag linus_lila_term 000121 done linus_lila_term 000122 i linus_lila_term 000123 leaf_no linus_lila_term 000124 si_ptr linus_lila_term 000126 temp_token linus_lila_term 000154 expr_data linus_lila_term 000166 i build_term_block 000200 var process_expr THE FOLLOWING EXTERNAL OPERATORS ARE USED BY THIS PROGRAM. alloc_cs cat_realloc_cs call_ext_out_desc call_ext_out call_int_this_desc return alloc_auto_adj mpfx2 shorten_stack ext_entry int_entry_desc alloc_based THE FOLLOWING EXTERNAL ENTRIES ARE CALLED BY THIS PROGRAM. linus_lila_block linus_lila_build_expr_str linus_lila_error linus_lila_get_token linus_lila_set_fn THE FOLLOWING EXTERNAL VARIABLES ARE USED BY THIS PROGRAM. linus_data_$max_expr_items linus_data_$max_pred_stack_size linus_data_$max_range_items linus_data_$max_set_stack_size linus_error_$const_expr_fn linus_error_$incomplete_where linus_error_$where_syntax mrds_data_$max_select_items mrds_data_$max_token_size LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC 13 20 000073 88 000074 18 000110 112 000123 114 000124 115 000131 118 000152 122 000206 123 000210 126 000213 128 000214 130 000216 132 000222 158 000254 159 000255 160 000257 162 000260 168 000314 169 000321 172 000342 173 000344 174 000352 175 000356 177 000405 181 000416 184 000467 187 000475 188 000477 189 000502 190 000504 192 000505 193 000510 195 000512 197 000513 203 000545 204 000552 206 000575 207 000577 210 000615 211 000617 213 000622 214 000627 217 000630 223 000664 224 000671 227 000712 228 000714 229 000722 230 000726 232 000755 236 000766 237 001012 240 001017 241 001021 242 001024 243 001026 245 001027 246 001032 248 001034 252 001035 257 001067 260 001111 262 001145 265 001167 266 001171 267 001174 269 001175 275 001231 276 001232 277 001234 278 001236 279 001241 281 001242 282 001244 284 001247 286 001250 292 001302 293 001320 295 001323 297 001340 300 001374 304 001432 306 001437 307 001444 308 001446 309 001451 311 001452 321 001504 322 001530 323 001532 324 001535 325 001540 327 001541 329 001546 332 001567 335 001623 337 001624 338 001626 340 001627 346 001641 347 001642 348 001643 350 001644 357 001645 358 001667 362 001727 365 001732 367 001760 368 002011 372 002110 374 002114 376 002123 378 002157 380 002164 381 002166 383 002227 387 002270 391 002300 393 002302 394 002333 395 002336 396 002351 397 002353 400 002354 402 002355 409 002356 410 002361 413 002414 415 002450 419 002501 421 002506 422 002510 423 002544 425 002546 427 002547 435 002563 437 002571 439 002573 440 002575 441 002576 442 002626 443 002630 444 002647 445 002704 446 002706 448 002712 450 002713 459 002715 460 002717 461 002721 462 002747 463 002751 464 002766 466 003004 467 003007 468 003013 469 003043 471 003045 473 003046 478 003047 479 003054 480 003056 481 003116 482 003120 484 003121 ----------------------------------------------------------- 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