I use 'objdump' on linux in a variety of binaries and it returns their assembly. The commands that I receive is 'real' commands or pseudo-command? I have read that there are some commands which are a combination of other commands and they are called pseudo-commands. Is it true? If yes, how can I get only 'real' commands from a executable?
Asked
Active
Viewed 79 times
0
-
1Your terminology is incorrect. A disassembly does not necessarily produce *"assembly"*, which allows label and variable names. Unless there's a symbol table available, disassembly simply produces instructions in mnemonic form. It's not *"commands"*, but instructions. – sawdust Apr 25 '19 at 07:35
-
It's a bit confusing. Are there any reference for disassembly, instruction set for various architectures? – 0sunday Apr 25 '19 at 10:02
1 Answers
0
On current x86- or ARM-based systems running Linux, the disassembled instructions will be real instructions.
Pseudo-operations are a convenience used when creating software, such as short sequences of instructions that are commonly used together, or instructions that are implemented in less-than-obvious ways.
For example, the instruction
mov eax, #0
which puts zero into register EAX, might be possible to implement in fewer bytes, and/or less time, as:
xor eax, eax
That exclusive-ORs register EAX with itself, which will always produce zero. An assembler thus might convert the easy-to-understand instruction into the smaller or faster form.
John Dallman
- 505
- 3
- 11