Answered step by step
Verified Expert Solution
Question
1 Approved Answer
1. Determine the type of the following MIPS instructions: a) xor $t0, $t1, $t2 b) addu $t0, $t1, $t2 c) addiu $t0, $s1, 0xA2C0
1. Determine the type of the following MIPS instructions: a) xor $t0, $t1, $t2 b) addu $t0, $t1, $t2 c) addiu $t0, $s1, 0xA2C0 d) subu $t0, $t1, $t2 e) sll $s1, $s2, 8 f) srlv $s1, $s2, $s3 g) sra $s1, $s2, 4 h) add $50, $s1, $s2 i) and $t0, $s1, $s2 j) andi $t0, $s1, 25 2. Translate the following MIPS instructions to binary code: instruction Binary code Xor addu addiu sll srlv add andi $t0, $t1, $t2 $to, $t1, $t2 $t0, $s1, 0xA2C0 $s1, $s2, 8 $s1, $s2, $s3 $50, $s1, $s2 St0, $s1, 25 Code in Hexa 3. Carry out resulting from addition of unsigned numbers can be used to check if the result of addition is incorrect. Write the shortest sequence of MIPS instructions to determine if there is a carry out from the addition of two registers St1 and St2. Place the carry out (0 or 1) in register $10. 4. Write a MIPS assembly program that asks the user to enter an integer, reads the integer and then displays the integer representation in both binary and hexadecimal, assuming 32-bit representation. A sample execution of the program is given below: Example: Enter an integer: -5 Number representation in binary is: 1111111|||||||||||||||||||1111011 Number representation in hexadecimal is: FFFFFFFB
Step by Step Solution
There are 3 Steps involved in it
Step: 1
The image you have provided shows a computer science assignment relating to MIPS Microprocessor without Interlocked Pipelined Stages assembly language instructions Below are the tasks as listed in the ...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