circuit10 704f542b3d [X86] Fix misassemble due to not storing registers to state machine on RParen (#150252)
This fixes #116883.

The x86 parser saves any register it encounters to a TmpReg field in its
state machine, then on encountering the next valid token immediately
afterwards saves it to either BaseReg, or IndexReg if BaseReg was
already filled. However, this saving logic was missing on the RParen
token handler, causing the parser to "forget" the register immediately
beforehand. This also would prevent later validation logic from
detecting the addressing mode as invalid, leading to a silent
misassembly rather than an error.

(cherry picked from commit a073cbbb1aeaaeac01b12e818fe47e4c04080aac)
2025-07-28 09:37:08 +02:00
..