order for encoding x86 instruction prefix bytes

后端 未结 3 2585
一个人的身影
一个人的身影 2021-02-20 18:33

I know that x86 instructions can have a maximum of 4 bytes of prefixes, e.g Lock, rep, segment overrides etc.

Is there any particular order in which they should appear,

3条回答
  •  伪装坚强ぢ
    2021-02-20 18:44

    The architecture volume of the intel developer manuals details the layout at lenght, however, from what I remember last time I read it, the order for most didn't matter, except the REX/REX.W prefix which must occupy the slot closest to the start of the actual instruction bytes (aka it takes the slot most on the right)

提交回复
热议问题