VirtualBox

Changeset 22152 in vbox for trunk/src/VBox/VMM


Ignore:
Timestamp:
Aug 11, 2009 10:02:17 AM (15 years ago)
Author:
vboxsync
Message:

Deal with out of memory situations for function lookups

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/PATM/VMMGC/PATMGC.cpp

    r18927 r22152  
    219219                else
    220220                {
     221                    /* Check first before trying to generate a function/trampoline patch. */
     222                    if (pVM->patm.s.fOutOfMemory)
     223                    {
     224                        pRegFrame->eip += PATM_ILLEGAL_INSTR_SIZE;
     225                        pRegFrame->eax = 0;     /* make it fault */
     226                        STAM_COUNTER_INC(&pVM->patm.s.StatFunctionNotFound);
     227                        return VINF_SUCCESS;
     228                    }
    221229                    STAM_COUNTER_INC(&pVM->patm.s.StatFunctionNotFound);
    222230                    return VINF_PATM_DUPLICATE_FUNCTION;
     
    411419
    412420            case PATM_ACTION_LOG_RET:
    413                 Log(("PATMGC: RET to %x ESP=%x iopl=%d\n", pRegFrame->edx, pRegFrame->ebx, X86_EFL_GET_IOPL(pVM->patm.s.CTXSUFF(pGCState)->uVMFlags)));
     421                Log(("PATMGC: RET from %x to %x ESP=%x iopl=%d\n", pRegFrame->eip, pRegFrame->edx, pRegFrame->ebx, X86_EFL_GET_IOPL(pVM->patm.s.CTXSUFF(pGCState)->uVMFlags)));
    414422                pRegFrame->eip += PATM_ILLEGAL_INSTR_SIZE;
    415423                return VINF_SUCCESS;
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