Question: 2. [14 points] The initial value in R4 is 0xFFFFFFFF, in R7 is 0x12345678, and the initial value of the condition code NZCV = 0000
![2. [14 points] The initial value in R4 is 0xFFFFFFFF, in](https://dsd5zvtm8ll6.cloudfront.net/si.experts.images/questions/2024/09/66f532ab1e0bf_32266f532aa9837a.jpg)
2. [14 points] The initial value in R4 is 0xFFFFFFFF, in R7 is 0x12345678, and the initial value of the condition code NZCV = 0000 STOP MOVS R4, #0x20 MOVS R7, #Ox0 CBNZ R7, DONE MOVW R4, #OXABCD DONE END : instruction 1 ; instruction 2 ; instruction 3 ; instruction 4 ; instruction 5 a) Convert the instruction 1 into machine code (in hexadecimal format). Please show which Thumb instruction format you use. [4 points] b) What will be the condition code NZVC after the instruction 2 is executed? What is the value in register 7 (word size) after the instruction 2 is executed? [4 points] c) After the instruction 3 is executed, what is the next instruction to be executed (instruction 4 or instruction 5)? Why? What will be the value in R4 (word size) after the instruction 5? [3 points] d) If the STOP instruction is at the memory location 0x01000000, fill the following memory block starting from 0x0100 0002 based on instructions 1-4. [3 points] Even address content Odd address content Ox0100 0008 Ox0100 0006 Ox0100 0004 Ox0100 0002 OxOF OxB1 2. [14 points] The initial value in R4 is 0xFFFFFFFF, in R7 is 0x12345678, and the initial value of the condition code NZCV = 0000 STOP MOVS R4, #0x20 MOVS R7, #Ox0 CBNZ R7, DONE MOVW R4, #OXABCD DONE END : instruction 1 ; instruction 2 ; instruction 3 ; instruction 4 ; instruction 5 a) Convert the instruction 1 into machine code (in hexadecimal format). Please show which Thumb instruction format you use. [4 points] b) What will be the condition code NZVC after the instruction 2 is executed? What is the value in register 7 (word size) after the instruction 2 is executed? [4 points] c) After the instruction 3 is executed, what is the next instruction to be executed (instruction 4 or instruction 5)? Why? What will be the value in R4 (word size) after the instruction 5? [3 points] d) If the STOP instruction is at the memory location 0x01000000, fill the following memory block starting from 0x0100 0002 based on instructions 1-4. [3 points] Even address content Odd address content Ox0100 0008 Ox0100 0006 Ox0100 0004 Ox0100 0002 OxOF OxB1
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
