Answers 2023/2024
Stack correct answers a range of consecutive memory locations set aside for temporarily storing and
retrieving data bytes
SP correct answers R13
Stack point grows from ____ addresses to ____ addresses correct answers high, low
Stack is ____ in _____ out correct answers last, first
_____ and _____ are instructions used to load and retrieve data from the stack correct answers PUSH,
POP
PUSH {R1} correct answers SUB R13, #4
STR R1, [R13]
POP {R1} correct answers LDR R1, [R13]
ADD R13, #4
subroutine return instruction correct answers BX LR
subroutine call instruction correct answers BL subroutine
CMP R0, #7
BLS next correct answers R0 > 7
CMP R0, #7
BLO next correct answers R0 >= 7
CMP R0, #7
BHS next correct answers R0 < 7
CMP R0, #7
BHI next correct answers R0 <= 7
BLS, BLO, BHS, BHI are _______ conditional structures correct answers unsigned
BLT, BGE, BGT, BLE are _______ conditional structures correct answers signed
CMP R0, #7
BNE next correct answers R0 == 7
CMP R0, #7
BEQ next correct answers R0 != 7
, CMP R0, #7
BLE next correct answers R0 > 7
CMP R0, #7
BLT next correct answers R0 >= 7
CMP R0, #7
BGE next correct answers R0 < 7
CMP R0, #7
BGT next correct answers R0 <= 7
== correct answers BNE
!= correct answers BEQ
> (unsigned) correct answers BLS
>= (unsigned) correct answers BLO
< (unsigned) correct answers BHS
<= (unsigned) correct answers BHI
> (signed) correct answers BLE
>= (signed) correct answers BLT
< (signed) correct answers BGE
<= (signed) correct answers BGT
conditional structure (comparing G with 7) correct answers LDR R2, =G;
LDR R0, [R2]
CMP R0, #7
BXX next
BL subroutine
next
if (G1 > G2)
isGreater();
else
isLess(); correct answers LDR R2, =G1
LDR R0, [R2]
LDR R2, =G2
LDR R1, [R2]
CMP R0, R1