Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

A pitfall cited in section 1.10 of the text book is expecting improve the overal

ID: 3885728 • Letter: A

Question

A pitfall cited in section 1.10 of the text book is expecting improve the overall performance of a computer by improving only one aspect of the computer. Consider a computer running a program that requires 200s, with 50s spent executing FP instructions, 65s executed Load/Store instructions, and 40s spent executing branch instructions, and the rest time for INT instructions. a) By how much (percentage) is the total time reduced if the time for FP operations is reduced by 20%? b) By how much (percentage) should the time for INT operations be reduced in order to reduce the total time by 10%? c) Can the total time be reduced by 25% by reducing only the time for branch instructions? Why?

Explanation / Answer


a) The total time reduced by 20% reduction of FP operation cab be obtained using the basic mathematical logic. [i.e., by substracting 20% of total time taken by FP Instructions from Total Time taken by the program]

Total_Timenew   = 200s - (20% of 50s) = (200 - 50*0.20) = 190s

Percentagereduced = [(Total_Timeold - Total_Timenew) / Total_Timeold] * 100%

   = [(200 - 190)/200] * 100% = 5%

----------------------------------------------------------------------------------------

b) To reduce the total time of program by 10%, how much % of time should be reduce for INT operations. This is similar to above problems, but we should compute in reverse order. Total Time for INT operation currently is 200-50-65-40 = 45sec

Percentagereduced= [(Total_Timeold - Total_Timenew) / Total_Timeold] * 100%
         ==> 10% = (200 - Total_Timenew ) / 200
         ==> 0.10 = (200 - Total_Timenew ) / 200
         ==> Total_Timenew = (200 -20) = 180s

Total_Timenew    = Total_Timeold - (x% of Time_TakenINT_op)
   ==>    180s   = 200s - (x% of 45s)
   ==> (x/100) * 45s = 200s - 180s
==>    x = (20/45) * 100%
==>    x = 44.444 %

----------------------------------------------------------------------------------------

c) In order to reduce total time by 25%, the amount that must be substracted from it will be
25% of 200s = 0.25*200 = 50sec. But as we can see, branch instructions are having atmost 40s allotted to them, so we cannot reduce 25% of total time even after completely eliminating all the branch instructions.

The maximum amount of time that can be reduced is (40/200) * 100% = 20%, if we completely eliminate the branch instructions.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote