Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

We have this ARMv7 program running on a Rasperry Pi, which is a little endian co

ID: 2084842 • Letter: W

Question

We have this ARMv7 program running on a Rasperry Pi, which is a little endian computer (this is relevant): global _start _start: mov r0, #0 mov r3, #0 ldr r1, =numbers label_A: cmp r3, #5 beq _exit ldrb r2, [r1], #2 @ pay attention here label_B add r0, r0, r2 label_C: add r3, r3, #1 bal label_A _exit: mov r7, #1 swi 0 data numbers: word 0x01020304, 0x05060708, 0x090a0b0c, 0x0d0e0f10, 0x11121314 If the address of the label numbers is 0xBF08, what is the value in r1 each time label _B is reached? Give each value in hexadecimal. What is the value in r0 each time label _C is reached? Give this value in base-10.

Explanation / Answer

a)address label numbers is 0xBF08 in value in r1 each time is 0x05060708

b)value in r0 each time is 0x11121314 and its hexa decimal value is 0xA962A2.

the value #0 IS moved in the r0 register each time

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote