Changeset 88673 in vbox for trunk/src/VBox/Devices/Audio/DevSB16.cpp
- Timestamp:
- Apr 23, 2021 12:42:47 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DevSB16.cpp
r88653 r88673 276 276 uint8_t mixer_nreg; 277 277 uint8_t mixer_regs[256]; 278 279 #ifdef VBOX_WITH_STATISTICS 280 STAMPROFILE StatTimerIO; 281 STAMCOUNTER StatBytesRead; 282 #endif 278 283 } SB16STATE; 279 284 … … 1643 1648 } 1644 1649 1650 STAM_REL_COUNTER_ADD(&pThis->StatBytesRead, copy); 1651 1645 1652 uint32_t cbWritten; 1646 1653 int rc = sb16WriteAudio(pThis, pStream, uChannel, off, cb, copy, &cbWritten); … … 1712 1719 static DECLCALLBACK(void) sb16TimerIO(PPDMDEVINS pDevIns, TMTIMERHANDLE hTimer, void *pvUser) 1713 1720 { 1721 RT_NOREF(pvUser); 1722 1714 1723 PSB16STATE pThis = PDMDEVINS_2_DATA(pDevIns, PSB16STATE); 1715 Assert(hTimer == pThis->hTimerIO); RT_NOREF(pvUser); 1724 STAM_PROFILE_START(&pThis->StatTimerIO, a); 1725 Assert(hTimer == pThis->hTimerIO); 1716 1726 1717 1727 uint64_t cTicksNow = PDMDevHlpTimerGet(pDevIns, hTimer); … … 1743 1753 PDMDevHlpTimerSet(pDevIns, hTimer, cTicksNow + cTicks); 1744 1754 } 1755 1756 STAM_PROFILE_STOP(&pThis->StatTimerIO, a); 1745 1757 } 1746 1758 … … 2887 2899 } 2888 2900 #endif 2901 2902 /* 2903 * Register statistics. 2904 */ 2905 # ifdef VBOX_WITH_STATISTICS 2906 PDMDevHlpSTAMRegister(pDevIns, &pThis->StatTimerIO, STAMTYPE_PROFILE, "Timer", STAMUNIT_TICKS_PER_CALL, "Profiling sb16TimerIO."); 2907 PDMDevHlpSTAMRegister(pDevIns, &pThis->StatBytesRead, STAMTYPE_COUNTER, "BytesRead", STAMUNIT_BYTES, "Bytes read from SB16 emulation."); 2908 # endif 2889 2909 2890 2910 return VINF_SUCCESS;
Note:
See TracChangeset
for help on using the changeset viewer.