Question: 1) For the following C statement, what is the corresponding MIPS assembly code? Assume that the variables are 32-bit integers declared in C program,


1) For the following C statement, what is the corresponding MIPS assembly code? Assume that the variables are 32-bit integers declared in C program, and that the variables f, g, h and i are stored in registers $50, $s1, $s2 and $53, respectively. Use a minimal number of MIPS assembly instructions. (10pts) f = g(h 5); - 2) For the following C statement, what is the corresponding MIPS assembly code? Assume that the variables are 4-byte words declared in C program, and that the variables f and g are stored in registers $50 and $s1, respectively. Also assume that the base address of the array A is in register $s6. Account for alignment restriction. (10pts) f = g + A[7] ;
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
