Closed dvyukov closed 1 year ago
@khuey would it be possible for you to take this on?
Looks like we just don't handle ud1 (or ud0 for that matter). How do we feel about renumbering the opcodes vs adding missing stuff at the end?
Ah, no, actually we do decode ud1 (just as OP_ud2b), there's just no operands listed in the decode table.
There's still the question of what we want to do about ud0, but perhaps we just punt on that for now.
Looks like we just don't handle ud1 (or ud0 for that matter). How do we feel about renumbering the opcodes vs adding missing stuff at the end?
We add at the end.
Thanks!
This byte sequence is a single UD1 instruction:
but drdecode decodes it as 3-byte instruction. This breaks decoding of instruction stream. I see lots of these instructions in real binaries compiled with clang, it seems to use it as padding at the end of functions or something.
I am using commit 45c9973e363254d534b819d3cc508601f534bb71.