Changeset 41744 in vbox for trunk/include/VBox/dis.h
- Timestamp:
- Jun 15, 2012 2:29:09 AM (13 years ago)
- svn:sync-xref-src-repo-rev:
- 78552
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/dis.h
r41743 r41744 194 194 /** @name 64-bit general register indexes. 195 195 * This matches the AMD64 register encoding. It is found used in 196 * DISOPPARAM:: base.reg_genand DISOPPARAM::Index.idxGenReg.196 * DISOPPARAM::Base.idxGenReg and DISOPPARAM::Index.idxGenReg. 197 197 * @note Safe to assume same values as the 16-bit and 32-bit general registers. 198 198 * @{ … … 218 218 /** @name 32-bit general register indexes. 219 219 * This matches the AMD64 register encoding. It is found used in 220 * DISOPPARAM:: base.reg_genand DISOPPARAM::Index.idxGenReg.220 * DISOPPARAM::Base.idxGenReg and DISOPPARAM::Index.idxGenReg. 221 221 * @note Safe to assume same values as the 16-bit and 64-bit general registers. 222 222 * @{ … … 242 242 /** @name 16-bit general register indexes. 243 243 * This matches the AMD64 register encoding. It is found used in 244 * DISOPPARAM:: base.reg_genand DISOPPARAM::Index.idxGenReg.244 * DISOPPARAM::Base.idxGenReg and DISOPPARAM::Index.idxGenReg. 245 245 * @note Safe to assume same values as the 32-bit and 64-bit general registers. 246 246 * @{ … … 266 266 /** @name 8-bit general register indexes. 267 267 * This mostly (?) matches the AMD64 register encoding. It is found used in 268 * DISOPPARAM:: base.reg_genand DISOPPARAM::Index.idxGenReg.268 * DISOPPARAM::Base.idxGenReg and DISOPPARAM::Index.idxGenReg. 269 269 * @{ 270 270 */ … … 293 293 /** @name Segment registerindexes. 294 294 * This matches the AMD64 register encoding. It is found used in 295 * DISOPPARAM:: base.reg_seg.295 * DISOPPARAM::Base.idxSegReg. 296 296 * @{ 297 297 */ … … 311 311 /** @name FPU register indexes. 312 312 * This matches the AMD64 register encoding. It is found used in 313 * DISOPPARAM:: base.reg_fp.313 * DISOPPARAM::Base.idxFpuReg. 314 314 * @{ 315 315 */ … … 326 326 /** @name Control register indexes. 327 327 * This matches the AMD64 register encoding. It is found used in 328 * DISOPPARAM:: base.reg_ctrl.328 * DISOPPARAM::Base.idxCtrlReg. 329 329 * @{ 330 330 */ … … 339 339 /** @name Debug register indexes. 340 340 * This matches the AMD64 register encoding. It is found used in 341 * DISOPPARAM:: base.reg_dbg.341 * DISOPPARAM::Base.idxDbgReg. 342 342 * @{ 343 343 */ … … 354 354 /** @name MMX register indexes. 355 355 * This matches the AMD64 register encoding. It is found used in 356 * DISOPPARAM:: base.reg_mmx.356 * DISOPPARAM::Base.idxMmxReg. 357 357 * @{ 358 358 */ … … 369 369 /** @name SSE register indexes. 370 370 * This matches the AMD64 register encoding. It is found used in 371 * DISOPPARAM:: base.reg_xmm.371 * DISOPPARAM::Base.idxXmmReg. 372 372 * @{ 373 373 */ … … 380 380 #define DISXREG_XMM6 UINT8_C(6) 381 381 #define DISXREG_XMM7 UINT8_C(7) 382 /** @} 382 /** @} */ 383 383 384 384 … … 388 388 typedef struct DISOPPARAM 389 389 { 390 /** Immediate value or address, if used. */391 uint64_t uValue;392 390 /** A combination of DISUSE_XXX. */ 393 391 uint64_t fUse; 392 /** Immediate value or address, applicable if any of the flags included in 393 * DISUSE_IMMEDIATE are set in fUse. */ 394 uint64_t uValue; 395 /** Disposition. */ 394 396 union 395 397 { 398 /** 64-bit displacement, applicable if DISUSE_DISPLACEMENT64 is set in fUse. */ 396 399 int64_t i64; 400 uint64_t u64; 401 /** 32-bit displacement, applicable if DISUSE_DISPLACEMENT32 or 402 * DISUSE_RIPDISPLACEMENT32 is set in fUse. */ 397 403 int32_t i32; 404 uint32_t u32; 405 /** 16-bit displacement, applicable if DISUSE_DISPLACEMENT16 is set in fUse. */ 398 406 int32_t i16; 407 uint32_t u16; 408 /** 8-bit displacement, applicable if DISUSE_DISPLACEMENT8 is set in fUse. */ 399 409 int32_t i8; 400 uint64_t u64;401 uint32_t u32;402 uint32_t u16;403 410 uint32_t u8; 404 411 } uDisp; 405 /** Copy of the corresponding DISOPCODE::fParam1 / DISOPCODE::fParam2 / 406 * DISOPCODE::fParam3. */ 407 uint32_t fParam; 408 412 /** The base register from ModR/M or SIB, applicable if DISUSE_BASE is 413 * set in fUse. */ 409 414 union 410 415 { 411 /** DISGREG_XXX. */ 412 uint8_t reg_gen; 413 /** DISFPREG_XXX */ 414 uint8_t reg_fp; 415 /** DISMREG_XXX. */ 416 uint8_t reg_mmx; 417 /** DISXREG_XXX. */ 418 uint8_t reg_xmm; 419 /** DISSELREG_XXX. */ 420 uint8_t reg_seg; 421 /** TR0-TR7 (no defines for these). */ 422 uint8_t reg_test; 423 /** DISCREG_XXX */ 424 uint8_t reg_ctrl; 425 /** DISDREG_XXX */ 426 uint8_t reg_dbg; 427 } base; 416 /** General register index (DISGREG_XXX), applicable if DISUSE_REG_GEN8, 417 * DISUSE_REG_GEN16, DISUSE_REG_GEN32 or DISUSE_REG_GEN64 is set in fUse. */ 418 uint8_t idxGenReg; 419 /** FPU stack register index (DISFPREG_XXX), applicable if DISUSE_REG_FP is 420 * set in fUse. 1:1 indexes. */ 421 uint8_t idxFpuReg; 422 /** MMX register index (DISMREG_XXX), applicable if DISUSE_REG_MMX is 423 * set in fUse. 1:1 indexes. */ 424 uint8_t idxMmxReg; 425 /** SSE register index (DISXREG_XXX), applicable if DISUSE_REG_XMM is 426 * set in fUse. 1:1 indexes. */ 427 uint8_t idxXmmReg; 428 /** Segment register index (DISSELREG_XXX), applicable if DISUSE_REG_SEG is 429 * set in fUse. */ 430 uint8_t idxSegReg; 431 /** Test register, TR0-TR7, present on early IA32 CPUs, applicable if 432 * DISUSE_REG_TEST is set in fUse. No index defines for these. */ 433 uint8_t idxTestReg; 434 /** Control register index (DISCREG_XXX), applicable if DISUSE_REG_CR is 435 * set in fUse. 1:1 indexes. */ 436 uint8_t idxCtrlReg; 437 /** Debug register index (DISDREG_XXX), applicable if DISUSE_REG_DBG is 438 * set in fUse. 1:1 indexes. */ 439 uint8_t idxDbgReg; 440 } Base; 428 441 /** The SIB index register meaning, applicable if DISUSE_INDEX is 429 442 * set in fUse. */ … … 438 451 /** Parameter size. */ 439 452 uint8_t cb; 453 /** Copy of the corresponding DISOPCODE::fParam1 / DISOPCODE::fParam2 / 454 * DISOPCODE::fParam3. */ 455 uint32_t fParam; 440 456 } DISOPPARAM; 441 457 AssertCompileSize(DISOPPARAM, 32);
Note:
See TracChangeset
for help on using the changeset viewer.