Question

Please convert the following bit pattern to a MIPS instruction. 0000 0001 0110 0110 0100 1000...

Please convert the following bit pattern to a MIPS instruction.

0000 0001 0110 0110 0100 1000 0010 0000

1000 1101 1001 1010 0000 0000 0001 1100

Homework Answers

Answer #1

Converting bit patterns to a MIPS instruction.

bit pattern 1:

0000 0001 0110 0110 0100 1000 0010 0000

The first 6 digits 000000
The given code is for ADD instruction.

Splitting the opcodes:
000000|01011|00110|01001|00000|100000

Instruction:
ADD rd,rs,rt

opcode rs rt rd shift amt function
6 bits 5 bits 5bits 5bits 5bits 6 bits
000000 01011 00110 01001 00000 100000

Registers for codes

01011 --->$t3

00110 --->$a2

01001 --->$t1

Complete Final instruction :

add $t1,$t3,$a2.


bit pattern 2:

1000 1101 1001 1010 0000 0000 0001 1100

The first 6 digits 100011
The given instruction is for LW instruction.

Splitting the opcodes:
100011|01100|11010|0000 0000 0001 1100

Instruction:
LW rt,offset(rs)

opcode rs rt address
6bits 5bits 5bits 16bits
1000011 01100 11010

0000 0000 0001 1100

Registers for codes

01100 --->$t4

11010 --->$k0

Offset address in the code must be hexadecimal

0000 0000 0001 1100 into hexa is

0000-->0

0000-->0

0001-->1

1100-->C

Therfore hexa code:

0x001C

Complete Final instruction :

lw $k0,0x001C($t4)

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
7. Encode the following message using the ASCII encoding scheme:  I love CS! 1. 0100 0011 0101...
7. Encode the following message using the ASCII encoding scheme:  I love CS! 1. 0100 0011 0101 0011 0010 0000 0111 0010 0111 0101 0110 1100 0110 0101 0111 0011 0010 0001 2. 0100 0011 0101 0011 0010 0000 0111 0010 0111 0101 0111 1100 0110 0101 0111 0011 0010 0001 3. 0100 1001 0010 0000 0110 1100 0110 1111 0111 0110 0110 0101 0010 0000 0100 0011 0101 0011 0010 0001 4. 0100 0011 0101 0011 0010 0000 0111 0010...
Write the MIPS assembly code that creates the 32-bit constant 0010 0000 0000 0001 0100 1001...
Write the MIPS assembly code that creates the 32-bit constant 0010 0000 0000 0001 0100 1001 0010 0100two and stores that value to register $t1, and print the value of $t1 to stdout in binary - i.e., as a 32 bit sequence of '1's and '0's (use the MIPS syscall functionality for I/O).
The cache is direct mapped, 16 lines, each line is 2 bytes The offset field is...
The cache is direct mapped, 16 lines, each line is 2 bytes The offset field is ________ bits The line field is ________ bits The tag field is ________ bits line tag byte 0 byte 1 (can someone explain this to me) 0000 0001 0010 0011 0100 0101 0110 0111 1000 1001 1010 1011 1100 1101 1110 1111
a. Write MIPS assembly code for the following machine code. Assume that the segment is placed...
a. Write MIPS assembly code for the following machine code. Assume that the segment is placed starting at location 8000. Create labels for branch and jump instructions and indicate the 0001 0001 0010 1000 0000 0000 0000 0011 1000 1110 0001 0001 0000 0000 0000 1000 0010 0010 0010 1000 0000 0000 0000 0110 0000 1000 0000 0000 0000 0001 0000 0010 b. Translate the following C function into MIPS assembly code. int f1(int ar1[], int ar2[], int n) {...
Suppose the information content of a packet is the bit pattern 1010 0000 1001 1101 and...
Suppose the information content of a packet is the bit pattern 1010 0000 1001 1101 and an even parity scheme is being used. What would the value of the field containing the parity bits be for the case of a two-dimensional parity scheme? Your answer should be such that a minimum-length checksum field is used.
5. Convert each of the following binary numbers into base 10. Show your work. (a) 0011...
5. Convert each of the following binary numbers into base 10. Show your work. (a) 0011 0001 (b) 0011 1011 (c) 0101 0110 (d) 1101 1101 (e) 0001 1000 (f) 0010 1110
Convert 1101 0001 1100 0011 binary to decimal (value is a 16-bit integer). The answer is...
Convert 1101 0001 1100 0011 binary to decimal (value is a 16-bit integer). The answer is -11837 but I would like the work to be shown, please
16.  Convert the following decimal notation to an equivalent binary notation: 2.75 17. If the following uses...
16.  Convert the following decimal notation to an equivalent binary notation: 2.75 17. If the following uses the floating-point format defined in Figure 1.25 of the textbook, what is the decimal notation for this number: 01100101 18. Encode the following decimal value using the 8-bit floating-point format of Figure 1.25: 7/8 HINT: Be sure to use the normalized form. Note: Answer should be in the format n nnn nnnn 19. Encode the following decimal value using the 8 bit floating point...
Assignment-I Write the output for the following instructions MOV B , A             Before instruction execution, the...
Assignment-I Write the output for the following instructions MOV B , A             Before instruction execution, the contents of registers B and A are                                  Rd= B= XBH                         Rs= A = 1FH              After the execution of instruction.                                 Rd= B = ?                         Rs= A = ? ADD B If A= E 3H   B=  0 4H then after the  execution of the above instruction the content of A = ? SUI 03H If the value of A = 15Hthen after the execution of the above instruction...
Question 6: Convert BCD 1001 0011 to decimal Question 7: Convert hexadecimal AA to decimal Question...
Question 6: Convert BCD 1001 0011 to decimal Question 7: Convert hexadecimal AA to decimal Question 8: What is the 2’s complement of (01001110)2? Question 9: How is – 1510 represented in eight-bit 2’s complement notation? Question 10: How is – 11210 represented in eight-bit 2’s complement notation? Question 11: Solve the binary arithmetic problem: (00010111)2 + (00101001)2 Question 12: Solve the binary arithmetic problem: (1010)2 - (0100)2 Question 13: Solve the following problem: (01110000)2 - (00011000)2 Question 14: Solve...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT