Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Converting binary/hexadecimal to MIPS instructions

Tags:

mips

For the following entries, what instructions do they represent respectively?

Binary: 00000001110001011000100000100001

Hexadecimal: 144FFF9D

I'm completely lost on what I'm doing here - searching online has produced a bunch of results that make very little sense to me, but what I've gathered is I'm basically supposed to match up the numbers to their appropriate instructions/registers, but how exactly do I know what those are? Where can I find a comprehensive list? How do I know whether it's an R I or J format function?

like image 909
secondubly Avatar asked Jun 30 '26 19:06

secondubly


1 Answers

The first 6 bits (it is easier to work in binary) are the opcode, from which you can determine how to interpret the rest. This site should get you started: http://www.mrc.uidaho.edu/mrc/people/jff/digital/MIPSir.html

Update: Calling the first 6 bits the opcode is (to be too kind) misleading, but it is enough to tell you how to interpret the rest of the instruction; you may need to look elsewhere (typically at the end of the instruction) for the complete determination of the opcode.

like image 174
Scott Hunter Avatar answered Jul 04 '26 16:07

Scott Hunter



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!