VirtualBox

Changeset 21186 in vbox for trunk/src/recompiler


Ignore:
Timestamp:
Jul 3, 2009 9:48:09 AM (16 years ago)
Author:
vboxsync
Message:

recompiler: Fixed mov to/from CRx/DRx decoding to match reality (mod bits must be ignored).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/recompiler/target-i386/translate.c

    r18476 r21186  
    80798079        } else {
    80808080            modrm = ldub_code(s->pc++);
     8081#ifndef VBOX    /* mod bits are always understood to be 11 (0xc0) regardless of actual content; see AMD manuals */
    80818082            if ((modrm & 0xc0) != 0xc0)
    80828083                goto illegal_op;
     8084#endif
    80838085            rm = (modrm & 7) | REX_B(s);
    80848086            reg = ((modrm >> 3) & 7) | rex_r;
     
    81198121        } else {
    81208122            modrm = ldub_code(s->pc++);
     8123#ifndef VBOX    /* mod bits are always understood to be 11 (0xc0) regardless of actual content; see AMD manuals */
    81218124            if ((modrm & 0xc0) != 0xc0)
    81228125                goto illegal_op;
     8126#endif
    81238127            rm = (modrm & 7) | REX_B(s);
    81248128            reg = ((modrm >> 3) & 7) | rex_r;
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette