Changeset 103622 in vbox for trunk/src/VBox/VMM/include/IEMN8veRecompilerEmit.h
- Timestamp:
- Mar 1, 2024 12:42:36 AM (11 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/include/IEMN8veRecompilerEmit.h
r103613 r103622 6720 6720 { 6721 6721 IEMNATIVE_ASSERT_VAR_IDX(pReNative, idxVar); 6722 AssertStmt(pReNative->Core.aVars[idxVar].enmKind == kIemNativeVarKind_Stack,6723 6724 6725 uint8_t const idxRegVar = p ReNative->Core.aVars[idxVar].idxReg;6722 PIEMNATIVEVAR const pVar = &pReNative->Core.aVars[IEMNATIVE_VAR_IDX_UNPACK(idxVar)]; 6723 AssertStmt(pVar->enmKind == kIemNativeVarKind_Stack, IEMNATIVE_DO_LONGJMP(pReNative, VERR_IEM_VAR_UNEXPECTED_KIND)); 6724 6725 uint8_t const idxRegVar = pVar->idxReg; 6726 6726 if ( idxRegVar < RT_ELEMENTS(pReNative->Core.aHstRegs) 6727 6727 && ( (RT_BIT_32(idxRegVar) & (~IEMNATIVE_CALL_VOLATILE_GREG_MASK | fHstVolatileRegsAllowed)) … … 6741 6741 else 6742 6742 { 6743 uint8_t const idxStackSlot = p ReNative->Core.aVars[idxVar].idxStackSlot;6743 uint8_t const idxStackSlot = pVar->idxStackSlot; 6744 6744 AssertStmt(idxStackSlot != UINT8_MAX, IEMNATIVE_DO_LONGJMP(pReNative, VERR_IEM_VAR_NOT_INITIALIZED)); 6745 6745 off = iemNativeEmitLoadGprByBp(pReNative, off, idxRegArg, iemNativeStackCalcBpDisp(idxStackSlot)); … … 6762 6762 { 6763 6763 IEMNATIVE_ASSERT_VAR_IDX(pReNative, idxVar); 6764 if (pReNative->Core.aVars[idxVar].enmKind == kIemNativeVarKind_Immediate) 6765 off = iemNativeEmitLoadGprImm64(pReNative, off, idxRegArg, pReNative->Core.aVars[idxVar].u.uValue + offAddend); 6764 PIEMNATIVEVAR const pVar = &pReNative->Core.aVars[IEMNATIVE_VAR_IDX_UNPACK(idxVar)]; 6765 if (pVar->enmKind == kIemNativeVarKind_Immediate) 6766 off = iemNativeEmitLoadGprImm64(pReNative, off, idxRegArg, pVar->u.uValue + offAddend); 6766 6767 else 6767 6768 off = iemNativeEmitLoadArgGregFromStackVar(pReNative, off, idxRegArg, idxVar, offAddend, … … 6781 6782 { 6782 6783 IEMNATIVE_ASSERT_VAR_IDX(pReNative, idxVar); 6783 AssertStmt( pReNative->Core.aVars[idxVar].enmKind == kIemNativeVarKind_Invalid 6784 || pReNative->Core.aVars[idxVar].enmKind == kIemNativeVarKind_Stack, 6784 PIEMNATIVEVAR const pVar = &pReNative->Core.aVars[IEMNATIVE_VAR_IDX_UNPACK(idxVar)]; 6785 AssertStmt( pVar->enmKind == kIemNativeVarKind_Invalid 6786 || pVar->enmKind == kIemNativeVarKind_Stack, 6785 6787 IEMNATIVE_DO_LONGJMP(pReNative, VERR_IEM_VAR_UNEXPECTED_KIND)); 6786 6788 … … 6788 6790 int32_t const offBpDisp = iemNativeStackCalcBpDisp(idxStackSlot); 6789 6791 6790 uint8_t const idxRegVar = p ReNative->Core.aVars[idxVar].idxReg;6792 uint8_t const idxRegVar = pVar->idxReg; 6791 6793 if (idxRegVar < RT_ELEMENTS(pReNative->Core.aHstRegs)) 6792 6794 { 6793 6795 off = iemNativeEmitStoreGprByBp(pReNative, off, offBpDisp, idxRegVar); 6794 6796 iemNativeRegFreeVar(pReNative, idxRegVar, fFlushShadows); 6795 Assert(p ReNative->Core.aVars[idxVar].idxReg == UINT8_MAX);6796 } 6797 Assert( p ReNative->Core.aVars[idxVar].idxStackSlot != UINT8_MAX6798 && p ReNative->Core.aVars[idxVar].idxReg == UINT8_MAX);6797 Assert(pVar->idxReg == UINT8_MAX); 6798 } 6799 Assert( pVar->idxStackSlot != UINT8_MAX 6800 && pVar->idxReg == UINT8_MAX); 6799 6801 6800 6802 return iemNativeEmitLeaGprByBp(pReNative, off, idxRegArg, offBpDisp);
Note:
See TracChangeset
for help on using the changeset viewer.