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

Consider the two following assembly files: test.s test2.s globl test globl testV

ID: 3727066 • Letter: C

Question

Consider the two following assembly files: test.s test2.s globl test globl testVar section .text globl test2 globl test2Var section .text test: test2: ADRP X2, test2Var ADD X2, X2, :lo12:test2Var LDUR X3, [X2, 0] ADD X3, X3, 1 STUR X3, [X2, 0] ADRP XO, mysteryStr ADD XO, XO, :1o12 :mysteryStr BR X30 ADRP X2, testVar ADD X2, X2, :lo12:testVar LDUR X3, [X2, 0] SUB X3, X3, 1 STUR X3, [X2, 0] ADRP XO, testString ADD XO, X0, :lo12:teststring BR X30 section .data testVar: .quad 0xA .section .data test2Var: .quad 0xA testString: .asciiz "Fill String"

Explanation / Answer

Answer for c:

Line #:                                                                  Instruction Type                                               Dependency

ADRP X2,test2Var                                           ADRP                                                                     ADD

LDUR X2,X2:lol2test2Var                               LDUR                                                                     ADD

STUR X3, [ X2,0]                                                                STUR                                                                     ADD

BR X30                                                                  BR