13) (4 pts) Squaring a number is useful in many other algorithms. This assembly routine calculates...
Find out what the following assembly code calculates AREA my code, CODE EXPORT main ALIGN ENTRY main PROC MOVS MOVS MOVS r0,#0 r1,#15 r2,#0 loop CMP BGT MLA ADDS r2,r1 stop re,r2,r2,ro r2,r2,#1 loop % The final result is saved in register r0 stop B stop ENDP END
Modify the ARMSIM program to do the following: 1) output the square sum of the data 2) output the sum of all negatives and positives separately .text @ Direvtive .global _start @ declare global begining _start: LDR R1,=idx @ content of idx is length of Vec and now R1 is a counter. LDR R1,[R1] @ R1 is now the length of Vec. read inderectly LDR R2,=Vec @ R2 is the address of first element of vector MOV...