■n I LIBRARY OF THE UNIVERSITY OF ILLINOIS AT URBANA-CHAMPAIGN 570.84 lifer Cop- 'L CENTRAL CIRCULATION AND BOOKSTACKS The person borrowing this material is re- sponsible for its renewal or return before the Latest Date stamped below. You may be charged a minimum fee of $75.00 for each non-returned or lost item. Theft, mutilation, or defacement of library materials can bo causes for student disciplinary action. All materials owned by the University of Illinois Library are the property of the State of Illinois and are protected by Article 16B of Illinois Criminal Law and Procedure. TO RENEW, CALL (217) 333-8400. University of Illinois Library at Urbana-Champaign "*''' 182000 When renewing by phone, write new due date below previous due date. L162 Digitized by the Internet Archive in 2013 http://archive.org/details/simulationanalys605mamr Ma) )Mo5~ /K4-Z4 I uiucDCs-R-73-605 j SIMULATION ANALYSIS OF A PAY -FOR -PRIORITY SCHEME FOR THE IBM 360/75 BY Sandra Ann Mararak August 1973 DEPARTMENT OF COMPUTER SCIENCE UNIVERSITY OF ILLINOIS AT URBANA-CHAMPAIGN URBANA, ILLINOIS UIUCDCS-R-73-605 SIMULATION ANALYSIS OF A PAY-FOR-FRIORITY SCHEME FOR THE IBM 360/75 BY SANDRA ANN MAMRAK August 1973 Department of Computer Science University of Illinois at Urbana-Champaign Urbana, Illinois 6l801 This work was supported in part by NSF GJ 28289 and was submitted in partial fulfillment of the requirements for the Master of Science degree in Computer Science at the University of Illinois at Urbana-Champaign. Ill ACKNOWLEDGMENT The constant support and expert guidance of Professor E. K. Bowdon, Sr . were essential elements in the preparation of this paper. I would like to sincerely thank him. I would like to acknowledge Mr. Fred Salz for his assistance in developing the benchmark jobstream and his assistance in modifying his basic GPSS simulator to suit the purposes of this project. Mr. Robert Skinner has also rendered invaluable aid during our many discussions relating to the design philosophy and the progress of the project. Mrs. Gayanne Carpenter's willing assistance and superb typing were the last, but surely not the least, contribution to the completion of this paper. This research was supported in part by the Computing Services Office at the University of Illinois at Urbana-Champaign and in part by the National Science Foundation under Grant No. NSF GJ 28289- IV PREFACE When a computing facility "becomes so heavily utilized that dissatisfaction about long turnaround times is prevalent in the user community, the introduction of a priority consideration into the scheduling algorithm will aid in lessening the problem. Users who desire shorter turnaround time may then opt for a high priority position on the job queue and users with less urgent jobs may opt for a middle or a low priority position on the job queue. High and low priority queue positions may be associated with higher and lower rates of job cost respectively. A responsible introduction of a priority scheduling algorithm into a given system must include a serious consideration of the goals of such an algorithm as they apply to that system, a thorough study of the various priority scheduling options available to the system, and the developing and analyzing of models embodying the most favorable of these options. The results of the development and evaluation of a priority scheduling algorithm for the University of Illinois computing center are presented in this paper. Project goals are set forth, algorithm options are considered and a thorough discussion of the formulation and analysis of various simulation models of proposed schemes is included. Recommenda- tions are made concerning the follow-up procedures required to make the project successful. V TABLE OF CONTENTS Page ACKNOWLEDGMENT iii PREFACE iv 1. INTRODUCTION: RESEARCH DESIGN 1 2. OBJECTIVES OF A PAY-FOR- PRIORITY SCHEME 3 3- OPTIONS IN A PAY-FOR -PRIORITY SCHEME 6 k. DEVELOPMENT OF SPECIFIC PAY -FOR -PRIORITY MODELS 11 k.l. Two Basic Schemes 11 h .2. . More Complex Schemes 13 5- EVALUATION OF THE SPECIFIC SCHEMES 20 5.1. Validation of the Simulator 20 5-2. Analysis of Pay-for-Priority Simulated Run Results 33 6. CONCLUSIONS U8 APPENDIX A: IBM 360/75 SCHEDULING ALGORITHM 5k APPENDIX B: JOB COSTS 56 LIST OF REFERENCES 57 1. INTRODUCTION: RESEARCH DESIGN At the University of Illinois at Urb ana -Champaign, the present scheduling algorithm used in the IBM 360/75 run under HASP 3-1 and O.S. [l] queues jobs for service according to their resource requests. A brief description of this scheduling algorithm can be found in Appendix A. Very important tasks must assume queue positions determined by their particular set of resource requests, irrespective of their urgency. A priority algorithm is desired, therefore, that allows jobs to vie for queue position depending on how short a turnaround time the user desires for his job. The basic principle behind such an algorithm is that users would be able to choose a priority for their jobs and would be charged for service accordingly. If a user is willing to pay more than the normal rate his job would be given a higher priority; if a user wishes to pay less than the normal rate, his job would be given a lower priority. This sort of scheduling algorithm is referred to as "pay-for-priority". As the first step in the development of a pay-for-priority scheme, specific objectives of such a scheme as it would be implemented by the Computing Services Offices for the University of Illinois user community were determined. These goals were intended to be a set of standards against which proposed pay-for-priority schemes could be tested and evaluated. In addition, a study was made of many possible options avail- able in the design of a pay-for-priority algorithm. Eight specific models incorporating various combinations of these options were selected to study. These eight models were built upon two basically dichotomous schemes--one in which discrete priority assignments were made and one in which continuous assignments were made. Relatively simple versions of each of the two schemes were cumulatively embellished with the addition of more finely tuned algorithm options. A GPSS simulation of the IBM 360/75 was used [2] to implement and evaluate the specific pay-f or -priority schemes. In order to use the GPSS simulator to predict real system performance within well-defined statistical limits of accuracy, the simulator had to be tuned with data characteristic of the environment to which the results were to be applied. It was necessary, therefore, to create a meaningful benchmark jobstream representing the workload of the period under study. Formulating a tuned simulator from the various system performance parameters produced by running the benchmark, and then validating the accuracy of the simulator were preliminary to any actual pay-f or -priority algorithm evaluations. As the final step in the pay-f or -priority scheme development and evaluation, simulation runs of eight specific models were performed and analyzed, yielding data upon which a report of comparative algorithm performance could be based. 2. OBJECTIVES OF A PAY-FOR-PRIORITY SCHEME The set of goals to be met by any specific pay-for-priority scheme will be as unique to an organization as are its service philosophy and its user community. A university computing facility in particular serves a wide range of users representing an equally wide range of system demands. The objectives of a pay-for-priority scheme as listed below are calculated to meet the diverse needs of users serviced by the Computing Services Office at the University of Illinois. These goals are standards by which any pay-for-priority scheme devised for the university community must be measured. OBJECTIVE 1: User Control To allow users to influence their scheduling priority, and thus the expected turnaround time, for each job submitted to the system. Involved in this objective is giving the user the ability to intelligently influence the turnaround time for his job by choosing an appropriate priority for it. Either a static or dynamically updated report can be issued informing the user of turnaround time for jobs in the various priority levels. The user can then be expected to determine priority parameters for his job that will place it, with its particular resource requests, in the desired priority level. OBJECTIVE 2: System Efficiency To maintain as high a level as possible of resource utilization and system throughput. k Involved in this objective is the degree to which system resource utilization and throughput will he permitted to degrade as a result of disregarding the normal scheduling algorithm in favor of choosing jobs strictly according to their paid for priority. The goal is to design a scheme that will dynamically maintain some acceptable level of resource use and throughput and will compensate in monetary returns for any required deviations from these acceptable levels. OBJECTIVE 3: Load Leveling To evenly distribute an essentially varying workload over the 2^-hour work day and over longer periods displaying fluctuations in use such as weekly, monthly, and semester periods. Involved in this objective is the need to provide incentives for users which would encourage them to use the system at times that presently are periods of low level usage. These low level usage times must be viewed in terms of hours of the day, i.e. midnight to 5 a.m., days of the week, weeks of the month, and months of the semester. Conversely, the reward system must be such as to discourage the running of less urgent jobs during periods of high level usage. OBJECTIVE h: Predictability To dynamically predict with reasonable accuracy the expected turnaround time for jobs with given priorities. Involved in this objective is the requirement that the priority scheme should dynamically provide the user with reliable information about the turnaround time that can be expected for a job if that job is submitted at a particular priority level. This information must be regularly updated and reflect the current turnaround times for the different priority levels. OBJECTIVE 5: Easy Use To be easily understood by users . Involved in this objective is the necessity of the adopted priority scheme to be readily understood by the average user and to be able to be used easily and intelligently, with little effort and adequate rewards . OBJECTIVE 6: Practicality To be practical to implement. Involved in this objective is the question of ease and speed of implementation of a proposed priority scheme . The scheme should be able to be introduced into the system by system programmers within a reasonable amount of time and be maintained and adjusted in a straight -forward manner after its implementation. OBJECTIVE 7: Fairness To guarantee all jobs, regardless of priority, the opportunity to actively compete for O.S. resources during some allotted time period. Involved in this objective is the right of users to be guaranteed some processing time on the computer, even if they choose a lower priority level than other users. No users are to be excluded from system use solely as a result of implementing the pay-for-priority scheme. Further, users may expect an acceptable turnaround time for a job submitted to the com- puting facility, independent of their ability to pay more than the normal service rate . 3 . OPTIONS IN A PAY-FOR-PRIORITY SCHEME Within the framework of the IBM 360/75 under HASP and O.S., there exist a myriad of options in formulating a pay-for-priority scheme. These options can be generally described in four basic sets of choices, each of which allows for several variations within itself. An underlying assumption in the options described below is that all jobs entering the system are subject to the pay-for-priority scheme, participating with default values when the specific pay-for-priority parameters are not assigned values by the user. OPTION 1: Continuous or Discrete Assignments A continuum of scheduling priority assignments and corresponding rates of pay-for-priority vs. a discrete class assignment of priority levels and corresponding rates of pay. Present job class assignments and their resulting quasi -priority- assignments are made based on some estimate of a job's size as reflected in the resources it requests. Involved in Option 1 is the choice of either implementing a continuum of priority assignments or of implementing a set of discrete levels of priority assignments within the framework of the present job class scheme. In the former case, an initial priority assignment based on a job's resource requests would be given to each job and the pay-for-priority assignment would be made using the job determined priority and a user determined reward factor r. For example, the pay-for-priority assignment might be given by the quotient of the initial priority and the reward factor . When processing is completed, the charges for each job can he computed by multiplying the normal system charge units times the factor r (or some function of r) . This scheme allows a job's priority assignment to be dependent on its size as -well as on the rate the user is willing to pay for its priority. The latter choice in this option is to maintain the basic class structure as it is presently used and to manipulate a job's priority either by assigning it to a special class P which would have dedicated initiators, or by assigning it to classes A-D and grading its priority within these classes--i.e . 1.1, 1.2, . . ., 13«9> 1^.0-- according to the rate the user is willing to pay. OPTION 2: Dedicated or Competitive Resource Use Assignment of various percentages of dedicated O.S. resources to jobs at different priority levels vs. job competition for O.S. resources as is presently implemented on the system. Once a job is in O.S., its processing time is affected not only by its own resource needs, but also by the other jobs that are simulataneously making demands on O.S. resources. The choice involved in Option 2 is one of either implementing a scheme whereby percentages of O.S. resources (CPU, I/O channels, core) would be dedicated to jobs of certain priority levels [3] or O.S. resources would be assigned as is presently done. In the former case a reference table can be established indicating what percentage of O.S. resources would be dedicated. For example, one such table might contain the following: Table 1. Percentages of Dedicated OS Resources Level of Priority % CPU % Core % I/O > 100% normal rate 50 60 50 = 100% normal rate 35 30 25 < 100% normal rate 15 10 25 The scheduler can reference a dynamically kept record of present system resource usage and choose its next job so as to maintain as closely as possible the levels of usage defined in the table. For the second choice in this option, even though jobs might gain or lose position on the HASP queue as a result of their particular priority assignment, once jobs are in O.S. they would vie for O.S. resources in exactly the same way as they do now. OPTION 3: Workload Dependent or Static Assignments Dynamically adjust pay-for-priority rates and percentages of dedicated O.S. resources with an increasing workload vs . keep static priority rate and dedication assignments. Accepting large jobs for processing during peak system loads may cause a degradation in resource utilization and system throughput. Involved in Option 3 is the choice to either increase the cost for faster service, along with adjusting percentages of dedicated O.S. resources or to keep static pay-for-priority and dedication percentages, regardless of the system load. 9 In the former case, a job's priority can be computed, using the job determined priority and user determined reward factor as described earlier. The cost of the job, however, instead of being just a function of resources used and the reward factor r, would also include a multi- plication factor which would measure the system workload. The workload factor can be adjusted such that jobs requesting no special priority considerations would pay the normal rate, jobs requesting a high priority would pay increasingly higher rates (depending on the workload) and jobs requesting a lew priority would pay increasingly lower rates. In addition to adjusting job costs for varying workloads, O.S. resource allocation can also be adjusted so that dedication of CPU, Core, and i/O facilities would vary with the workload. In this case, Table 1 might be transformed into the following: Table 2. Dynamic Assignment of Percentages of Dedicated OS Resources Level of Priority Low Level Workload % CPU/Core/IO Medium Level Workload % CPU/Core/IO High Level Workload % CPU/Core/IO > 100% normal rate 45/50/45 50/60/50 60/65/65 = 100% normal rate 30/30/30 35/30/25 40/35/35 < 100% normal rate 25/20/25 15/10/25 For the second choice in this option, pay-for-priority rates and/or dedication percentages would not change in a dynamic way, but would stay set until some external intervention altered them. 10 OPTION k: Ageing or Absolute Priority Increase a job's priority as a result of its waiting time in the system vs . maintain static priority assignments. A job gains or loses position in the HASP queue as a result of other jobs being run or other jobs of higher priority joining the queue. Involved in Option k is the choice to either let a job also gain position in the HASP queue as a result of the time it has spent on the queue, thus allowing initial priorities to be overridden, or to let it move forward only as a result of jobs ahead of it being run. 11 k. DEVELOPMENT OF SPECIFIC PAY-FOR-PRIORITY MODELS The four "basic options for implementing a pay-for -priority- scheme and the many variations possible within each option present the priority algorithm designer with a large number of schemes to he considered. A systematic approach organized around the basic dichotomy of the set of discrete algorithms and the set of continuous algorithms was adopted to simplify the study. Each of two basic models (discrete or continuous priority assignments) was run with no pay-for-priority scheme options added so that a standard set of system performance parameters could be collected. These relatively simple models were then each embellished with the cumulative addition of pay-for-priority options. System performance parameters were collected after the addition of each option thus making comparisons of the different schemes possible. The design of the pay- for-priority algorithm evaluation is summarized in Table 3 and described in detail below. k.l. Two Basic Schemes The two basic models used to evaluate the pay-for-priority algorithms were both GPSS simulations of the IBM 360/75* Th e model used to represent the discrete priority assignment scheme simulated the opera- tion of the IBM 360 under HASP and O.S. using the Magic Number and class assignment schemes as are used in the current system. The express initiator was inactivated and the remaining six initiators were set to 12 Table 3« Summary of Pay-f or-Priority Models Options Implemented Discrete Algorithms Continuous Algorithms Simple priority scheme A basic simulator of the A simulator of the with turnaround pre- IBM 360/75 under HASP IBM 360/75 was diction capabilities. and O.S. was developed developed to run and a turnaround time under a PRT priority prediction module was scheme which assigns added to it . continuous priorities to jobs. The pre- diction module was added ,! Addition of pay-for- The Magic Number scheme The PRT scheme is priority. - is used with options used with options for either a low, normal, of low, normal, or or high priority within high priorities . a given class . ; Addition of an ageing A module is added which A module is added which ! option. bumps a job's priority increases a job's when the job has been priority as a result waiting in the system of its being in the for a given period of system a long time . time . Addition of varying A module is added which The same workload •workload considera- calculates a job's cost varying cost scheme tions . using a workload factor. module is added to the High priorities cost PRT simulator . more under heavy loads . 13 A, AB, BA, BA, BAC and CBA. The model used to simulate the continuous priority assignment scheme used a "FRT" assignment [k] . This scheme assigns a unique priority to each job based on the job's resource requests The actual priority assignment, FRT, is defined by FRT = a-IOREQ + CPUSEC + p 'REGION where Oi and (3 are experimentally determined coefficients which measure the amount of time a job will spend in O.S. as a result of its I/O requests and core requests respectively. Jobs are queued in HASP in order of increasing FRT and all initiators are set to select as their next job the one with the lowest FRT. k .2 . More Complex Schemes To these two basic models was added a turnaround time prediction module . In the Magic Number scheme the predicted turnaround time for a job in a given class is determined by averaging the actual turnaround times of jobs run in that class. This predictor is recalculated at two minute intervals, with the "seed" for the present two minute average being taken as the average turnaround time during the last two minute interval . In the FRT scheme, as a job is terminated, its priority assign- ment and its turnaround time are saved in an array. The array is large enough to contain these points of information for the fifty most recent jobs completed. At two minute intervals a least squares curve-fitting Ik routine is used to calculate the coefficients of the first degree polynomial which best approximates the pairs of coordinates presently in the array. These coefficients are then used to approximate the expected turnaround time for all jobs arriving during the next two minute interval. Figure 1 illustrates the prediction module function, given nine pairs of hypothetical coordinates. MO r— * z 1 — 1 30 Q 2 Z? cc 20 l or rt ~, « n 1 -(In x - a) f(x,a,0) = — e -i L x£v2rt 2a tX) = t<0 Since the log-normal curves are so close to the exponential family, exponential curve -fits were also tried, but with poorer results than the log-normal fits . An inspection of distribution graphs of core requests by job step indicated that these functions consistently hovered around common default values such as 58K or ll6K, with few exceptions. The step core functions, therefore, were not smoothed with the curve-fitting package, but instead were fed into the simulator discretely, using the distribution values from the respective frequency tables. The distribution of cards punched per job was handled similarly since the distribution graph of this function was also highly irregular. The curve fitting was done using a package program authored by J. A. Middleton titled, "Least-Squares Estimation of Non-Linear Parameters- NLIN" [6] . User subroutines indicating the function to which the data 25 are to be fit are called "by the main program which then iteratively attempts to determine the required variable coefficients (a and p in the log-normal case). The algorithm used selects an optimized correction vector for the coefficients by interpolating between the vector obtained by the gradient method and that obtained by a Taylor's series expansion truncated after the first derivative. Iteration is applied to this vector according to the least- squares method of estimating parameters until one of the several stopping criteria is met. Table 5 contains a list of parameters to which the curve-fitting was applied. Included in the table are the estimated sum of squares (ESS) and standard errors from the curve fitting results (SE = VESS/118) and the coefficients for the respective log-normal equations. Table 5. Curve Fitting Data LOC-NORMAL CURVE FITS ESS SE a 6 CLASS A 10 1.06 .09 5.88 3.82 CLASS B 10 1.74 .12 3.04 2.64 CLASS C 10 .82 .08 9.62 3.19 CLASS A CPU .25 .05 6.50 -9.60 CLASS B CPU 1.45 .11 2.47 1.32 CLASS C CPU 1.46 .11 8.88 1.50 LINES PRINTED .55 .07 8.73 6.93 ESS: SE: a,B: * Estimated Sum of Squares Standard Error log-normal curve coefficients log-normal curve fits were done on data transformed to the 0-1 interval 26 Simulated System Parameters Having gathered the required frequency distributions and having determined the necessary percentage figures referred to earlier, these data were fed into the simulator and the simulator was run for a two hour period with the same job arrival rate as the benchmark run. Job statistics were collected over the benchmark run and a correlation was performed between the real and simulated data. Correlation of Real and Simulated Runs The parameters to be correlated fell into two separate categories. The first of these categories was the set of parameters from the real system that had actually been fed into the simulator in terms of frequency distributions. The parameters included in this category were i/O and CPU distributions for class A, B, and C jobs, and distributions of lines per job. The second category of parameters to be correlated were those which were not fed directly into the simulator, but were produced by the simulator (and the real system) as a result of the characteristics of the input job stream and the way in which the decisions about actually running that jobstream were made. The correlations in this second category particularly serve to validate the simulator, since their closeness verifies that indeed the simulator handles the jobstream in the same way the actual system does. The parameters in this category are frequency distributions of i/O, CPU and real time (time is O.S.) for the total jobstream, frequency 27 distributions for real time "by class, a frequency distribution for units charged by job, and a frequency distribution of turnaround time for the total jobstream. Correlation Coefficients for Frequency Distributions In the correlation analysis [7], the various system parameters (number of i/o requests, number of kilobytes of core, etc.) were considered to be the independent variables in each case and the number of jobs using the respective resources were considered to be the dependent variables. The estimated coefficient of correlation, r, was used to test hypotheses about the population coefficient of correlation p. The coefficients may vary from -1 through to +1. Perfect positive correlation (an increase in the components of one dependent variable vector determines exactly an increase in the components of the other dependent variable vector) yields a coefficient of +1. A perfect negative correlation (a decrease in the components of one vector determines a decrease in the components of the other) yields a coefficient of -1. Tests of hypotheses about p, as well as about confidence inter- vals, can be made from moderately large samples if a function of r is used rather than the sample correlation coefficient itself. The function used is the Fisher r to Z transformation defined by Z = 1/2 in (£±|) . The sampling distribution of Z values is approximately normal, with an expectation given approximately by ■1 + E(Z) = | = l/2 In (i-±-£) 1 - o 28 For moderately large samples, the hypothesis that p is equal to any value p can be tested in terms of the test statistic: V i/(n - 3) where N is the sample size and the test is. referred to a normal distribution. It is approximately true that for random samples of size N, an interval such as Z - -(a/a) W* - 3) < I < Z + z (a/£) n/(N - 3) i •will cover the true value of | with probability 1 - a. Here Z is the sample value corresponding to r, | is the Z value corresponding to p, Z/ /p\ is the value cutting the upper Qt/2 proportion in a normal distri- bution, and en is the conditional probability of rejecting the correct hypothesis in favor of an alternate hypothesis. Since the coefficient of correlation is a measure of a linear relationship between sets of variables and since the Fisher r to Z trans- formation is designed for bivariate normal distributions, a transformation on the original data from both the real and simulated systems was necessary to make the parameter distributions approximately normal. The trans- formation applied was of the form y' = In y where y is the log-normal function of x as defined earlier. The OL and p used in the y expression were those found using the curve fitting package. 29 An illustrative example of how this correlation technique would he applied to the class A i/O data distributions from the real and simulated systems will aid in clarifying the procedure. A SOUPAC (Statistically Oriented Users Programming and Consulting) program package called "Correlation" is used to determine the estimated coefficient of correlation r [8] . Suppose that for class A i/O, r - .93* This high value of r evidences a very strong linear correlation between the two variables in question. Now, it is desired to test the hypothesis "does the number of class A jobs requesting 1-7* 8-lU, . . . , 83^-8^0 i/O requests in the real system and the linear relation account for more than 90 percent of the variance in the observed number of class A jobs making identical i/O requests in the simulated system?" That is, we actually want to thest the hypothesis p p > .900 or p > .9U8 against the alternative p 2 < .100 or p < .316 Here the Fisher r to Z transformation is used to find the test statistic z - E(z) = 1.658 - 1.811 _ 65 A/(N - 3) JTJTri 30 In a normal sampling distribution, a standard score of I.96 in absolute value is required for rejecting the hypothesis at the .05 level. Thus, we may safely conclude from this sample that more than 90 percent of the variance in the simulated system data is accounted for by its apparent linear relation to the real system data. For cc = .05 and Z/ / ? v = 1-96, the 95 percent confidence interval for | is given approximately by 1.658 - 1.96(.0922) < | < 1.658 + l-96(.0922) 1.U78 < i < 1.838. The corresponding interval for p is then approximately • 90 < p< .95. We can assert that the probability is about -95 that sample intervals such as this cover the true value of p. Table 6 contains the list of the dependent variables which were correlated, along with the r, p and interval of confidence values for each. 31 Table 6. Correlations of Simulation Parameters GROUP I. PARAMETER VALUES FED INTO SIMULATOR Interval of Confidence r P (at .05 level) Class A I/O .22 .38 .04 - p - .40 Class B I/O .42 .55 .26 - p - .56 Class C I/O -.02 - - Class A CPU .52 .64 .38 - p - .64 Class B CPU .67 .76 .55 - p - .76 Class C CPU -.02 - - Lines Printed .72 .77 .62 - p - .79 GROUP II. PARAMETERS PRODUCED INDEPENDENTLY BY THE SIMULATOR Job I/O .64 .73 .52 - p - .73 Job CPU .69 .77 .58 - p - .77 Job Real Time .41 .52 .25 < p < .55 Job Turnaround Time .87 .90 .82 - p - .90 Job Cost .67 .76 .55 - p - .76 Class A Real Time .48 .58 .33 - p - .61 Class B Real Time .37 .48 .20 - p - .51 Class C Real Time 0.0 - - Except for the class C coefficients, the parameters in Group I of Table 6 correlated quite satisfactorily. The class C jobs represented only k percent (16 jobs out of 399) of the total simulated jobstream and hence could not be expected to yield significant results. The class A i/o correlation was relatively low due to the "raggedness" of the frequency distribution of the real system class A i/o data at the lower end. 32 This unevenness could have been directly simulated, and hence the correlation made higher, by using the real frequency distribution data rather than the smoothed distribution. This tactic, however, which would yield more satisfactory results in this case, would contradict the effect of the original distribution smoothing technique which was felt to represent the whole population more accurately. The Group II correlations in Table 6 were equally satisfactory. The real time and turnaround time coefficients in this group are values gathered from a second run of the simulator. The set of real time correlations from the first four-hour run were unacceptably low. The simulated system real times were generally much higher than the real system parameters and so the simulator was tuned by decreasing the number of milliseconds per i/O request and milliseconds of overhead time per job. It should be noted that even though the turnaround correlation coefficient is high (.87), the means of the real and simulated distributions differ by about five minutes. This phenomenon occurs because the simulator does not simulate jobs that are queued for long periods of time waiting for special requests such as reversed-form printouts or India ink pen plots. Despite the fact that these jobs represent a small percentage of the total jobstream, their turnaround times can easily become one or two hours and thus influence the mean turnaround out of proportion to their number. Correlation of Percentage Distributions Those parameters which were evaluated in terms of percentage as opposed to frequency distribution included jobs having 1, 2, or 3 steps, i/O and CPU used by each step and jobs in classes A-C . Table 7 shows 33 the comparison of the percentage rates for these parameters for the simulated and real systems. This unusually high degree of agreement further emphasizes the close correspondence between the real and simulated systems . Table 7. Percentage Distributions of Simulation Parameters Percentage of: Real System Simulated System Jobs with 1 step " 2 steps II II o II 43 54 3 40 51 9 Total Job CPU used by step 1 II II II II II II o II II II II II II o 38 60 2 39 60 1 Total Job I/O used by Step 1 II II II II It II o II II II II II II T 41 58 1 41 58 1 Jobs in Class A B ii ii it p 39 56 5 36 60 4 5-2. Analysis of Pay- for -Priority Simulated Run Results Because of the satisfactory outcome of the simulator validating process, a reliable tool was available with which to test certain aspects of the specific pay-for-priority schemes. The eight models described earlier and summarized in Table 3 were each run for a four hour period 3^ of simulated time. The simulation run results displayed in Table 9 an d 10, and reasoned analysis in cases where simulation was not helpful, combined to form the comparative evaluation of the various schemes as presented in Table 8. In this table an attempt was made to classify a scheme's performance in meeting each objective as excellent, good, fair or poor . Comments on the Significance of the Results The GPSS simulation was used as a tool to collect various sets of data describing the performance of pay -for -priority models. The signif- icance and limits of applicability of the results of the simulation runs should be understood before undertaking the task of studying the simulation results. Frequency distributions of turnaround times were the major output of the runs. These distributions were collected over the nine categories of high, middle and low priority class A, B and C jobs. The data in Tables 9 an( i 10 represent the average of these distributions and as such are subject to the statistical phenomenon of one or two "stray" values distorting the average in a small sample size. Despite the fact that the overall sample size was greater than 700 jobs in every run, specific priority jobs within a class were likely to represent only a small percentage of the total jobstream. For example, there were only 5 high priority class C jobs that completed in the PRT runs. The average turnaround times listed in Table 10 for high priority class C jobs, therefore, are not significant. The seeming inconsistency in the fact that high priority 35 -d cd j-, o o H -P C5 H w Cs d h W id o in «5 O [k. tS M w a 5 H -P o h | 0) O H -H O C5 cS fe w W fc s ro (5 o •H Ph o Fn fe w W Fn >> o c > ■H M P H O c •H >> w O •H •H H P 0) U JH H •H •H > P C 0) ^> H •H C w > cd QJ cd w -P O S P w O w o U a o & •H cu = O *H ,£> 0) W 0) w a •H O CO O h5 £ £ H OJ on Jt LT\ VD C- ^ ^ •H o ctf o Fc Pk Ft, P-i p c 60 15 Magic Number PRT X Y Z Z 10 5 64 82 20 10 k3 k6 30 15 ko 20 100 33 60 30 20 >6o 30 15 It should be noted that even though these particular prediction schemes were unsuccessful, it is not to be implied that all schemes will be unsuccessful. One of the limiting factors in making predictions is the lack of recent information on jobs that run less frequently than others. For example, high priority class A jobs completed at a rate of one every three minutes. Thus it is feasible that turnaround time predictions for high priority class A jobs could be about 5 minutes old, and the system ^7 history reflected in this figure could be no longer accurate. An alternative approach to prediction is to prepare tables of average and worst-case turnaround figures for each of the classes under varying workloads. These tables could be referenced by the user and would offer a more stable reference point. More experimentation is required in this area if adequate predictability of a pay-for-priority scheme is to be realized. 1+8 6 . CONCLUSIONS Recommendations A consideration of the work involved in the implementation of any variations of the Magic Number or PRT schemes is essential "before a decision can he made on which of the schemes to adopt. All of the Magic Number schemes are inherently easier to implement because the basic Magic Number mechanisms of class assignments and priority within a class assignment are already present in the current system. The addition of the three levels of priority- -high, middle and low — would simply involve another parameter on the ID card and the logic to assign a job a priority 5, 6, or 7 ; depending on whether the job had requested low, middle or high priority within its class. The means for charging some percentage of actual job cost are present in the system charging mechanism and would have to be activated. The ageing mechanism is also already present in HASP and only constant parameters (exactly how long to let jobs age within a given priority level) would have to be managed. Addition of the workload factor would require storing average turnaround times of various classes and subsequently using these figures as the basis for deciding system activity and the price of priority. The logic to do this would have to be- added to the present system. h9 The basic system change required to implement the PRT scheme •would be the addition of a new queue add and queue delete module to HASP. Because the PRT assignments are continuous, it is necessary to queue jobs in the order of increasing PRT. Logic -would also have to be added which would calculate the job's PRT given its core, i/o and CPU requests. Priority levels and ageing modifications are accomplished by changing a job's PRT and thus changing its position on the queue. Given the queue add and queue delete module, these changes would be straightforward pieces of logic. The addition of the workload factor would require considerably more work than the other modifications since the workload factor is determined from the slope of the predictor curve and the predictor curve itself was found to perform unacceptably. If it were decided to implement the PRT with workload factor, experimentation with a more accurate predictor should be carried on simultaneously with the initial work for the PRT implementation so that the improved predictor could be ready for use when it was required. The impressive improvement in turnaround time and throughput for the PRT scheme is a factor far outweighing the more complex coding required to implement this scheme. Yet, undertaking the complex coding may impose an undue delay on the introduction of a pay-f or -priority scheme. The plan for implementation, therefore, should consist of several phases. The first of these phases is an introduction of the three levels of priority 50 into the present Magic Number scheme, ignoring ageing and the workload factor. Following this, the Magic Number formula should be changed to the PRT formula, but class and initiator settings should remain essentially the same. Subsequent phases should include the changeover to a continuous PRT scheme, the addition of the ageing module and the addition of the workload factor module. Beside providing for quick implementation with a potential for progressively more complex improvements, this plan also nicely provides for the monitoring of system and user response after each individual system change is made. The ultimate decision for the implementation of a specific pay-for-priority algorithm rests with administrative personnel. The type of information needed to make this decision includes answers to such questions as how will this scheme effect system efficiency, revenue collected, and the user community. Some of the answers to these questions can only be determined after implementation of a scheme. Many important questions, however, can be answered prior to implementation by using system models to measure system performance . The results of the study of pay-for-priority schemes as presented in this paper verify the usefulness of simulation as an adjustable model which is able to easily incorporate features of various scheduling algorithms . Further, the performance measurements obtainable from simulation, combined with reasoned analysis by experienced systems analysts can provide accurate and adequate information for input into the decision making process which precedes system changes. Thus, a responsible intro- duction of pay-for-priority scheduling is possible. 51 The Road Ahead The development, evaluation and recommendation of a pay-for- priority scheme to be implemented on the IBM 360/75 is only the first step in a series of events which will lead to the successful adaptation of such a scheme . After actual implementation is accomplished, ongoing evaluation and maintenance of the scheme are natural and essential subsequent tasks, particularly in the scheme's first few months of use. Implementation of a pay-for-priority scheme requires two important tasks. The first of these is the laborious job of coding the scheme that has been selected into the HASP and O.S. software configuration A second and equally important part of implementation involves user orientation. The computing community should thoroughly understand the scheme and feel confident that they can manipulate it to their own advantage . Dynamic evaluation and maintenance of the scheme should play a major role in the first few months of use of the pay-for-priority scheme. The values of various parameters in all the recommended schemes were chosen on the basis of being "reasonable predictions" of user and system behavior. These parameters include charges for various priority levels, percentage of users requesting high or low priorities in each class, ageing times and the workload factor h. User response must be closely monitored, therefore, and answers must be sought for such questions as: 52 --what percentage of users choose high or low priorities and is this an acceptable level of use? --is the amount being charged for high and low priorities serving as an incentive for their respective use? --what are acceptable waiting times to be incorporated into the ageing section of the algorithm? --is the predictor calculating turnaround times that correlate closely with the actual turnaround values? --is the workload factor h an acceptable one? --is the revenue being collected sufficient to justify the scheme? — what user suggestions could make the scheme more acceptable to the whole user community? The answer to these questions should be used to more finely tune the scheme that is adopted, using whatever means are necessary to successfully do the tuning. These "means" may range from a straightforward change of a particular constant parameter to reruns of the pay-for -priority simulator to test more feasible alternatives. The GPSS simulator has played an important role in the recommendation of a pay-for -priority scheme. The full circle of validation for the simulator must be completed as an extension of the pay-for-priority project. The circle began with the development of a benchmark jobstream from which to gather data to feed into the simulator. The simulator was tuned to fit the real system data and then it was used to make predictions about a typical jobstream. As a final step, after the pay-for-priority scheme has been implemented, the benchmark should be run under the scheme and the jobstream performance should be rigorously compared to the simulator predictions for it. This analysis will be the ultimate test for the validity of the simulator. 53 The results of the simulated runs of the various pay-for- priority schemes have raised questions and problems for further study that were not anticipated. These results suggest that more thought and effort will "be required to develop predictors that perform satisfactorily within acceptable limits. If it is decided to adopt the PRT scheme, more extensive simulated runs of that scheme should be performed to guarantee that its striking advantages are maintained over longer periods of time. Further experimentation should be done with varying the parameters that indicate what percentage of the user community will actually request high or low priority runs. At what point will a particular job mix begin to cause system efficiency degradation? Other areas of observation present themselves, such as monitoring the variations in queue sizes as the simulation progresses. If the Magic Number scheme is to be used, its components and relevance should be critically examined. A glaring omission is its ignorance of maximum core requests, a factor appropriate to consider for scheduling and included in the PRT calculations. Finally, another natural and desirable extension of the pay-for- priority project is the further development of a benchmark jobstream. Four hours of sampling was done to formulate a jobstream for use in developing the pay-f or-priority scheme . Another four-hour sample should be taken and the two jobstreams should be compared, combined and used for a finer characterization of jobs as they are serviced by the Computing Services Office. 3000 for class D. A special class of very small fast jobs is called "express" or class X jobs. Any one of seven initiators can be set to recognize up to five different classes of jobs, in a specific order. It is in this order that a free initiator will take a job off the spool and feed it to O.S. For example, if an initiator is set CBA, it will first search the spool for a class C job; if not found, it will look for a class B. If there is no B job, and no A job either, the initiator will be put in a wait state. Once the job is selected, it is put on the O.S. queue to be serviced by the operating system. After a job is placed on the O.S. queue, there is no longer any class distinction. Another set of initiators selects jobs on a first-come, first-served basis and removes them from the O.S. queue. 55 It is the function of these initiators to take the job through the various stages of execution. Jobs are selectively given control of the CPU by the O.S. Scheduler. The job with the highest dispatching priority (the job that has the lowest ratio of CPU time to I/O requests will get the highest dispatching priority) is given control until an interrupt occurs - either user initiated or system initiated. 56 APPENDIX B: JOB COSTS Central Processor Charges 360/75 (calculated for each job step): units charged = 0.0*+(X+Y) (0.00*+5Z+0.5) X = CPU time in centiseconds (0.01 sec.) Y = number of Input and Output requests Z = core size used in Kilobytes The CPU charge for the entire job is $.Ol/unit charged. Overhead Charge HASP EXPRESS $ 1.00 per job submitted 1.00 per job submitted On-Line Peripheral Charges Disk drive (permanent Disk/Tape drive (setup) Card Reader Card Punch Line Printer CalComp Plotter 27J+I/TTY terminal $0.0065 per track per day 1.00 per volume mounted 1.U0 per thousand cards read 3.90 per thousand cards punched .80 per thousand lines printed 20.00 per hour plotter time 1.00 per hour connect time 57 LIST OF REFERENCES [l] Simpson, T. H., "Houston Automatic Spooling Priority System - II (version 2)," International Business Machines Corporation, 1969* [2] Salz, F-, "A GPSS Simulation of the 360/75 Under HASP and O.S. 360, " Department of Computer Science Report No. UIUCDCS-R-72-528, University of Illinois at Urbana-Champaign, June 1972. [3] , Introduction to 0S/VS2 Release 2, GC28-0661-0, International Business Machines Corporation, 1973- Ik] Mamrak, S., "Proposed Priority Schemes for the IBM 360/75, " Noncirculated internal document, Department of Computer Science, University of Illinois at Urbana-Champaign, February 1973- [5] Salz, F., "Simulation Analysis of a Network Computer," Master of Science Thesis, Department of Computer Science, University of Illinois at Urbana-Champaign, June 1973' [6] Middleton, J. A., "Least Squares Estimation of Non-Linear Parameters -NLIN, " 360D-13'2 .003, International Business Machines Corporation, 1968. [7] Hays, W. L., Statistics , Holt, Rinehart and Winston, Inc., New York, 1963, PP. 529 : 33o^ [8] , "Correlation," SOUPAC Program Descriptions , Report No. 370-3, University of Illinois at Urbana-Champaign, March 1, 1971- BIBLIOGRAPHIC DATA 5HEET 1. Report No. UIUCDCS-R-73-605 3. Recipient's Accession No. Title and Subtitle Simulation Analysis of a Pay-For-Priority Scheme for the IBM 360/75 5. Report Date August 1973 6, Author(s) Sandra Ann Mamrak 8- Performing Organization Rept. No - UIUCDCS-R-73-605 Performing Organization Name and Address University of Illinois at Urbana-Champaign Department of Computer Science Urbana, Illinois 6l801 10. Project/Task/Work Unit No. 11. Contract/Grant No. NSF GJ 28289 2. Sponsoring Organization Name and Address National Science Foundation 1800 G Street, N.W. Washington, D.C. 20550 13. Type of Report & Period Covered Master of Science Thesis 14. 5. Supplementary Notes 6, Abstracts when a computing facility becomes so heavily utilized that dissatisfaction about long turnaround times is prevalent in the user community, the introduction of a priority consideration into the scheduling algorithm will aid in lessening the problem. Users who desire shorter turnaround time may then opt for a high priority position on the job queue and users with less urgent jobs may opt for a middle or a low priority position on the job queue. High and low priority queue positions may be associated idth higher and lower rates of job cost respectively. The results of the development and evaluation of a priority scheduling algorithm for the University of Illinois computing center are presented in this paper. Project goals are set forth, algorithm options are considered and a thorough discussion of the formulation and analysis of various simulation models of proposed schemes is included. Recommendations are made concerning the follow-up procedures required to make the project successful. '. Key Words and Document Analysis. 17a. Descriptors Priority Scheduling; Simulation; Validation I b. Idcntif icrs/Open-linded Terms e. ( OSATI Field/Group • Availability Statement Release Unlimited 19. Security Class (This Report) UNCLASSIFIED 20. Security Class (This Page UNCLASSIFIED 21. No. of Pages 60 22. Price RM N TIS-3B ( 10-70) USCOMM-DC 40329-P7 1 • a* ^ UNIVERSITY OF ILLINOIS-URBAN A 3 0112 047417826