Question: 1. (4) Shown below in Listing 1 is a very simple loop in Nios II assembly code. For the two branches, indicate what the branch

 1. (4) Shown below in Listing 1 is a very simple

1. (4) Shown below in Listing 1 is a very simple loop in Nios II assembly code. For the two branches, indicate what the branch predictor would yield (i.e., predict "taken" or predict "not taken") for the /e and the /s cores. Justify your answer.|| Listing 1: A Simple Nios Assembly Loop # Initialize various values/counters movui r16, 10 movia r15, dataArray mov r14, r0 # The Loop! SimpleLoop: 1dw r6, 0(115) bne ro, r6, NextIter addi r14, r14, 1 NextIter: addi r15, r15, 4 subi r16, 116, 1 bne r16, ro, SimpleLoop # The end 2. (6) If the relatively senseless code below is running on a Nios II /e core, approximately how long does it take (in cycles) to execute the code? Show your work. In any case where the instruction timing is vague (e.g., "Duration of Avalon-MM read transfer"), report the answer as precisely as possible, including multiples of vague delays. movia r7, a Value movia r8, another Value 1dw r9, 0(17) 1db r10, 0(18) add r10, r9, r10 slli r10, 110, 4 sth r10, 0(17) 1. (4) Shown below in Listing 1 is a very simple loop in Nios II assembly code. For the two branches, indicate what the branch predictor would yield (i.e., predict "taken" or predict "not taken") for the /e and the /s cores. Justify your answer.|| Listing 1: A Simple Nios Assembly Loop # Initialize various values/counters movui r16, 10 movia r15, dataArray mov r14, r0 # The Loop! SimpleLoop: 1dw r6, 0(115) bne ro, r6, NextIter addi r14, r14, 1 NextIter: addi r15, r15, 4 subi r16, 116, 1 bne r16, ro, SimpleLoop # The end 2. (6) If the relatively senseless code below is running on a Nios II /e core, approximately how long does it take (in cycles) to execute the code? Show your work. In any case where the instruction timing is vague (e.g., "Duration of Avalon-MM read transfer"), report the answer as precisely as possible, including multiples of vague delays. movia r7, a Value movia r8, another Value 1dw r9, 0(17) 1db r10, 0(18) add r10, r9, r10 slli r10, 110, 4 sth r10, 0(17)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!