Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Question 1 (MIPS disassembly, 30%) Consider the following snippet of sample code, viewed in MARS. The left hand column represents the address, in hexadecimal, of
Question 1 (MIPS disassembly, 30%) Consider the following snippet of sample code, viewed in MARS. The left hand column represents the address, in hexadecimal, of each MIPS instruction The middle column is the representation of each instruction as a 32 bit number (written in hexadecimal). The right hand column is the corresponding MIPS instruction. Your task is complete the entries in the right hand column by parsing each instruction appropriately. In your final result you can represent registers by their numerical values but remember to assign labels where appropriate. For this example, the following information may be useful. add has a function code of 2016. and has a function code of 2416. addi has an opcode of 816 or has a function code of 2516 s has a function code of 016. slt has a function code of 2a16. bne has an opcode of 0516. beq has an opcode of 0416. jal has an opcode of 0316. j has an opcode of 0216. jr has a function code of 0816 [Ox00400024] 0x00004020 add $8, $0, $o [0x00400028] 0x0005482a [0x0040002c] 0x11200004 [0x00400030] 0x01044020 [0x00400034] 0x20a5ffff .. [0x00400038] 0x0810000a [0x0040003c] 0x01001020 [Ox00400040] 0x03e00008 jr $31 Question 1 (MIPS disassembly, 30%) Consider the following snippet of sample code, viewed in MARS. The left hand column represents the address, in hexadecimal, of each MIPS instruction The middle column is the representation of each instruction as a 32 bit number (written in hexadecimal). The right hand column is the corresponding MIPS instruction. Your task is complete the entries in the right hand column by parsing each instruction appropriately. In your final result you can represent registers by their numerical values but remember to assign labels where appropriate. For this example, the following information may be useful. add has a function code of 2016. and has a function code of 2416. addi has an opcode of 816 or has a function code of 2516 s has a function code of 016. slt has a function code of 2a16. bne has an opcode of 0516. beq has an opcode of 0416. jal has an opcode of 0316. j has an opcode of 0216. jr has a function code of 0816 [Ox00400024] 0x00004020 add $8, $0, $o [0x00400028] 0x0005482a [0x0040002c] 0x11200004 [0x00400030] 0x01044020 [0x00400034] 0x20a5ffff .. [0x00400038] 0x0810000a [0x0040003c] 0x01001020 [Ox00400040] 0x03e00008 jr $31
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started