COMPILATION LISTING OF SEGMENT resource_usage Compiled by: Multics PL/I Compiler, Release 30, of February 16, 1988 Compiled at: Honeywell Bull, Phoenix AZ, SysM Compiled on: 07/13/88 1040.1 mst Wed 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 12 /* RESOURCE_USAGE - Procedure to print user's monthly (to date) resource usage and resource limits. 13* This procedure gets this info from the user's PIT, where cpg_ put it. 14* 15* This procedure is called in any of four modes: 16* 17* 1) long mode (specify the control_arg -long or -lg); 18* this prints the month-to-date charges, resource limits, interactive usage for all shifts, 19* absentee usage in all queues, and io daemon usage in all queues. 20* 21* 2) default mode (called with no control_arg) 22* this lists the month-to-date charge, the resource limit, the interactive usage for all shifts, and the 23* absentee and io daemon usage for all queues. 24* 25* 3) brief mode (called specifying the control_arg -brief or -bf) 26* this lists the month-to-date charge, the resource limit, and totals for interactive, 27* absentee and io daemon usage. 28* 29* 4) totals mode (called specifying the control_arg -totals or -tt ) 30* this lists just the month-to-date charge and the resource limit. 31**/ 32 33 34 35 /****^ HISTORY COMMENTS: 36* 1) change(86-02-01,Gilcrease), approve(86-03-27,MCR7369), 37* audit(86-06-20,LJAdams), install(86-06-30,MR12.0-1081): 38* To make these first comments hcom-acceptible. J. Phillipps and THVV - 39* June 1972 J. Phillipps - revised and upgraded for version 2 PL/1 September 40* 1972 . - revised for memory and virtual cpu charging on 6180 March 1973 . 41* - updated headers and added absolute limit reporting a la sipb April 1976. 42* 43* T. Casey - August 1977 - to only print nonzero device charges and to 44* print some new ones. C. Hornig - June 1979 - to print usage even if 45* charge was zero. E. N. Kittlitz - June 1981 - UNCA rate structure 46* changes 47* 2) change(86-02-01,Gilcrease), approve(86-05-19,MCR7369), 48* audit(86-06-20,LJAdams), install(86-06-30,MR12.0-1081): 49* Add 'weekly' to cutoff table array. 50* END HISTORY COMMENTS */ 51 52 53 resource_usage: ru: procedure; 54 55 dcl crashes char (8) aligned, 56 answer char (46) varying, 57 answer1 char (47) varying, 58 answer2 char (29) varying, 59 answer3 char (18) varying, 60 j fixed bin, 61 logins char (7) aligned, 62 datestr char (16) aligned, 63 pit_name char (32) int static init ("pit"), 64 reset char (16) aligned; /* formatted string for time last reset PDT */ 65 66 67 dcl an fixed bin init (1), 68 al fixed bin (21), 69 nargs fixed bin, 70 absolute bit (1) init ("0"b), 71 cutoff bit (1) init ("0"b), 72 month bit (1) init ("0"b), 73 ec fixed bin (35), 74 (i, ii) fixed bin, 75 mode fixed bin init (3), 76 temp float bin init (0e0); 77 78 dcl (pp, ap) ptr; 79 80 dcl bchr char (al) unaligned based (ap); 81 82 dcl dev_usage_buffer char (160); /* stuff for printing device usage */ 83 dcl dub_array (160) char (1) unal based (addr (dev_usage_buffer)); 84 dcl dubp ptr; 85 dcl dubl fixed bin; 86 dcl based_dub char (dubl) based (dubp); 87 dcl (dubi, retlen) fixed bin; 88 dcl devh char (8) varying; 89 dcl dusw (16) bit (1) aligned; 90 dcl rs_name char (32) aligned; 91 dcl max_rs_number fixed bin; 92 93 dcl ndevices fixed bin; 94 dcl 1 dvt (16) aligned, 95 2 device_id char (8), 96 2 device_price (0:7) float bin; 97 98 dcl MILLION fixed bin (35) internal static init (1000000), 99 prettybigfloat float bin int static init (1e36); 100 101 dcl increment (0:6) char (12) aligned initial 102 ("never", "daily", "monthly", "yearly", "calendar_yr", "fiscal_yr", "weekly"); 103 104 dcl (addr, divide, float, length, mod, null, rtrim, substr) builtin; 105 106 /* procedures called by this program */ 107 108 dcl com_err_ entry options (variable), 109 cu_$arg_ptr entry (fixed bin, ptr, fixed bin (21), fixed bin (35)), 110 cu_$arg_count entry (fixed bin, fixed bin (35)), 111 date_time_ entry (fixed bin (71), char (*) aligned), 112 get_pdir_ entry () returns (char (168)), 113 hcs_$initiate entry (char (*), char (*), char (*), fixed bin (1), fixed bin (2), ptr, fixed bin (35)), 114 hcs_$terminate_noname entry (ptr, fixed bin (35)), 115 ioa_ entry options (variable), 116 ioa_$rsnnl entry options (variable); /* ctl,retstr,retlen,args */ 117 dcl system_info_$device_prices entry (fixed bin, ptr); 118 dcl system_info_$rs_name entry (fixed bin, char (*) aligned, fixed bin (35)); 119 dcl system_info_$max_rs_number entry (fixed bin); 120 121 dcl error_table_$badopt fixed bin (35) ext; 122 dcl error_table_$too_many_args fixed bin (35) ext; 123 124 1 1 /* BEGIN INCLUDE FILE ... user_attributes.incl.pl1 TAC 10/79 */ 1 2 1 3 1 4 /****^ HISTORY COMMENTS: 1 5* 1) change(86-12-11,Brunelle), approve(87-07-13,MCR7741), 1 6* audit(87-04-19,GDixon), install(87-08-04,MR12.1-1056): 1 7* Add incl for abs_attributes.incl.pl1 to automatically include absentee 1 8* attribute switches. 1 9* 2) change(87-04-19,GDixon), approve(87-07-13,MCR7741), 1 10* audit(87-07-16,Brunelle), install(87-08-04,MR12.1-1056): 1 11* A) Add USER_ATTRIBUTE_NAMES arrays. attribute_names.incl.pl1 can thereby 1 12* be deleted. 1 13* B) Add constants identifying attributes that can be changed by user at 1 14* login, etc. 1 15* END HISTORY COMMENTS */ 1 16 1 17 1 18 /* Modified 82-01-03 E. N. Kittlitz. to declare a complete level-1 structure */ 1 19 1 20 /* format: style4 */ 1 21 dcl 1 user_attributes aligned based, /* the user user_attributes */ 1 22 (2 administrator bit (1), /* 1 system administrator privileges */ 1 23 2 primary_line bit (1), /* 2 user has primary-line privileges */ 1 24 2 nobump bit (1), /* 2 user cannot be bumped */ 1 25 2 guaranteed_login bit (1), /* 4 user has guaranteed login privileges */ 1 26 2 anonymous bit (1), /* 5 used only in SAT. project may have anon.users */ 1 27 2 nopreempt bit (1), /* 6 used only in PDT. user not preemptable by others 1 28* . of same project (distinct from "nobump") */ 1 29 2 nolist bit (1), /* 7 don't list user on "who" */ 1 30 2 dialok bit (1), /* 8 user may have multiple consoles */ 1 31 2 multip bit (1), /* 9 user may have several processes */ 1 32 2 bumping bit (1), /* 10 in SAT. Can users in project bump each other? */ 1 33 2 brief bit (1), /* 11 no login or logout message */ 1 34 2 vinitproc bit (1), /* 12 user may change initial procedure */ 1 35 2 vhomedir bit (1), /* 13 user may change homedir */ 1 36 2 nostartup bit (1), /* 14 user does not want start_up.ec */ 1 37 2 sb_ok bit (1), /* 15 user may be standby */ 1 38 2 pm_ok bit (1), /* 16 user may be primary */ 1 39 2 eo_ok bit (1), /* 17 user may be edit_only */ 1 40 2 daemon bit (1), /* 18 user may login as daemon */ 1 41 2 vdim bit (1), /* 19 * OBSOLETE * user may change outer mdle */ 1 42 2 no_warning bit (1), /* 20 no warning message */ 1 43 2 igroup bit (1), /* 21 in SAT: this project may give its users individual groups 1 44* . in PDT: this user has an individual load control group */ 1 45 2 save_pdir bit (1), /* 22 save pdir after fatal process error */ 1 46 2 disconnect_ok bit (1), /* 23 ok to save user's disconnected processes */ 1 47 2 save_on_disconnect bit (1), /* 24 save them unless -nosave login arg is given */ 1 48 2 pad bit (12)) unaligned; 1 49 1 50 dcl USER_ATTRIBUTE_NAMES (0:24) char (20) int static options (constant) init 1 51 ("none", /* 0 */ 1 52 "administrator", /* 1 */ 1 53 "primary_line", /* 2 */ 1 54 "nobump", /* 3 */ 1 55 "guaranteed_login", /* 4 */ 1 56 "anonymous", /* 5 */ 1 57 "nopreempt", /* 6 */ 1 58 "nolist", /* 7 */ 1 59 "dialok", /* 8 */ 1 60 "multip", /* 9 */ 1 61 "bumping", /* 10 */ 1 62 "brief", /* 11 */ 1 63 "vinitproc", /* 12 */ 1 64 "vhomedir", /* 13 */ 1 65 "nostartup", /* 14 */ 1 66 "no_secondary", /* 15 */ 1 67 "no_prime", /* 16 */ 1 68 "no_eo", /* 17 */ 1 69 "daemon", /* 18 */ 1 70 "", /* 19 vdim OBSOLETE */ 1 71 "no_warning", /* 20 */ 1 72 "igroup", /* 21 */ 1 73 "save_pdir", /* 22 */ 1 74 "disconnect_ok", /* 23 */ 1 75 "save_on_disconnect"); /* 24 */ 1 76 1 77 dcl ALT_USER_ATTRIBUTE_NAMES (0:24) char (20) int static options (constant) init 1 78 ("null", /* 0 */ 1 79 "admin", /* 1 */ 1 80 "", "", /* 2 - 3 */ 1 81 "guar", /* 4 */ 1 82 "anon", /* 5 */ 1 83 "", "", /* 6 - 7 */ 1 84 "dial", /* 8 */ 1 85 "multi_login", /* 9 */ 1 86 "preempting", /* 10 */ 1 87 "", /* 11 */ 1 88 "v_process_overseer", /* 12 */ 1 89 "v_home_dir", /* 13 */ 1 90 "no_start_up", /* 14 */ 1 91 "no_sec", /* 15 */ 1 92 "no_primary", /* 16 */ 1 93 "no_edit_only", /* 17 */ 1 94 "op_login", /* 18 */ 1 95 "", /* 19 */ 1 96 "nowarn", /* 20 */ 1 97 "", "", "", /* 21 - 23 */ 1 98 "save"); /* 24 */ 1 99 1 100 dcl USER_ATTRIBUTES_always_allowed bit (36) aligned int static 1 101 options(constant) init("000000000010000000010000000000000000"b); 1 102 /* SAT/PDT attributes not needed for user to give (brief, no_warning) */ 1 103 1 104 dcl USER_ATTRIBUTES_default_in_pdt bit (36) aligned int static 1 105 options(constant) init("000000000010000000010000000000000000"b); 1 106 /* PDT value for (brief, no_warning) is default */ 1 107 1 108 dcl USER_ATTRIBUTES_settable_by_user bit (36) aligned int static 1 109 options(constant) init("000100000110010000010000000000000000"b); 1 110 /* user MIGHT set (bump, ns, brief, guar, no_warning) */ 1 111 2 1 /* BEGIN INCLUDE FILE ... user_abs_attributes.incl.pl1 */ 2 2 2 3 /* * * * * * * * * * * * * * * * * * * * * * * * * * */ 2 4 /* */ 2 5 /* This include file describes the attributes of an absentee job. It is */ 2 6 /* used by user_table_entry.incl.pl1, abs_message_format.incl.pl1 */ 2 7 /* and PIT.incl.pl1. */ 2 8 /* */ 2 9 /* * * * * * * * * * * * * * * * * * * * * * * * * * */ 2 10 2 11 /****^ HISTORY COMMENTS: 2 12* 1) change(86-12-08,GDixon), approve(87-07-13,MCR7741), 2 13* audit(87-07-16,Brunelle), install(87-08-04,MR12.1-1056): 2 14* Separated abs_attributes from the request structure 2 15* (abs_message_format.incl.pl1) so that the identical structure could be 2 16* used in the ute structure (user_table_entry.incl.pl1). 2 17* 2) change(87-04-19,GDixon), approve(87-07-13,MCR7741), 2 18* audit(87-07-16,Brunelle), install(87-08-04,MR12.1-1056): 2 19* Added ABS_ATTRIBUTE_NAMES array. 2 20* 3) change(87-11-11,Parisek), approve(88-02-11,MCR7849), 2 21* audit(88-03-22,Lippard), install(88-07-13,MR12.2-1047): 2 22* Added the no_start_up flag. SCP6367 2 23* END HISTORY COMMENTS */ 2 24 2 25 dcl 1 user_abs_attributes aligned based, 2 26 2 restartable bit (1) unaligned, /* 1 if request may be started over from the beginning */ 2 27 2 user_deferred_until_time bit (1) unaligned, /* 1 if request was specified as deferred */ 2 28 2 proxy bit (1) unaligned, /* 1 if request submitted for someone else */ 2 29 2 set_bit_cnt bit (1) unaligned, /* 1 if should set bit count after every write call */ 2 30 2 time_in_gmt bit (1) unaligned, /* 1 if deferred_time is in GMT */ 2 31 2 user_deferred_indefinitely bit (1) unaligned, /* 1 if operator is to say when to run it */ 2 32 2 secondary_ok bit (1) unaligned, /* 1 if ok to log in as secondary foreground user */ 2 33 2 truncate_absout bit (1) unaligned, /* 1 if .absout is to be truncated */ 2 34 2 restarted bit (1) unaligned, /* 1 if job is restarted */ 2 35 2 no_start_up bit (1) unaligned, /* 1 if requested -ns */ 2 36 2 attributes_pad bit (26) unaligned; 2 37 2 38 dcl ABS_ATTRIBUTE_NAMES (10) char (28) varying int static options(constant) init( 2 39 "restartable", 2 40 "user_deferred_until_time", 2 41 "proxy", 2 42 "set_bit_cnt", 2 43 "time_in_gmt", 2 44 "user_deferred_indefinitely", 2 45 "secondary_ok", 2 46 "truncate_absout", 2 47 "restarted", 2 48 "no_start_up"); 2 49 2 50 /* END INCLUDE FILE ... user_abs_attributes.incl.pl1 */ 2 51 1 112 1 113 1 114 /* END INCLUDE FILE ... user_attributes.incl.pl1 */ 125 3 1 /* BEGIN INCLUDE FILE ... pit.incl.pl1 */ 3 2 3 3 /****^ ******************************************** 3 4* * * 3 5* * Copyright, (C) Honeywell Bull Inc., 1988 * 3 6* * * 3 7* ******************************************** */ 3 8 3 9 /* Requires user_attributes.incl.pl1 */ 3 10 /* Declaration of the Process Inititalization Table (PIT) */ 3 11 3 12 /****^ HISTORY COMMENTS: 3 13* 1) change(86-03-01,Gilcrease), approve(86-03-27,MCR7370), 3 14* audit(86-06-25,Lippard), install(86-06-30,MR12.0-1082): 3 15* First comment for hcom. Modified 750430 by PG to add terminal_access_class 3 16* Modified 6/20/77 by J. Stern to add term_type_name Modified Feb 1980 by M. 3 17* B. Armstrong to implement multiple rate structures. (UNCA) Modified by R. 3 18* McDonald May 1980 to include page charges, replaces cpu in iod (UNCA) 3 19* Modified by Benson I. Margulies November 1981 do declare pit_$, pit_ptr, 3 20* and unaligned character strings. Modified by E. N. Kittlitz January 1982 3 21* for user_attributes.incl.pl1 changes Modified by E. N. Kittlitz October 3 22* 1982 for request_id. Modified by BIM 1984-09-12 for auth range. The max 3 23* copies the pds, but this is the only home of the min. 3 24* 2) change(86-03-01,Gilcrease), approve(86-03-27,MCR7370), 3 25* audit(86-06-25,Lippard), install(86-06-30,MR12.0-1082): 3 26* Add the truncate_absout and restarted bits for the 3 27* -truncate .absout SCP 6297, version 3. 3 28* 3) change(86-12-11,GDixon), approve(87-07-16,MCR7741), 3 29* audit(87-07-16,Brunelle), install(87-08-04,MR12.1-1056): 3 30* Changed structure under pit.abs_attributes to use like structure in 3 31* abs_attributes.incl.pl1. This allows the same attributes to be used 3 32* in abs_message_format.incl.pl1 and user_table_entry.incl.pl1 as well as 3 33* this include file. 3 34* 4) change(88-06-03,Parisek), approve(88-06-10,MCR7920), 3 35* audit(88-06-23,Hunter), install(87-07-05,MR12.2-1053): 3 36* Remove "pitmsg" in END comment string. pitmsg.incl.pl1 is no longer a 3 37* name of pit.incl.pl1. 3 38* 5) change(88-07-11,Parisek), approve(88-07-11,MCR7849), 3 39* audit(88-07-03,Lippard), install(88-07-13,MR12.2-1047): 3 40* Removed the ringpad element and added the min_ring & max_ring elements so 3 41* users may access their lowest and/or highest possible login ring value. 3 42* SCP6367. 3 43* END HISTORY COMMENTS */ 3 44 3 45 3 46 /* format: style4 */ 3 47 declare pit_$ bit (36) aligned external static; 3 48 declare pit_ptr pointer; 3 49 3 50 dcl 1 pit aligned based (pit_ptr), 3 51 2 version fixed bin, /* indicates which version of the pit */ 3 52 2 process_type fixed bin, /* initializer, interactive, or absentee process */ 3 53 2 login_responder char (64) unal, /* path name of login responder */ 3 54 3 55 /* All of these are going to be word aligned whether or not they are declared aligned, 3 56* and unaligning them cleans up code in many places */ 3 57 3 58 2 homedir char (64) unal, /* path name of home directory */ 3 59 2 project char (28) unal, /* name of this process' project affiliation */ 3 60 2 account char (32) unal, /* name of account to which this process is charged */ 3 61 2 n_processes fixed bin, /* number of previous processes for this session */ 3 62 2 login_time fixed bin (71), /* clock time at login */ 3 63 2 proc_creation_time fixed bin (71), /* clock time at creation of this process */ 3 64 2 old_proc_cpu fixed bin (71), /* cpu time used by previous processes in this session */ 3 65 2 user_weight fixed bin, /* weight of this process */ 3 66 2 anonymous fixed bin, /* 1 if anonymous user */ 3 67 2 login_name char (28) unal, /* name of user given at login */ 3 68 2 logout_pid bit (36), /* process id of answering service */ 3 69 2 logout_channel fixed bin (71), /* channel for signalling logouts to answering service */ 3 70 2 group char (8) unal, /* party group */ 3 71 2 min_ring fixed bin, /* min ring */ 3 72 2 max_ring fixed bin, /* max ring */ 3 73 2 at like user_attributes aligned, /* include user_attributes.incl.pl1 */ 3 74 2 whox fixed bin, /* this process's index in whotab (or 0) */ 3 75 2 outer_module char (32) unaligned, 3 76 2 pad (2) fixed bin, 3 77 2 dont_call_init_admin bit (1) aligned, /* Call process_overseer_ directly */ 3 78 2 terminal_access_class bit (72) aligned, /* access class of user's terminal */ 3 79 2 dollar_charge float bin, /* Month-to-date expenditure */ 3 80 2 dollar_limit float bin, /* Limit stop on usage */ 3 81 2 shift_limit (0:7) float bin, /* Stops on each shift's usage */ 3 82 2 logins fixed bin, /* Number of logins this month */ 3 83 2 crashes fixed bin, /* Number of sessions crashed */ 3 84 2 interactive (0:7), /* interactive usage by shift */ 3 85 3 charge float bin, /* Total charge */ 3 86 3 xxx fixed bin, 3 87 3 cpu fixed bin (71), /* CPU usage in microseconds */ 3 88 3 core fixed bin (71), /* Memory usage in page-microseconds */ 3 89 3 connect fixed bin (71), /* Connect time in microseconds */ 3 90 3 io_ops fixed bin (71), /* Terminal I/O operations */ 3 91 2 absentee (4), /* Absentee usage by queue */ 3 92 3 charge float bin, /* Total absentee charge */ 3 93 3 jobs fixed bin, /* Number of jobs */ 3 94 3 cpu fixed bin (71), /* CPU usage in microseconds */ 3 95 3 memory fixed bin (71), /* Memory usage in mu */ 3 96 2 iod (4), /* IO Daemon usage, by queue */ 3 97 3 charge float bin, /* Total charge */ 3 98 3 pieces fixed bin, /* Number of requests */ 3 99 3 pad fixed bin (35), 3 100 3 pages fixed bin (35), /* number of pages output */ 3 101 3 lines fixed bin (71), /* Record count */ 3 102 2 devices (16) float bin, /* Usage of attached devices */ 3 103 2 time_last_reset fixed bin (71), /* time last updated the PDT */ 3 104 2 absolute_limit float bin, /* Limit, not reset monthly */ 3 105 2 absolute_spent float bin, /* Spending against this */ 3 106 2 absolute_cutoff fixed bin (71), /* Spending will be reset on this date */ 3 107 2 absolute_increm fixed bin, /* .. time increment code. 0 = don't reset */ 3 108 2 rs_number fixed bin (9) unsigned unaligned, /* rate structure number (0= default rates) */ 3 109 2 pad1a fixed bin (27) unsigned unaligned, /* remainder of word */ 3 110 2 request_id fixed bin (71), /* absentee request id */ 3 111 2 authorization_range (2) bit (72) aligned, 3 112 2 pad1 (73) fixed bin, /* extra space */ 3 113 2 charge_type fixed bin, /* device charge type of console */ 3 114 2 term_type_name char (32) unal, /* terminal type name */ 3 115 2 line_type fixed bin, /* line type of user's console */ 3 116 2 tty_type fixed bin, /* old terminal type (obsolete, kept for compatibility) */ 3 117 2 service_type fixed bin, /* type of service console is performing */ 3 118 2 tty_answerback char (4) unaligned, /* original answerback of user's console */ 3 119 2 old_tty char (6), /* (obsolete) attachment name of user's console */ 3 120 2 standby fixed bin, /* 1 if standby user */ 3 121 2 login_line char (120) unal, /* line typed at login */ 3 122 2 cant_bump_until fixed bin (71), /* cannot be preempted until this time (0 for abs) */ 3 123 2 input_seg char (168) unal, /* path name of absentee input file */ 3 124 2 output_seg char (168) unal, /* path name of absentee output file */ 3 125 2 max_cpu_time fixed bin, /* max number of seconds allowed to this absentee proc */ 3 126 2 abs_queue fixed bin, /* absentee queue if absentee, else -1 */ 3 127 2 abs_attributes aligned like user_abs_attributes, /* include abs_attributes.incl.pl1 */ 3 128 2 arg_info_ptr fixed bin (18) unsigned, /* Relative pointer to information on absentee args. */ 3 129 2 old_proc_core fixed bin (71), /* Memory usage by previous processes in this session */ 3 130 2 old_proc_io_ops fixed bin (71), /* I/O operations from previous processes in this session */ 3 131 2 tty char (32) unaligned, /* Attachment name of users channel */ 3 132 2 start_arg_info fixed bin; /* Put absentee args information here. */ 3 133 3 134 3 135 /* Structure to contain information on absentee arguments */ 3 136 dcl 1 arg_info aligned based, 3 137 2 arg_count fixed bin, /* Number of arguments for replacement in absentee segment */ 3 138 2 ln_args fixed bin, /* Length of string containing arguments. */ 3 139 2 arg_lengths (25 refer (arg_info.arg_count)) fixed bin, /* Array of argument lengths */ 3 140 2 args char (128 refer (arg_info.ln_args)) unal; 3 141 /* Args used for replacement in absentee control segment. */ 3 142 3 143 declare PIT_version_3 fixed bin int static options (constant) init (3); 3 144 3 145 /* END INCLUDE FILE ... pit.incl.pl1 */ 126 127 128 129 130 /* ====================================================== */ 131 132 call system_info_$max_rs_number (max_rs_number); 133 134 call hcs_$initiate ((get_pdir_ ()), pit_name, "", 0, 1, pp, ec); /* get ptr to PIT in process dir */ 135 if pp = null then do; 136 call com_err_ (ec, "resource_usage", "pit"); 137 return; 138 end; 139 call cu_$arg_count (nargs, ec); 140 if ec ^= 0 then go to argerr; 141 if nargs > 1 then do; 142 call com_err_ (error_table_$too_many_args, "resource_usage", "This command only takes one argument."); 143 return; 144 end; 145 146 do an = 1 to nargs; 147 call cu_$arg_ptr (an, ap, al, ec); /* see which option was specified */ 148 if ec ^= 0 then go to argerr; 149 /* default mode = 3 */ 150 else if bchr = "-long" then mode = 2; /* if arg specifies long option, set mode */ 151 else if bchr = "-lg" then mode = 2; 152 else if bchr = "-brief" then mode = 1; /* if arg specifies brief option, set mode accordingly */ 153 else if bchr = "-bf" then mode = 1; 154 else if bchr = "-tt" | bchr = "-totals" | bchr = "-total" then mode = 0; 155 /* if no arg, default mode is an expanded form of brief */ 156 else do; 157 call com_err_ (error_table_$badopt, "resource_usage", """^a""", bchr); 158 return; 159 end; 160 end; 161 162 if mode = 0 then do; /* total mode is specified */ 163 call ioa_$rsnnl ("Month-to-Date: $^9.2f; Limit: $^9a; ", 164 answer, j, pp -> pit.dollar_charge, (cv_limit (pp -> pit.dollar_limit))); 165 /* if cutoff set by proj administrator, print it also */ 166 if substr ((cv_limit (pp -> pit.absolute_limit)), 6) = "open" then do; 167 call ioa_$rsnnl ("Total: $^9.2f;", answer3, j, pp -> pit.absolute_spent); 168 call ioa_ ("^/^a", answer || answer3); 169 end; 170 else do; 171 call ioa_$rsnnl ("Total: $^9.2f; Absolute Limit: $^9a; ", 172 answer1, j, pp -> pit.absolute_spent, (cv_limit (pp -> pit.absolute_limit))); 173 call date_time_ (pp -> pit.absolute_cutoff, datestr); 174 call ioa_$rsnnl ("Reset: ^a, ^a;", 175 answer2, j, substr (datestr, 1, 8), increment (pp -> pit.absolute_increm)); 176 call ioa_ ("^/^a", answer); 177 call ioa_ (answer1 || answer2); 178 end; 179 goto endit1; 180 181 end; 182 call date_time_ (pp -> pit.proc_creation_time, datestr); /* usage from beginning of mo. to time process created */ 183 call date_time_ (pp -> pit.time_last_reset, reset); /* format time last reset PDT */ 184 call ioa_ ("^/^a.^a Report from ^a to ^a", pp -> pit.login_name, pp -> pit.project, reset, datestr); 185 if max_rs_number > 0 then do; 186 call system_info_$rs_name ((pp -> pit.rs_number), rs_name, ec); 187 if ec ^= 0 then call com_err_ (ec, "resource_usage", 188 "For rate structure ^d. Contact your system administrator.", pp -> pit.rs_number); 189 call ioa_ ("^5xRate Structure -- ^a", rs_name); 190 end; 191 192 quick: 193 if mode = 2 then do; /* long mode */ 194 if substr ((cv_limit (pp -> pit.absolute_limit)), 6) = "open" then do; 195 call ioa_$rsnnl ("Month-to-Date: $^9.2f; Limit: $^9a; ", 196 answer, j, pp -> pit.dollar_charge, (cv_limit (pp -> pit.dollar_limit))); 197 call ioa_$rsnnl ("Total: $^9.2f;", answer3, j, pp -> pit.absolute_spent); 198 call ioa_ (answer || answer3); 199 end; 200 else do; 201 call ioa_$rsnnl ("Total: $^9.2f, Absolute Limit: $^9a; ", 202 answer1, j, pp -> pit.absolute_spent, (cv_limit (pp -> pit.absolute_limit))); 203 call date_time_ (pp -> pit.absolute_cutoff, datestr); 204 call ioa_$rsnnl ("Reset: ^a, ^a;", 205 answer2, j, substr (datestr, 1, 8), increment (pp -> pit.absolute_increm)); 206 call ioa_ (answer1 || answer2); 207 end; 208 end; 209 210 else do; 211 call ioa_ ("Month-To-Date: $^9.2f; Limit: $^9a;", 212 pp -> pit.dollar_charge, (cv_limit (pp -> pit.dollar_limit))); 213 end; 214 do i = 1 to 7, 0; /* sum interactive charge */ 215 temp = temp + pp -> pit.interactive (i).charge; 216 end; 217 if temp = 0e0 then do; /* if no usage, don't print header */ 218 call ioa_ ("^/Interactive Usage: none;"); 219 go to abstee; 220 end; 221 222 /* P R I N T H E A D E R S */ 223 224 if pp -> pit.crashes = 1 then 225 crashes = "crash. "; /* do singular and plural parse */ 226 else crashes = "crashes."; 227 if pp -> pit.logins = 1 then 228 logins = "login, "; 229 else logins = "logins,"; 230 if mode = 2 then do; /* long mode header for interactive usage */ 231 call ioa_ ("^/Interactive Usage: $^8.2f;^2x^2d^1x^8a^2d^1x^7a", 232 temp, pp -> pit.logins, logins, pp -> pit.crashes, crashes); 233 call ioa_ ("^4xshift^2x$charge^4x$limit^8xvcpu^4xconnect^4xterminal i/o^2xmemory/kmu"); 234 end; 235 else if mode = 1 then do; /* brief mode header for interactive usage */ 236 call ioa_ ("^/Interactive Usage: $^8.2f;^2x^2d^1x^8a^2d^1x^7a", 237 temp, pp -> pit.logins, logins, pp -> pit.crashes, crashes); 238 go to abstee; 239 end; 240 else if mode = 3 then do; /* default mode */ 241 call ioa_ ("^/Interactive Usage: $^8.2f;^2x^2d^1x^8a^2d^1x^7a", 242 temp, pp -> pit.logins, logins, pp -> pit.crashes, crashes); 243 call ioa_ ("^4xshift^2x$charge^4x$limit"); 244 end; 245 temp = 0e0; /* clear temp */ 246 247 248 /* P R I N T R E S O U R C E U S A G E */ 249 250 251 /* print out resource usage */ 252 253 do i = 1 to 7, 0; 254 if pp -> pit.shift_limit (i) > prettybigfloat 255 then if pp -> pit.interactive (i).charge = 0e0 256 & pp -> pit.interactive (i).cpu = 0 257 & pp -> pit.interactive (i).connect = 0 258 & pp -> pit.interactive (i).core = 0 259 & pp -> pit.interactive (i).io_ops = 0 260 then goto skip; /* don't print useless lines */ 261 if mode = 2 then do; /* long mode */ 262 call ioa_ ("^5x^1d^4x^8.2f^1x^9a^3x^9a^2x^9a^5x^11.1f^1x^11.1f", i, 263 pp -> pit.interactive (i).charge, (cv_limit (pp -> pit.shift_limit (i))), 264 (cv_time (pp -> pit.interactive (i).cpu)), (cv_time (pp -> pit.interactive (i).connect)), 265 float (pp -> pit.interactive (i).io_ops/1e3), float (pp -> pit.interactive (i).core/1e6)); 266 end; 267 else if mode = 3 then do; /* default mode */ 268 call ioa_ ("^5x^1d^4x^8.2f^1x^9a", i, pp -> pit.interactive (i).charge, 269 (cv_limit (pp -> pit.shift_limit (i)))); 270 skip2: end; 271 skip: end; 272 273 abstee: temp = 0e0; /* clear temp */ 274 do ii = 1 to 4; /* scan for absentee usage */ 275 temp = temp + pp -> pit.absentee (ii).charge; 276 end; 277 if temp = 0e0 then do; 278 call ioa_ ("^/Absentee Usage: none;"); 279 go to iod; 280 end; 281 else call ioa_ ("^/Absentee Usage: $^8.2f;", temp); 282 if mode = 1 then go to iod; /* brief mode exit here */ 283 else if mode = 3 then do; /* default mode */ 284 call ioa_ ("^4xqueue^2x$charge^6xjobs"); 285 do ii = 1 to 4; 286 if pp -> pit.absentee (ii).charge = 0e0 then go to next; 287 call ioa_ ("^5x^1d^4x^8.2f^6x^4d", ii, pp -> pit.absentee (ii).charge, pp -> pit.absentee (ii).jobs); 288 next: end; 289 end; 290 if mode = 2 then do; /* long mode */ 291 call ioa_ ("^4xqueue^2x$charge^6xjobs^8xvcpu^2xmemory/kmu"); 292 293 do ii = 1 to 4; 294 if pp -> pit.absentee (ii).charge = 0e0 then go to skip3; 295 call ioa_ ("^5x^1d^4x^8.2f^6x^4d^3x^9a^2x^10.1f", ii, pp -> pit.absentee (ii).charge, 296 pp -> pit.absentee (ii).jobs, cv_time (pp -> absentee (ii).cpu), 297 float (pp -> pit.absentee (ii).memory/1e6)); 298 skip3: end; 299 end; 300 iod: temp = 0e0; 301 do ii = 1 to 4; 302 temp = temp + pp -> pit.iod (ii).charge; 303 end; 304 if temp = 0e0 then do; 305 call ioa_ ("^/IO Daemon Usage: none;"); 306 go to device; 307 end; 308 else call ioa_ ("^/IO Daemon Usage: $^8.2f;", temp); 309 if mode = 1 then go to device; /* brief mode exit here */ 310 else if mode = 3 then do; /* default mode */ 311 call ioa_ ("^4xqueue^2x$charge^6xlines"); 312 do ii = 1 to 4; 313 if pp -> pit.iod (ii).charge = 0e0 then go to next2; 314 call ioa_ ("^4x^1x^1d^4x^8.2f^x^10d", 315 ii, pp -> pit.iod (ii).charge, pp -> pit.iod (ii).lines); 316 next2: end; 317 end; 318 if mode = 2 then do; /* long mode */ 319 call ioa_ ("^4xqueue^2x$charge^4xpieces^7xpages^8xlines"); 320 do ii = 1 to 4; 321 if pp -> pit.iod (ii).charge = 0e0 then go to skip4; 322 call ioa_ ("^4x^1x^1d^4x^8.2f^6x^4d^3x^9d^x^12d", 323 ii, pp -> pit.iod (ii).charge, pp -> pit.iod (ii).pieces, 324 pp -> pit.iod (ii).pages, pp -> pit.iod (ii).lines); 325 skip4: end; 326 end; 327 device: temp = 0e0; /* clear temp */ 328 do ii = 1 to 16; /* scan for device usage */ 329 if pp -> pit.devices (ii) = 0e0 330 then dusw (ii) = ""b; 331 else dusw (ii) = "1"b; 332 temp = temp + pp -> pit.devices (ii); 333 end; 334 if temp = 0e0 then do; 335 if mode = 2 then 336 call ioa_ ("^/Device Usage: none;"); /* only print in long mode */ 337 end; 338 else do; 339 call ioa_ ("^/Device Usage: $^8.2f;", temp); 340 341 /* The purpose of the following code is to print a column only for devices with nonzero usage. */ 342 343 call system_info_$device_prices (ndevices, addr (dvt)); /* get device names and prices (but only use names) */ 344 dev_usage_buffer = ""; /* clear buffer before making heading */ 345 dubi = 1; /* set index to first character position in buffer */ 346 do i = 1 to 16; /* put each device name in heading */ 347 if dusw (i) then do; /* but only if it has nonzero usage */ 348 devh = rtrim (device_id (i)); /* copy name and see how long it really is */ 349 dubi = dubi + 9 - length (devh); /* compute how far to skip to right-adjust name */ 350 substr (dev_usage_buffer, dubi, 1) = "$"; /* put in leading dollar sign */ 351 substr (dev_usage_buffer, dubi+1, length (devh)) = devh; /* put in the name */ 352 dubi = dubi + 1 + length (devh); /* advance char index past name */ 353 end; 354 end; 355 call ioa_ ("^a", dev_usage_buffer); /* print the heading */ 356 357 dev_usage_buffer = ""; /* clear buffer before formatting usage figures */ 358 dubl = length (dev_usage_buffer); /* initialize char counters */ 359 dubi = 1; 360 do i = 1 to 16; /* print usage for each device */ 361 if dusw (i) then do; /* only if it is nonzero */ 362 dubp = addr (dub_array (dubi)); /* get addr of where to put next usage field */ 363 call ioa_$rsnnl ("^3x^7.2f", based_dub, retlen, pp -> pit.devices (i)); /* format the usage figure */ 364 dubl = dubl - retlen; /* decrement remaining length of buffer */ 365 dubi = dubi + retlen; /* advance index to next available character position */ 366 end; 367 end; 368 call ioa_ ("^a", dev_usage_buffer); /* print the usage figures */ 369 end; 370 endit: call ioa_ (""); 371 endit1: call hcs_$terminate_noname (pp, ec); 372 return; 373 374 argerr: call com_err_ (ec, "resource_usage"); 375 return; 376 377 378 /* =========================================================== */ 379 380 381 382 cv_time: procedure (time) returns (char (9) aligned); 383 384 /* procedure to convert from fixed bin (71) to a nice formatted string of hrs: mins: secs */ 385 386 387 388 dcl time fixed bin (71), 389 j fixed bin, 390 hours fixed bin, 391 minutes fixed bin, 392 seconds fixed bin, 393 answer char (9) aligned; 394 395 396 seconds = divide (time, MILLION, 35, 0); 397 minutes = divide (seconds, 60, 35, 0); 398 seconds = mod (seconds, 60); /* get rid of the remainder */ 399 hours = divide (minutes, 60, 35, 0); 400 minutes = mod (minutes, 60); /* get rid of the remainder */ 401 402 call ioa_$rsnnl ("^3d:^2d:^2d", answer, j, hours, minutes, seconds); 403 if substr (answer, 5, 1) = " " then substr (answer, 5, 1) = "0"; 404 if substr (answer, 8, 1) = " " then substr (answer, 8, 1) = "0"; 405 406 return (answer); 407 end; 408 409 410 411 412 /* = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = */ 413 414 cv_limit: procedure (limit) returns (char (9) aligned); 415 416 /* procedure to convert a float bin $limit into either the string, "open", if $limit is >= 1e37, 417* or to convert a float bin $limit into an integer $limit */ 418 419 dcl limit float bin, 420 lim char (9) aligned, 421 jj fixed bin, 422 itemp fixed bin; 423 424 425 if limit >= prettybigfloat then do; 426 lim = " open"; 427 go to char; 428 end; 429 else do; 430 itemp = limit; 431 call ioa_$rsnnl ("^6d.00", lim, jj, itemp); 432 end; 433 char: return (lim); 434 end; 435 436 437 438 test_ru: entry (xpit); /* enter here if using an experimental PIT */ 439 440 dcl xpit char (*); 441 442 pit_name = xpit; 443 444 445 446 end resource_usage; SOURCE FILES USED IN THIS COMPILATION. LINE NUMBER DATE MODIFIED NAME PATHNAME 0 07/13/88 0935.5 resource_usage.pl1 >special_ldd>install>MR12.2-1047>resource_usage.pl1 125 1 08/06/87 0913.6 user_attributes.incl.pl1 >ldd>include>user_attributes.incl.pl1 1-112 2 07/13/88 0900.1 user_abs_attributes.incl.pl1 >special_ldd>install>MR12.2-1047>user_abs_attributes.incl.pl1 126 3 07/13/88 0930.5 pit.incl.pl1 >special_ldd>install>MR12.2-1047>pit.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. MILLION 000001 constant fixed bin(35,0) initial dcl 98 ref 396 absentee 264 based structure array level 2 dcl 3-50 absolute 000171 automatic bit(1) initial packed unaligned dcl 67 set ref 67* absolute_cutoff 370 based fixed bin(71,0) level 2 dcl 3-50 set ref 173* 203* absolute_increm 372 based fixed bin(17,0) level 2 dcl 3-50 ref 174 204 absolute_limit 366 based float bin(27) level 2 dcl 3-50 set ref 166* 171* 194* 201* absolute_spent 367 based float bin(27) level 2 dcl 3-50 set ref 167* 171* 197* 201* addr builtin function dcl 104 ref 343 343 362 362 al 000167 automatic fixed bin(21,0) dcl 67 set ref 147* 150 151 152 153 154 154 154 157 157 an 000166 automatic fixed bin(17,0) initial dcl 67 set ref 67* 146* 147* answer 000102 automatic varying char(46) dcl 55 in procedure "ru" set ref 163* 168 176* 195* 198 answer 000626 automatic char(9) dcl 388 in procedure "cv_time" set ref 402* 403 403* 404 404* 406 answer1 000117 automatic varying char(47) dcl 55 set ref 171* 177 201* 206 answer2 000134 automatic varying char(29) dcl 55 set ref 174* 177 204* 206 answer3 000145 automatic varying char(18) dcl 55 set ref 167* 168 197* 198 ap 000204 automatic pointer dcl 78 set ref 147* 150 151 152 153 154 154 154 157 based_dub based char packed unaligned dcl 86 set ref 363* bchr based char packed unaligned dcl 80 set ref 150 151 152 153 154 154 154 157* charge 314 based float bin(27) array level 3 in structure "pit" dcl 3-50 in procedure "ru" set ref 302 313 314* 321 322* charge 144 based float bin(27) array level 3 in structure "pit" dcl 3-50 in procedure "ru" set ref 215 254 262* 268* charge 264 based float bin(27) array level 3 in structure "pit" dcl 3-50 in procedure "ru" set ref 275 286 287* 294 295* com_err_ 000020 constant entry external dcl 108 ref 136 142 157 187 374 connect 152 based fixed bin(71,0) array level 3 dcl 3-50 set ref 254 262* core 150 based fixed bin(71,0) array level 3 dcl 3-50 ref 254 262 262 cpu 146 based fixed bin(71,0) array level 3 in structure "pit" dcl 3-50 in procedure "ru" set ref 254 262* cpu 266 based fixed bin(71,0) array level 3 in structure "pit" dcl 3-50 in procedure "ru" set ref 295* 295* crashes 000100 automatic char(8) dcl 55 in procedure "ru" set ref 224* 226* 231* 236* 241* crashes 142 based fixed bin(17,0) level 2 in structure "pit" dcl 3-50 in procedure "ru" set ref 224 231* 236* 241* cu_$arg_count 000024 constant entry external dcl 108 ref 139 cu_$arg_ptr 000022 constant entry external dcl 108 ref 147 cutoff 000172 automatic bit(1) initial packed unaligned dcl 67 set ref 67* date_time_ 000026 constant entry external dcl 108 ref 173 182 183 203 datestr 000156 automatic char(16) dcl 55 set ref 173* 174 174 182* 184* 203* 204 204 dev_usage_buffer 000206 automatic char(160) packed unaligned dcl 82 set ref 344* 350* 351* 355* 357* 358 362 368* devh 000263 automatic varying char(8) dcl 88 set ref 348* 349 351 351 352 device_id 000320 automatic char(8) array level 2 dcl 94 set ref 348 devices 344 based float bin(27) array level 2 dcl 3-50 set ref 329 332 363* divide builtin function dcl 104 ref 396 397 399 dollar_charge 127 based float bin(27) level 2 dcl 3-50 set ref 163* 195* 211* dollar_limit 130 based float bin(27) level 2 dcl 3-50 set ref 163* 195* 211* dub_array based char(1) array packed unaligned dcl 83 set ref 362 dubi 000261 automatic fixed bin(17,0) dcl 87 set ref 345* 349* 349 350 351 352* 352 359* 362 365* 365 dubl 000260 automatic fixed bin(17,0) dcl 85 set ref 358* 363 363 364* 364 dubp 000256 automatic pointer dcl 84 set ref 362* 363 dusw 000266 automatic bit(1) array dcl 89 set ref 329* 331* 347 361 dvt 000320 automatic structure array level 1 dcl 94 set ref 343 343 ec 000174 automatic fixed bin(35,0) dcl 67 set ref 134* 136* 139* 140 147* 148 186* 187 187* 371* 374* error_table_$badopt 000050 external static fixed bin(35,0) dcl 121 set ref 157* error_table_$too_many_args 000052 external static fixed bin(35,0) dcl 122 set ref 142* float builtin function dcl 104 ref 262 262 262 262 295 295 get_pdir_ 000030 constant entry external dcl 108 ref 134 hcs_$initiate 000032 constant entry external dcl 108 ref 134 hcs_$terminate_noname 000034 constant entry external dcl 108 ref 371 hours 000623 automatic fixed bin(17,0) dcl 388 set ref 399* 402* i 000175 automatic fixed bin(17,0) dcl 67 set ref 214* 215* 253* 254 254 254 254 254 254 262* 262 262 262 262 262 262 262 262 268* 268 268* 346* 347 348* 360* 361 363* ii 000176 automatic fixed bin(17,0) dcl 67 set ref 274* 275* 285* 286 287* 287 287* 293* 294 295* 295 295 295 295 295 295* 301* 302* 312* 313 314* 314 314* 320* 321 322* 322 322 322 322* 328* 329 329 331 332* increment 000560 automatic char(12) initial array dcl 101 set ref 101* 101* 101* 101* 101* 101* 101* 174* 204* interactive 144 based structure array level 2 dcl 3-50 io_ops 154 based fixed bin(71,0) array level 3 dcl 3-50 ref 254 262 262 ioa_ 000036 constant entry external dcl 108 ref 168 176 177 184 189 198 206 211 218 231 233 236 241 243 262 268 278 281 284 287 291 295 305 308 311 314 319 322 335 339 355 368 370 ioa_$rsnnl 000040 constant entry external dcl 108 ref 163 167 171 174 195 197 201 204 363 402 431 iod 314 based structure array level 2 dcl 3-50 itemp 000644 automatic fixed bin(17,0) dcl 419 set ref 430* 431* j 000153 automatic fixed bin(17,0) dcl 55 in procedure "ru" set ref 163* 167* 171* 174* 195* 197* 201* 204* j 000622 automatic fixed bin(17,0) dcl 388 in procedure "cv_time" set ref 402* jj 000643 automatic fixed bin(17,0) dcl 419 set ref 431* jobs 265 based fixed bin(17,0) array level 3 dcl 3-50 set ref 287* 295* length builtin function dcl 104 ref 349 351 352 358 lim 000640 automatic char(9) dcl 419 set ref 426* 431* 433 limit parameter float bin(27) dcl 419 ref 414 425 430 lines 320 based fixed bin(71,0) array level 3 dcl 3-50 set ref 314* 322* login_name 72 based char(28) level 2 packed packed unaligned dcl 3-50 set ref 184* logins 000154 automatic char(7) dcl 55 in procedure "ru" set ref 227* 229* 231* 236* 241* logins 141 based fixed bin(17,0) level 2 in structure "pit" dcl 3-50 in procedure "ru" set ref 227 231* 236* 241* max_rs_number 000316 automatic fixed bin(17,0) dcl 91 set ref 132* 185 memory 270 based fixed bin(71,0) array level 3 dcl 3-50 ref 295 295 minutes 000624 automatic fixed bin(17,0) dcl 388 set ref 397* 399 400* 400 402* mod builtin function dcl 104 ref 398 400 mode 000177 automatic fixed bin(17,0) initial dcl 67 set ref 67* 150* 151* 152* 153* 154* 162 192 230 235 240 261 267 282 283 290 309 310 318 335 month 000173 automatic bit(1) initial packed unaligned dcl 67 set ref 67* nargs 000170 automatic fixed bin(17,0) dcl 67 set ref 139* 141 146 ndevices 000317 automatic fixed bin(17,0) dcl 93 set ref 343* null builtin function dcl 104 ref 135 pages 317 based fixed bin(35,0) array level 3 dcl 3-50 set ref 322* pieces 315 based fixed bin(17,0) array level 3 dcl 3-50 set ref 322* pit based structure level 1 dcl 3-50 pit_name 000010 internal static char(32) initial packed unaligned dcl 55 set ref 134* 442* pp 000202 automatic pointer dcl 78 set ref 134* 135 163 163 166 167 171 171 173 174 182 183 184 184 186 187 194 195 195 197 201 201 203 204 211 211 215 224 227 231 231 236 236 241 241 254 254 254 254 254 254 262 262 262 262 262 262 262 262 268 268 275 286 287 287 294 295 295 295 295 295 295 302 313 314 314 321 322 322 322 322 329 332 363 371* prettybigfloat 000000 constant float bin(27) initial dcl 98 ref 254 425 proc_creation_time 64 based fixed bin(71,0) level 2 dcl 3-50 set ref 182* project 42 based char(28) level 2 packed packed unaligned dcl 3-50 set ref 184* reset 000162 automatic char(16) dcl 55 set ref 183* 184* retlen 000262 automatic fixed bin(17,0) dcl 87 set ref 363* 364 365 rs_name 000306 automatic char(32) dcl 90 set ref 186* 189* rs_number 373 based fixed bin(9,0) level 2 packed packed unsigned unaligned dcl 3-50 set ref 186 187* rtrim builtin function dcl 104 ref 348 seconds 000625 automatic fixed bin(17,0) dcl 388 set ref 396* 397 398* 398 402* shift_limit 131 based float bin(27) array level 2 dcl 3-50 set ref 254 262* 268* substr builtin function dcl 104 set ref 166 174 174 194 204 204 350* 351* 403 403* 404 404* system_info_$device_prices 000042 constant entry external dcl 117 ref 343 system_info_$max_rs_number 000046 constant entry external dcl 119 ref 132 system_info_$rs_name 000044 constant entry external dcl 118 ref 186 temp 000200 automatic float bin(27) initial dcl 67 set ref 67* 215* 215 217 231* 236* 241* 245* 273* 275* 275 277 281* 300* 302* 302 304 308* 327* 332* 332 334 339* time parameter fixed bin(71,0) dcl 388 ref 382 396 time_last_reset 364 based fixed bin(71,0) level 2 dcl 3-50 set ref 183* user_abs_attributes based structure level 1 dcl 2-25 user_attributes based structure level 1 dcl 1-21 xpit parameter char packed unaligned dcl 440 ref 438 442 NAMES DECLARED BY DECLARE STATEMENT AND NEVER REFERENCED. ABS_ATTRIBUTE_NAMES internal static varying char(28) initial array dcl 2-38 ALT_USER_ATTRIBUTE_NAMES internal static char(20) initial array packed unaligned dcl 1-77 PIT_version_3 internal static fixed bin(17,0) initial dcl 3-143 USER_ATTRIBUTES_always_allowed internal static bit(36) initial dcl 1-100 USER_ATTRIBUTES_default_in_pdt internal static bit(36) initial dcl 1-104 USER_ATTRIBUTES_settable_by_user internal static bit(36) initial dcl 1-108 USER_ATTRIBUTE_NAMES internal static char(20) initial array packed unaligned dcl 1-50 arg_info based structure level 1 dcl 3-136 pit_$ external static bit(36) dcl 3-47 pit_ptr automatic pointer dcl 3-48 NAMES DECLARED BY EXPLICIT CONTEXT. abstee 003113 constant label dcl 273 ref 219 238 argerr 004176 constant label dcl 374 ref 140 148 char 004417 constant label dcl 433 ref 427 cv_limit 004355 constant entry internal dcl 414 ref 163 166 171 194 195 201 211 262 268 cv_time 004247 constant entry internal dcl 382 ref 262 262 295 295 device 003642 constant label dcl 327 ref 306 309 endit 004153 constant label dcl 370 endit1 004164 constant label dcl 371 ref 179 iod 003401 constant label dcl 300 ref 279 282 next 003261 constant label dcl 288 ref 286 next2 003545 constant label dcl 316 ref 313 quick 001767 constant label dcl 192 resource_usage 000656 constant entry external dcl 53 ru 000646 constant entry external dcl 53 skip 003104 constant label dcl 271 ref 254 skip2 003104 constant label dcl 270 skip3 003377 constant label dcl 298 ref 294 skip4 003640 constant label dcl 325 ref 321 test_ru 004223 constant entry external dcl 438 THERE WERE NO NAMES DECLARED BY CONTEXT OR IMPLICATION. STORAGE REQUIREMENTS FOR THIS PROGRAM. Object Text Link Symbol Defs Static Start 0 0 4626 4702 4430 4636 Length 5216 4430 54 300 175 10 BLOCK NAME STACK SIZE TYPE WHY NONQUICK/WHO SHARES STACK FRAME ru 608 external procedure is an external procedure. cv_time internal procedure shares stack frame of external procedure ru. cv_limit internal procedure shares stack frame of external procedure ru. STORAGE FOR INTERNAL STATIC VARIABLES. LOC IDENTIFIER BLOCK NAME 000010 pit_name ru STORAGE FOR AUTOMATIC VARIABLES. STACK FRAME LOC IDENTIFIER BLOCK NAME ru 000100 crashes ru 000102 answer ru 000117 answer1 ru 000134 answer2 ru 000145 answer3 ru 000153 j ru 000154 logins ru 000156 datestr ru 000162 reset ru 000166 an ru 000167 al ru 000170 nargs ru 000171 absolute ru 000172 cutoff ru 000173 month ru 000174 ec ru 000175 i ru 000176 ii ru 000177 mode ru 000200 temp ru 000202 pp ru 000204 ap ru 000206 dev_usage_buffer ru 000256 dubp ru 000260 dubl ru 000261 dubi ru 000262 retlen ru 000263 devh ru 000266 dusw ru 000306 rs_name ru 000316 max_rs_number ru 000317 ndevices ru 000320 dvt ru 000560 increment ru 000622 j cv_time 000623 hours cv_time 000624 minutes cv_time 000625 seconds cv_time 000626 answer cv_time 000640 lim cv_limit 000643 jj cv_limit 000644 itemp cv_limit THE FOLLOWING EXTERNAL OPERATORS ARE USED BY THIS PROGRAM. alloc_char_temp call_ext_0Jnf;G3ZR}BMultics Storage System Volume pub_08 pub_08 public GQ~2rP/߇ mF bT 2T "T oMT9eTT, ----------------------------------------------------------- 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