Changeset 90013 in vbox for trunk/src/VBox/Devices
- Timestamp:
- Jul 4, 2021 9:10:00 PM (3 years ago)
- Location:
- trunk/src/VBox/Devices/Audio
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DevHdaStream.cpp
r90012 r90013 86 86 AssertPtr(pStreamR3->pHDAStateR3->pDevIns); 87 87 88 # ifdef DEBUG89 int rc = RTCritSectInit(&pStreamR3->Dbg.CritSect);90 AssertRCReturn(rc, rc);91 # endif92 93 88 const bool fIsInput = hdaGetDirFromSD(uSD) == PDMAUDIODIR_IN; 94 89 … … 158 153 pStreamR3->State.StatDmaBufUsed = 0; 159 154 } 160 161 # ifdef DEBUG162 if (RTCritSectIsInitialized(&pStreamR3->Dbg.CritSect))163 {164 rc2 = RTCritSectDelete(&pStreamR3->Dbg.CritSect);165 AssertRC(rc2);166 }167 # endif168 155 169 156 if (pStreamR3->Dbg.Runtime.fEnabled) … … 1011 998 pStreamShared->State.offWrite = 0; 1012 999 pStreamShared->State.offRead = 0; 1013 1014 # ifdef DEBUG1015 pStreamR3->Dbg.cReadsTotal = 0;1016 pStreamR3->Dbg.cbReadTotal = 0;1017 pStreamR3->Dbg.tsLastReadNs = 0;1018 pStreamR3->Dbg.cWritesTotal = 0;1019 pStreamR3->Dbg.cbWrittenTotal = 0;1020 pStreamR3->Dbg.cWritesHz = 0;1021 pStreamR3->Dbg.cbWrittenHz = 0;1022 pStreamR3->Dbg.tsWriteSlotBegin = 0;1023 # endif1024 1000 1025 1001 /* Report that we're done resetting this stream. */ -
trunk/src/VBox/Devices/Audio/DevHdaStream.h
r89887 r90013 54 54 /** Runtime debug info. */ 55 55 HDASTREAMDEBUGRT Runtime; 56 #ifdef DEBUG57 /** Critical section to serialize access if needed. */58 RTCRITSECT CritSect;59 uint32_t Padding0[2];60 /** Number of total read accesses. */61 uint64_t cReadsTotal;62 /** Number of total DMA bytes read. */63 uint64_t cbReadTotal;64 /** Timestamp (in ns) of last read access. */65 uint64_t tsLastReadNs;66 /** Number of total write accesses. */67 uint64_t cWritesTotal;68 /** Number of total DMA bytes written. */69 uint64_t cbWrittenTotal;70 /** Number of total write accesses since last iteration (Hz). */71 uint64_t cWritesHz;72 /** Number of total DMA bytes written since last iteration (Hz). */73 uint64_t cbWrittenHz;74 /** Timestamp (in ns) of beginning a new write slot. */75 uint64_t tsWriteSlotBegin;76 /** Number of current silence samples in a (consecutive) row. */77 uint64_t csSilence;78 /** Number of silent samples in a row to consider an audio block as audio gap (silence). */79 uint64_t cSilenceThreshold;80 /** How many bytes to skip in an audio stream before detecting silence.81 * (useful for intros and silence at the beginning of a song). */82 uint64_t cbSilenceReadMin;83 #else84 56 uint64_t au64Alignment[2]; 85 #endif86 57 } HDASTREAMDEBUG; 87 58
Note:
See TracChangeset
for help on using the changeset viewer.