Changeset 103782 in vbox
- Timestamp:
- Mar 11, 2024 5:25:09 PM (12 months ago)
- svn:sync-xref-src-repo-rev:
- 162151
- Location:
- trunk/src/VBox/VMM
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMAll/IEMAllInstPython.py
r103779 r103782 3098 3098 'IEM_MC_FETCH_YREG_U256': (McBlock.parseMcGeneric, False, False, False, ), 3099 3099 'IEM_MC_FETCH_YREG_U32': (McBlock.parseMcGeneric, False, False, False, ), 3100 'IEM_MC_FETCH_YREG_U64': (McBlock.parseMcGeneric, False, False, False,),3100 'IEM_MC_FETCH_YREG_U64': (McBlock.parseMcGeneric, False, False, True, ), 3101 3101 'IEM_MC_FLIP_EFL_BIT': (McBlock.parseMcGeneric, True, True, False, ), 3102 3102 'IEM_MC_FPU_FROM_MMX_MODE': (McBlock.parseMcGeneric, True, True, False, ), -
trunk/src/VBox/VMM/VMMAll/IEMAllN8veRecompiler.cpp
r103779 r103782 15293 15293 /* Free but don't flush the source register. */ 15294 15294 iemNativeSimdRegFreeTmp(pReNative, idxSimdRegDst); 15295 iemNativeVarRegisterRelease(pReNative, idxDstVar); 15296 15297 return off; 15298 } 15299 15300 15301 #define IEM_MC_FETCH_YREG_U64(a_u64Dst, a_iYRegSrc) \ 15302 off = iemNativeEmitSimdFetchYregU64(pReNative, off, a_u64Dst, a_iYRegSrc, 0) 15303 15304 /** Emits code for IEM_MC_FETCH_YREG_U64. */ 15305 DECL_INLINE_THROW(uint32_t) 15306 iemNativeEmitSimdFetchYregU64(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t idxDstVar, uint8_t iYReg, uint8_t iQWord) 15307 { 15308 IEMNATIVE_ASSERT_VAR_IDX(pReNative, idxDstVar); 15309 IEMNATIVE_ASSERT_VAR_SIZE(pReNative, idxDstVar, sizeof(uint64_t)); 15310 15311 uint8_t const idxSimdRegSrc = iemNativeSimdRegAllocTmpForGuestSimdReg(pReNative, &off, IEMNATIVEGSTSIMDREG_SIMD(iYReg), 15312 iQWord >= 2 15313 ? kIemNativeGstSimdRegLdStSz_High128 15314 : kIemNativeGstSimdRegLdStSz_Low128, 15315 kIemNativeGstRegUse_ReadOnly); 15316 15317 iemNativeVarSetKindToStack(pReNative, idxDstVar); 15318 uint8_t const idxVarReg = iemNativeVarRegisterAcquire(pReNative, idxDstVar, &off); 15319 15320 off = iemNativeEmitSimdLoadGprFromVecRegU64(pReNative, off, idxVarReg, idxSimdRegSrc, iQWord); 15321 15322 /* Free but don't flush the source register. */ 15323 iemNativeSimdRegFreeTmp(pReNative, idxSimdRegSrc); 15295 15324 iemNativeVarRegisterRelease(pReNative, idxDstVar); 15296 15325 -
trunk/src/VBox/VMM/include/IEMN8veRecompilerEmit.h
r103780 r103782 7093 7093 { 7094 7094 #ifdef RT_ARCH_AMD64 7095 /* pextrq gpr, vecsrc, #iQWord (ASSUMES SSE4.1). */ 7096 pCodeBuf[off++] = X86_OP_PRF_SIZE_OP; 7097 pCodeBuf[off++] = X86_OP_REX_W 7098 | (iVecRegSrc < 8 ? 0 : X86_OP_REX_R) 7099 | (iGprDst < 8 ? 0 : X86_OP_REX_B); 7100 pCodeBuf[off++] = 0x0f; 7101 pCodeBuf[off++] = 0x3a; 7102 pCodeBuf[off++] = 0x16; 7103 pCodeBuf[off++] = X86_MODRM_MAKE(X86_MOD_REG, iVecRegSrc & 7, iGprDst & 7); 7104 pCodeBuf[off++] = iQWord; 7095 if (iQWord >= 2) 7096 { 7097 /** @todo Currently not used. */ 7098 AssertReleaseFailed(); 7099 } 7100 else 7101 { 7102 /* pextrq gpr, vecsrc, #iQWord (ASSUMES SSE4.1). */ 7103 pCodeBuf[off++] = X86_OP_PRF_SIZE_OP; 7104 pCodeBuf[off++] = X86_OP_REX_W 7105 | (iVecRegSrc < 8 ? 0 : X86_OP_REX_R) 7106 | (iGprDst < 8 ? 0 : X86_OP_REX_B); 7107 pCodeBuf[off++] = 0x0f; 7108 pCodeBuf[off++] = 0x3a; 7109 pCodeBuf[off++] = 0x16; 7110 pCodeBuf[off++] = X86_MODRM_MAKE(X86_MOD_REG, iVecRegSrc & 7, iGprDst & 7); 7111 pCodeBuf[off++] = iQWord; 7112 } 7105 7113 #elif defined(RT_ARCH_ARM64) 7106 7114 /* umov gprdst, vecsrc[iQWord] */ … … 7119 7127 iemNativeEmitSimdLoadGprFromVecRegU64(PIEMRECOMPILERSTATE pReNative, uint32_t off, uint8_t iGprDst, uint8_t iVecRegSrc, uint8_t iQWord) 7120 7128 { 7121 Assert(iQWord <= 1);7129 Assert(iQWord <= 3); 7122 7130 7123 7131 #ifdef RT_ARCH_AMD64 7124 7132 off = iemNativeEmitSimdLoadGprFromVecRegU64Ex(iemNativeInstrBufEnsure(pReNative, off, 7), off, iGprDst, iVecRegSrc, iQWord); 7125 7133 #elif defined(RT_ARCH_ARM64) 7126 off = iemNativeEmitSimdLoadGprFromVecRegU64Ex(iemNativeInstrBufEnsure(pReNative, off, 1), off, iGprDst, iVecRegSrc, iQWord); 7134 /* ASSUMES that there are two adjacent 128-bit registers available for the 256-bit value. */ 7135 Assert(!(iVecRegSrc & 0x1)); 7136 /* Need to access the "high" 128-bit vector register. */ 7137 if (iQWord >= 2) 7138 off = iemNativeEmitSimdLoadGprFromVecRegU64Ex(iemNativeInstrBufEnsure(pReNative, off, 1), off, iGprDst, iVecRegSrc + 1, iQWord - 2); 7139 else 7140 off = iemNativeEmitSimdLoadGprFromVecRegU64Ex(iemNativeInstrBufEnsure(pReNative, off, 1), off, iGprDst, iVecRegSrc, iQWord); 7127 7141 #else 7128 7142 # error "port me"
Note:
See TracChangeset
for help on using the changeset viewer.