1

As described in this x86 Assembly Guide, x86 Assembly instruction can be divided into the following categories:

Control Flow Instructions, Arithmetic and Logic Instructions and Data Movement Instructions

However, if have not been able to find an actual list of all x86 Instruction categorized in these categories. All I've found are examples, as the ones in the mentioned guide.

Does anyone know where to find such a list?

Peter Cordes
  • 328,167
  • 45
  • 605
  • 847
MateMann
  • 11
  • 1
  • 3
    I would also add "Processor state control instructions". Some of those might loosely be considered data movement (lgdt/sgdt), but others don't fit so neatly (cli/sti). – SoronelHaetir Jun 22 '22 at 16:56
  • I needed to categorize an (almost) *actual list of all x86 and x86-64 Instructions* into [modules](https://euroassembler.eu/easource/), each module source yields a brief description of every instruction. You will have to assign them to categories of your choice manually, I'm afraid. – vitsoft Jun 22 '22 at 18:15
  • 6
    https://uops.info/xml.html has a `category` attribute for each instruction. It won't match your question because that tutorial is awkwardly outdated and its categorization is arbitrary and oversimplistic. If you want: download it and run `grep -oP 'category="\K[^"]+' instructions.xml | sort | uniq` to see all the categories. You can then merge categories with simple find/replace operations. I don't think somebody made a ready-to-use list as you want. – Margaret Bloom Jun 22 '22 at 18:46
  • Thanks for the link to uops.info. You can generate a nice list with `xmlstarlet sel -t -v "//instruction/@category" instructions.xml | sort | uniq -c | sort -n`. – zx485 Jun 22 '22 at 23:24
  • 2
    Note that the text says "Machine instructions **generally** fall into three categories: data movement, arithmetic/logic, and control-flow." (emphasis mine). The categorization is informal. It's just something the author made up. – Raymond Chen Jun 23 '22 at 00:52
  • Here's some questions: how are categories used, who consumes them, what happens if an instruction is miscatagoried? If the answers are: they aren't, no one, and nothing, then the categories are just made up, so go along with. – Erik Eidt Aug 11 '22 at 01:21

0 Answers0