- Timestamp:
- Apr 4, 2007 3:25:07 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Disassembler/DisasmCore.cpp
r1935 r1938 235 235 }; 236 236 237 static unsigned g_aRegHidSegIndex[] = 238 { 239 RT_OFFSETOF(CPUMCTXCORE, esHid), /* USE_REG_ES */ 240 RT_OFFSETOF(CPUMCTXCORE, csHid), /* USE_REG_CS */ 241 RT_OFFSETOF(CPUMCTXCORE, ssHid), /* USE_REG_SS */ 242 RT_OFFSETOF(CPUMCTXCORE, dsHid), /* USE_REG_DS */ 243 RT_OFFSETOF(CPUMCTXCORE, fsHid), /* USE_REG_FS */ 244 RT_OFFSETOF(CPUMCTXCORE, gsHid) /* USE_REG_GS */ 245 }; 246 237 247 /** 238 248 * Macro for accessing segment registers in CPUMCTXCORE structure. … … 565 575 566 576 /** 577 * Returns the value of the specified segment register including a pointer to the hidden register in the supplied cpu context 578 * 579 */ 580 DISDECL(int) DISFetchRegSegEx(PCPUMCTXCORE pCtx, uint32_t sel, RTSEL *pVal, CPUMSELREGHID **ppSelHidReg) 581 { 582 AssertReturn(sel < ELEMENTS(g_aRegSegIndex), VERR_INVALID_PARAMETER); 583 584 AssertCompile(sizeof(uint16_t) == sizeof(RTSEL)); 585 *pVal = DIS_READ_REGSEG(pCtx, sel); 586 *ppSelHidReg = (CPUMSELREGHID *)((char *)pCtx + g_aRegHidSegIndex[sel]); 587 return VINF_SUCCESS; 588 } 589 590 /** 567 591 * Updates the value of the specified 32 bits general purpose register 568 592 *
Note:
See TracChangeset
for help on using the changeset viewer.