Chapter 5 ½ Function and Performance 45

 Stack(top in Mp) Stack(top in Pc) 1-address or general-reg. 3-address Program push B push C add pop A push B push C add pop A load B add C store A Add B, C, A No. of instructions 4 4 3 1 Accesses ~ 4op' + 3a + 6d 4op' + 3a + 3d 3op + 3a + 3d 1op" + 3a + 3d Program size bits » 64 64 72 60 Bits accessed 16+48+192 = 256 16+48+96 =160 24+48+96 =168 12+48+96 =156 Time to execute (m s)d 0.5 + 1.5 + 6 = 8 0.5 + 1.5 + 3 = 5 0.75 + 1.5 + 3 = 5.25 0.37 + 1.5 + 3 = 4.87 Statement execution rate (actual performance) 1/8 = 0.125 M 1/5 = 0.2 M 1/5.25 = 0.19 M 1/4.87 = 0.21 M Operand rate 2/8 = 0.25 M 2/5 = 0.4 M 2/5.25 = 0.38 M 2/4.87 = 0.42 M Instruction rate 4/8 = 0.5 M 4/5 = 0.8 M 3/5.25 = 0.57 M 1/4.87 = 0.21 M Pc(accesses/s) 1 M 1M 1 M 1M

~ op = operand, a = address, d = data
» assumes address/a = 16 b; data/d = 32 b; op = 8 b; op' = 4 b; op' = 12 b
d Assumes a memory-limited processor which can access 32 b/m s

highest performance for the 3-address machine, whereas the conventional instructions per second measure shows the 3-address machine to have the lowest performance (by a factor of 4 in relation to the fastest machine). A more subtle measure- operation-rate-is correlated with the true benchmark statement execution rate. It should be noted that, except for the first machine, a stack machine with stack in Mp, the information rate (word accesses per second) is a better performance indicator than the conventional instruction rate measure. For more unconventional machines, instructions per second tends to become a significantly poorer measure. For various vector/array machines (e.g., ILLIAC LV, CDC STAR, CRAY-i) which have to operate on at least 64 operands per single instruction, instructions per second would be a poor measure. Hand-held calculators have single, complex instructions, such as sine and polar-to-cartesian coordinate conversion. In this case using anything but a final benchmark problem would be misleading, and accesses per second is best as a Pc performance measure.

The secondary Pc parameters include the number of data-types and the context-switching rate. The number of data-types (e.g., scientific, string, character, lists, vectors) in the Pc gives an indication of performance when it is operated with a particular language. In the case of multiprogramming systems (e.g., real time, transaction, and time sharing), the time to switch from job to job is critical. Thus the process context-switching rate is also an important attribute, since most large computer systems operate with some form of multiprogramming.

Mp, Ms. The memory sizes (in bytes) for both primary and secondary memory give memory capability. The memory transfer rates are needed as secondary measures, especially to compute memory interference when multiple processors are used. The Mp transfer rate also tracks the access rate available to the Pc for secondary memory transfers and external interface transfers. For file systems, which require multiple accesses to secondary memory for single items, the probabilistic measure of file access rate is needed for a more accurate performance estimate. Similarly, for multiprogrammed systems, which use secondary memory to hold programs, the probabilistic measure of program swapping rate is required.

T.human, T.communications, T.external. Communications capabilities with humans, other computers, and other electronically encoded processes are equally important structure and