5.51 · exercise
Predict: Array Memory Tracing
Act as the CPU. Work out the block sizes and the byte offsets that map C array declarations onto AArch64 memory operands.
0 of 4 correct
Mental Trace
// C: int ia[5];
.bss
.balign 4
ia: .skip NMental Trace
// C: char array[2][3]; // x20 holds the address of array[0][0] ldrb w21, [x20, OFFSET]
Mental Trace
// C: long myArray[5] = {10, 20, 30, 40, 50};
// x20 holds the address of myArray[0]
ldr x21, [x20, OFFSET]Mental Trace
// C: int ia[2][3][3];