Update fifo's trace to log relevant information
`Push` and `Pull` methods already log `this` pointer. The same information has been added `PullAndUpdateEarmark` method. This is a great way to follow producer and consumer threads on complex scenarios. In addition to that, the value of `earmark_frames_` has been added in the logs of the corresponding method to help the readability of the logs. R=hongchan Bug: None Change-Id: Ie99209aee3cadce1e179b831e411eb772c6f9505 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2883807 Reviewed-by: Hongchan Choi <hongchan@chromium.org> Commit-Queue: Hongchan Choi <hongchan@chromium.org> Cr-Commit-Position: refs/heads/master@{#881658}
This commit is contained in:

committed by
Chromium LUCI CQ

parent
43decd4b24
commit
4620d9ca6a
1
AUTHORS
1
AUTHORS
@ -42,6 +42,7 @@ Akos Kiss <akiss@inf.u-szeged.hu>
|
||||
Aku Kotkavuo <a.kotkavuo@partner.samsung.com>
|
||||
Aldo Culquicondor <alculquicondor@gmail.com>
|
||||
Aleksandar Stojiljkovic <aleksandar.stojiljkovic@intel.com>
|
||||
Alex Chronopoulos <achronop@gmail.com>
|
||||
Alex Gabriel <minilogo@gmail.com>
|
||||
Alex Gartrell <agartrell@cmu.edu>
|
||||
Alex Gaynor <alex.gaynor@gmail.com>
|
||||
|
@ -213,16 +213,15 @@ size_t PushPullFIFO::Pull(AudioBus* output_bus, size_t frames_requested) {
|
||||
|
||||
size_t PushPullFIFO::PullAndUpdateEarmark(AudioBus* output_bus,
|
||||
size_t frames_requested) {
|
||||
TRACE_EVENT2("webaudio",
|
||||
"PushPullFIFO::PullAndUpdateEarmark",
|
||||
"frames_requested", frames_requested,
|
||||
"pull_count_", pull_count_);
|
||||
TRACE_EVENT2("webaudio", "PushPullFIFO::PullAndUpdateEarmark", "this",
|
||||
static_cast<void*>(this), "frames_requested", frames_requested);
|
||||
|
||||
CHECK(output_bus);
|
||||
SECURITY_CHECK(frames_requested <= output_bus->length());
|
||||
|
||||
MutexLocker locker(lock_);
|
||||
TRACE_EVENT0("webaudio", "PushPullFIFO::PullAndUpdateEarmark (under lock)");
|
||||
TRACE_EVENT2("webaudio", "PushPullFIFO::PullAndUpdateEarmark (under lock)",
|
||||
"pull_count_", pull_count_, "earmark_frames_", earmark_frames_);
|
||||
|
||||
SECURITY_CHECK(frames_requested <= fifo_length_);
|
||||
SECURITY_CHECK(index_read_ < fifo_length_);
|
||||
|
Reference in New Issue
Block a user