- Timestamp:
- Nov 6, 2016 7:15:01 PM (8 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
-
include/VBox/vmm/dbgf.h (modified) (1 diff)
-
src/VBox/Debugger/testcase/tstDBGCStubs.cpp (modified) (1 diff)
-
src/VBox/VMM/VMMR3/DBGFR3Flow.cpp (modified) (4 diffs)
-
src/VBox/VMM/VMMR3/VMMR3.def (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/vmm/dbgf.h
r64589 r64590 2615 2615 VMMR3DECL(uint32_t) DBGFR3FlowBranchTblGetSlots(DBGFFLOWBRANCHTBL hFlowBranchTbl); 2616 2616 VMMR3DECL(PDBGFADDRESS) DBGFR3FlowBranchTblGetStartAddress(DBGFFLOWBRANCHTBL hFlowBranchTbl, PDBGFADDRESS pAddrStart); 2617 VMMR3DECL(PDBGFADDRESS) DBGFR3FlowBranchTblGetAddrAtSlot(DBGFFLOWBRANCHTBL hFlowBranchTbl, uint32_t idxSlot, PDBGFADDRESS pAddrSlot); 2617 2618 VMMR3DECL(int) DBGFR3FlowBranchTblQueryAddresses(DBGFFLOWBRANCHTBL hFlowBranchTbl, PDBGFADDRESS paAddrs, uint32_t cAddrs); 2618 2619 -
trunk/src/VBox/Debugger/testcase/tstDBGCStubs.cpp
r64589 r64590 492 492 return NULL; 493 493 } 494 VMMR3DECL(PDBGFADDRESS) DBGFR3FlowBranchTblGetAddrAtSlot(DBGFFLOWBRANCHTBL hFlowBranchTbl, uint32_t idxSlot, PDBGFADDRESS pAddrSlot) 495 { 496 return NULL; 497 } 494 498 VMMR3DECL(int) DBGFR3FlowBranchTblQueryAddresses(DBGFFLOWBRANCHTBL hFlowBranchTbl, PDBGFADDRESS paAddrs, uint32_t cAddrs) 495 499 { -
trunk/src/VBox/VMM/VMMR3/DBGFR3Flow.cpp
r64589 r64590 1524 1524 1525 1525 /** 1526 * Returns the number of branch tables inside the control flow graph. 1527 * 1528 * @returns Number of basic blocks. 1529 * @param hFlow The control flow graph handle. 1530 */ 1531 VMMR3DECL(uint32_t) DBGFR3FlowGetBranchTblCount(DBGFFLOW hFlow) 1532 { 1533 PDBGFFLOWINT pThis = hFlow; 1534 AssertPtrReturn(pThis, 0); 1535 1536 return pThis->cBranchTbls; 1537 } 1538 1539 1540 /** 1526 1541 * Retains the basic block handle. 1527 1542 * … … 1596 1611 * 1597 1612 * @returns Pointer to DBGF adress containing the branch address of the basic block. 1598 * @param hFlowBb The basic block handle.1613 * @param hFlowBb The basic block handle. 1599 1614 * @param pAddrTarget Where to store the branch address of the basic block. 1600 1615 * 1601 1616 * @note This is only valid for unconditional or conditional branches and will assert 1602 1617 * for every other basic block type. 1618 * @note For indirect unconditional branches using a branch table this will return the start address 1619 * of the branch table. 1603 1620 */ 1604 1621 VMMR3DECL(PDBGFADDRESS) DBGFR3FlowBbGetBranchAddress(DBGFFLOWBB hFlowBb, PDBGFADDRESS pAddrTarget) … … 1608 1625 AssertPtrReturn(pAddrTarget, NULL); 1609 1626 AssertReturn( pFlowBb->enmEndType == DBGFFLOWBBENDTYPE_UNCOND_JMP 1610 || pFlowBb->enmEndType == DBGFFLOWBBENDTYPE_COND, 1627 || pFlowBb->enmEndType == DBGFFLOWBBENDTYPE_COND 1628 || pFlowBb->enmEndType == DBGFFLOWBBENDTYPE_UNCOND_INDIRECT_JMP, 1611 1629 NULL); 1612 1630 1613 *pAddrTarget = pFlowBb->AddrTarget; 1631 if ( pFlowBb->enmEndType == DBGFFLOWBBENDTYPE_UNCOND_INDIRECT_JMP 1632 && pFlowBb->pFlowBranchTbl) 1633 *pAddrTarget = pFlowBb->pFlowBranchTbl->AddrStart; 1634 else 1635 *pAddrTarget = pFlowBb->AddrTarget; 1614 1636 return pAddrTarget; 1615 1637 } … … 1919 1941 *pAddrStart = pFlowBranchTbl->AddrStart; 1920 1942 return pAddrStart; 1943 } 1944 1945 1946 /** 1947 * Returns one address in the branch table at the given slot index. 1948 * 1949 * @return Pointer to the address at the given slot in the given branch table. 1950 * @param hFlowBranchTbl The branch table handle. 1951 * @param idxSlot The slot the address should be returned from. 1952 * @param pAddrSlot Where to store the address. 1953 */ 1954 VMMR3DECL(PDBGFADDRESS) DBGFR3FlowBranchTblGetAddrAtSlot(DBGFFLOWBRANCHTBL hFlowBranchTbl, uint32_t idxSlot, PDBGFADDRESS pAddrSlot) 1955 { 1956 PDBGFFLOWBRANCHTBLINT pFlowBranchTbl = hFlowBranchTbl; 1957 AssertPtrReturn(pFlowBranchTbl, NULL); 1958 AssertPtrReturn(pAddrSlot, NULL); 1959 AssertReturn(idxSlot < pFlowBranchTbl->cSlots, NULL); 1960 1961 *pAddrSlot = pFlowBranchTbl->aAddresses[idxSlot]; 1962 return pAddrSlot; 1921 1963 } 1922 1964 -
trunk/src/VBox/VMM/VMMR3/VMMR3.def
r64589 r64590 157 157 DBGFR3FlowBranchTblGetSlots 158 158 DBGFR3FlowBranchTblGetStartAddress 159 DBGFR3FlowBranchTblGetAddrAtSlot 159 160 DBGFR3FlowBranchTblQueryAddresses 160 161 DBGFR3FlowItCreate
Note:
See TracChangeset
for help on using the changeset viewer.

