Question: You are given this program and its flowchart: The execution time of the blocks is: B1 = 6 cycles, B2 = 2 if branch taken,
You are given this program and its flowchart:
![for (1-0, z-0; i 2) z=z+x[i]*c[i]; B1: initialize loop } B2: loop](https://dsd5zvtm8ll6.cloudfront.net/images/question_images/1712/0/7/5/286660c3216005141712075285298.jpg)
The execution time of the blocks is: B1 = 6 cycles, B2 = 2 if branch taken, 5 if not taken, B3 = 3 if branch taken, 6 if not taken, B4 = 7, B5 = 1
a. What is the maximum number of times that each block in your flowchart executed?
b. What is the minimum number of times that each block in your flowchart 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?
for (1-0, z-0; i 2) z=z+x[i]*c[i]; B1: initialize loop } B2: loop test B3: test x[i] B4: update z B5: loop update
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
