Changeset 102129 in vbox
- Timestamp:
- Nov 16, 2023 11:36:17 PM (14 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/ValidationKit/bootsectors/bs3-cpu-basic-2-template.mac
r102128 r102129 2070 2070 2071 2071 %assign iIndex 0 2072 %assign cShift 0 2072 %assign cShift 0 ; we don't have enough room for checking all the shifts in the 16-bit segment or the total image. 2073 2073 %rep 8 2074 2074 %if iIndex == 0 … … 2092 2092 %endif 2093 2093 2094 ;%assign cShift 0 2095 ;%rep 4 2094 %if TMPL_BITS == 32 2095 %assign cShiftLoops 1 ;; @todo split out the LEA tests, they are too big and we haven't done 64-bit mode yet. 2096 %else 2097 %assign cShiftLoops 1 2098 %endif 2099 %rep cShiftLoops 2096 2100 2097 2101 ; 2098 ; 32-bit operand size first.2102 ; We don't have room to test both 32-bit and 16-bit operand sizes here for 16-bit code. 2099 2103 ; 2100 2104 call .load_regs 2101 %if iBase == 4 2105 %if iBase == 4 || iDstReg == 4 2106 mov esp, LEA_ESP 2107 %endif 2108 2109 ; lea 2110 %assign iValue iBase_Value + (iIndex_Value << cShift) 2111 db MY_O32 8dh, X86_MODRM_MAKE(iMod, iDstReg, iMemReg), X86_SIB_MAKE(iBase, iIndex, cShift) 2112 %if iMod == X86_MOD_MEM1 2113 db -119 2114 %assign iValue iValue - 119 2115 %elif iMod == X86_MOD_MEM4 || (iMod == 0 && iBase == 5) 2116 dd -04353f1ech 2117 %assign iValue iValue - 04353f1ech 2118 %endif 2119 2120 ; cmp iDstReg, iValue 2121 db MY_CMP_O32 81h, X86_MODRM_MAKE(X86_MOD_REG, 7, iDstReg) 2122 dd iValue & 0ffffffffh 2123 %if iBase == 4 || iDstReg == 4 2124 mov esp, [BS3_DATA_NM(g_bs3CpuBasic2_lea_rsp)] 2125 %endif 2126 jz $+3 2127 int3 2128 2129 %if TMPL_BITS == 32 2130 call .load_regs 2131 %if iBase == 4 || iDstReg == 4 2102 2132 mov esp, LEA_ESP 2103 2133 %endif … … 2117 2147 db MY_CMP_O32 81h, X86_MODRM_MAKE(X86_MOD_REG, 7, iDstReg) 2118 2148 dd iValue & 0ffffffffh 2119 %if iBase == 4 2149 %if iBase == 4 || iDstReg == 4 2120 2150 mov esp, [BS3_DATA_NM(g_bs3CpuBasic2_lea_rsp)] 2121 2151 %endif 2122 2152 jz $+3 2123 2153 int3 2124 2125 %assign cShift (cShift + 1) & 3 2126 ;%endrep 2154 %endif ; TMPL_BITS == 32 2155 2156 %assign cShift (cShift + 1) & 3 2157 %endrep 2127 2158 %assign iIndex iIndex + 1 2128 2159 %endrep
Note:
See TracChangeset
for help on using the changeset viewer.