0

How to extract the opcode and the data form the instruction? "instruction" is inst below in decimal. For some values of "??", I should be able to extract the opCode and data???

opCode = inst >>??;
data = inst & ??;

It is done on a x86 processor using C.
It is 16 bit in total.

Starting from 0 from the right to left.
11th to 15th bit is OpCode.

0 to 9th bit is Data.


Is there a shortcut using hexadecimal notation?

2
Contributors
1
Reply
2
Views
11 Years
Discussion Span
Last Post by Salem
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.