Fix NetEq performance test regression
The test code created an AudioBuffer object inside the work loop. This turned out to be expensive, since the AudioBuffer ctor implicitly called memset on all of the audio data array. The obvious remedy is to create the buffer outside of the loop. This does not have any impact apart from the performance boost, since the output data from NetEq is not even considered in the test. BUG=chromium:592907,webrtc:5647 TBR=ivoc@webrtc.org NOTRY=true Review URL: https://codereview.webrtc.org/1782803002 Cr-Commit-Position: refs/heads/master@{#11940}
This commit is contained in:
committed by
Commit bot
parent
9cbebee523
commit
d72595eeea
@ -541,6 +541,8 @@ class AudioFrame {
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(AudioFrame);
|
||||
};
|
||||
|
||||
// TODO(henrik.lundin) Can we remove the call to data_()?
|
||||
// See https://bugs.chromium.org/p/webrtc/issues/detail?id=5647.
|
||||
inline AudioFrame::AudioFrame()
|
||||
: data_() {
|
||||
Reset();
|
||||
|
||||
Reference in New Issue
Block a user