Question: Consider the following program and its flowchart. The execution times of the blocks are as follows: B1 = 6 cycles B2 = 2 cycles if
Consider the following program and its flowchart. The execution times of the blocks are as follows:
B1 = 6 cycles
B2 = 2 cycles if branch taken, 5 cycles if not taken.
B3 = 3 cycles if branch taken, 6 cycles if not taken.
B4 = 7 cycles.
B5 = 1 cycle.

for (i-0, z-0; i2) z + x[i]*c[i]; = z B2: loop test B3: test x[i] B4: update z B5: loop update a) What is the maximum number of times that each block is executed? b) What is the minimum number of times that each block is executed? c) What is the maximum execution time of the program in clock cycles? d) What is the minimum execution time of the program in clock cycles
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
