Question: Q22. (a) Integer addition (twice - for incrementing the loop counter and in the first line of the loop's body), integer multiplication (first line of

Q22. (a) Integer addition (twice - for incrementing the loop counter and in the first line of the loop's body), integer multiplication (first line of the loop's body), integer comparison (twice for termination of the loop and in the second line of the loop's body). Whetstone deals with the floating point performance not used in this test. Dhrystone deals with integer performance that are relevant to this test. CoreMark tests a MCU on some real life integer workload, which is different from this test. (4 marks) (b) All these MCUs use the same CPU core clocked at the same frequency. This is the reason why their execution times are the same. (2 marks) CPU. (c) Both CPU execute one instruction per a clock cycle thus the difference in the clock frequencies translates into the 84/16 = 5.25 speedup for the ARM (It is necessary to note that ARM CPU has three stage pipeline thus its instructions per cycle count is slightly lower than 1 that can be neglected here.) long data type means that the code operates 4-byte data pieces that are native for the ARM CPU but can be operated via software subroutines only for the other Arduinos. (E.g., incrementing the loop count in 8-bit Arduinos would require, in addition to register increment, checking the carry flag and incrementing higher bytes in the variable with additional carry flag checks.) This Arduino Due's architectural advantage likely lead to the remaining 28ms / 2ms/5.25 = 2.67 speedup. (4 marks)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
