VirtualBox

Changeset 41506 in vbox for trunk/src/VBox/Devices/PC


Ignore:
Timestamp:
May 30, 2012 7:23:46 PM (13 years ago)
Author:
vboxsync
Message:

Made it work.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/PC/BIOS-new/MakeDebianBiosAssembly.cpp

    r41500 r41506  
    3131#include <iprt/string.h>
    3232#include <iprt/stream.h>
     33#include <iprt/x86.h>
    3334
    3435#include <VBox/dis.h>
     
    723724}
    724725
    725 /*
    726 < 00006590  67 aa 67 e7 67 1b 68 56  55 89 e5 83 ec 08 8a 46  |g.g.g.hVU......F|
    727 < 000065a0  23 30 e4 3d e8 00 74 3f  3d 86 00 75 49 fb 8b 46  |#0.=..t?=..uI..F|
    728 
    729 > 00006590  67 aa e7 67 1b 68 56 55  89 e5 83 ec 08 8a 46 23  |g..g.hVU......F#|
    730 > 000065a0  30 e4 3d e8 00 74 40 3d  86 00 75 4a fb 8b 46 1e  |0.=..t@=..uJ..F.|
    731 */
    732726
    733727/**
     
    739733    bool fDifferent = DISFormatYasmIsOddEncoding(pCpuState);
    740734    uint8_t const  *pb = &g_pbImg[uFlatAddr - VBOX_BIOS_BASE];
    741     if (   pb[0] == 0x2a
    742         && pb[1] == 0xe4)
     735
     736    /*
     737     * Disassembler bugs.
     738     */
     739    /** @todo Group 1a and 11 seems to be disassembled incorrectly when
     740     *        modrm.reg != 0. Those encodings should be invalid AFAICT. */
     741
     742    if (   (   pCpuState->opcode  == 0x8f            /* group 1a */
     743            || pCpuState->opcode  == 0xc7            /* group 11 */
     744            || pCpuState->opcode  == 0xc6            /* group 11 - not verified */
     745           )
     746        && pCpuState->ModRM.Bits.Reg != 0)
     747        fDifferent = true;
     748    /** @todo "TEST Eb,Ib" (f6 0f 08) ends up with no mnemonic as well as
     749     *        wrong length (2 instead of 3)! */
     750    else if (   pCpuState->opcode == 0xf6
     751             && pb[1] == 0x0f
     752             && pb[2] == 0x08)
     753        fDifferent = true;
     754    /*
     755     * Check these out and consider adding them to DISFormatYasmIsOddEncoding.
     756     */
     757    else if (   pb[0] == 0x2a
     758             && pb[1] == 0xe4)
    743759        fDifferent = true; /* sub ah, ah    - alternative form 0x28 0x?? */
    744760    else if (   pb[0] == 0x2b
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