| | |
How to extract the opcode and the data form the instruction
![]() |
•
•
Join Date: Oct 2006
Posts: 3
Reputation:
Solved Threads: 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?
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?
Last edited by sciconf; Oct 2nd, 2006 at 11:39 pm.
Something like
Assembly Syntax (Toggle Plain Text)
( opc >> 11 ) & 0x3f; // 6 bits opc & 0x3ff; // 10 bits
![]() |
Similar Threads
- Please help with passing data from one form to another form (VB.NET)
- Input data form - autofill from Excel or ACT! sql (ASP)
- posting data from a form to msg broker fail (RSS, Web Services and SOAP)
- Extract MIME type from binary file data (C#)
- receiving data from a form in PHP? (PHP)
- Posting form data to an Oracle database (JavaScript / DHTML / AJAX)
Other Threads in the Assembly Forum
- Previous Thread: urgently help in a program in MIPS
- Next Thread: IPv6 Address Storage in Memory?
| Thread Tools | Search this Thread |






