Changing to using strategy classes rather than having two different
derived classes of BitrateControllerImpl. This enables run-time switching
of the strategy, which is now possible through a new API. The reason is
that it must fit the current design of ViE.
BUG=2436
R=stefan@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/2789004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5028 4adac7df-926f-26a2-2b94-8c16560cd09d
1) Change AsyncSocket's SignalReadEvent and SignalWriteEvent's thread mode to multi_threaded_local as they can be accessed from different threads.
2) Protect NATServer::TransEntry::whitelist.
3) Protect PhysicalSocket:error_.
Detail failures can be seen from issue 2080, comment #5.
TBR=fischman@webrtc.org
RISK=P1
TEST=try bots and tsanv2
BUG=2080
Review URL: https://webrtc-codereview.appspot.com/2669005
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5026 4adac7df-926f-26a2-2b94-8c16560cd09d
This CL fixes the problem with voe_auto_test extended-codec test, as well as
extended-file test. First problem was that Opus was not added as a special case, like the other codecs, and the second problem was that the tests were not updated when test files were moved to the resources catalogue.
There are still some tests that fails. Here is a list of all extended tests and their status:
Base: fails - the reason seem to be that external transport has been removed.
CallReport: passes
Codec: passes (with this CL)
DTMF: passes
Encryption: fails or is dissabled?
VoEExternalMedia: passes
File: passes (with this CL)
Hardware: passes
NetEqStats: empty?
Network: passes
RTP_RTCP: fails
VideoSync: fails
VolumeControl: passes
BUG=issue2234
R=andrew@webrtc.org, henrika@webrtc.org, xians@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/2023004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5020 4adac7df-926f-26a2-2b94-8c16560cd09d
1) init start_time_ns_ before the file_read_thread_ is started to avoid data racing as the start_time_ns_ will also be read by the file_read_thread_.
2) add CriticalSection to protect |finished_| that is accessed by FileReadThread and the main thread
Also remove the suppression for filemediaengine.cc, which has already been fixed in other cl.
TBR=henrike@webrtc.org
TEST=try bots and manual tsan v2 test
BUG=2078
Review URL: https://webrtc-codereview.appspot.com/2509004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5018 4adac7df-926f-26a2-2b94-8c16560cd09d
Today, our tryjobs default to run on all trybots since
we don't have any default list configured in PRESUBMIT.py.
Because of this, the --testfilter argument doesn't work
unless you also specify --bot when sending the tryjob.
With this CL, it is possible to use --testfilter without
--bot.
It also gets the benefit of excluding unnecessary bots
when doing platform-specific changes.
Most of the code is copied from Chromium's src/PRESUBMIT.py:
https://code.google.com/p/chromium/codesearch#chromium/src/PRESUBMIT.py&l=1030
TEST=tested submitting a tryjob with git try -t compile.
BUG=none
R=andrew@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/2619004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5016 4adac7df-926f-26a2-2b94-8c16560cd09d
Analogous to the recent libjingle change: http://cl/54929753-p10.
This supports scoped_ptr<T[]> and scoped_ptr<C, FreeDeleter> rather
than scoped_array and scoped_ptr_malloc respectively.
- Add Chromium's template-based COMPILE_ASSERT. We didn't have this
previously in order to support the macro in C. Instead, move the
existing macro to compile_assert_c.h.
- Additionally copy the move.h and template_util.h depedencies and add
the WARN_UNUSED_RESULT macro.
- Leave scoped_array and scoped_ptr_malloc for now, but mark as
deprecated.
- Remove scoped_ptr foo(NULL) use. The default constructor handles it.
- Remove the now redundant COMPILE_ASSERT from peerconnection_jni.cc.
- Add a CHECK_ARRAY_SIZE macro to rtp_format_vp8_unittest.cc to remove
some repeated code.
TESTED=trybots
R=pbos@webrtc.org, tommi@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/2449005
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5015 4adac7df-926f-26a2-2b94-8c16560cd09d
This CL implements an alternative to the bitrate clamping that is done
in BitrateControllerImpl. The default behavior is unchanged, but if
the new algorithm is enabled the behavior is as follows:
When the new bitrate is lower than the sum of min bitrates, the
algorithm will give each observer up to its min bitrate, one
observer at a time, until the bitrate budget is depleted. Thus,
with this change, some observers may get less than their min bitrate,
or even zero.
Unit tests are implemented.
Also fixing two old lint warnings in the affected files.
This change is related to the auto-muter feature.
BUG=2436
R=stefan@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/2439005
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5007 4adac7df-926f-26a2-2b94-8c16560cd09d
If frames were delivered within the same millisecond as VideoCaptureImpl
was created, or the timestamp weren't granular enough then the first
frame would be mistakenly dropped because of having the same timestamp
as a previous one, even though there was no previous one.
BUG=
R=mflodman@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/2599004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@5004 4adac7df-926f-26a2-2b94-8c16560cd09d
Update Thread documentation, fix all subclasses that had a problem.
This is to avoid a data racing between the destructor modifying the vtable, and
Thread::PreRun calling virtual method Run at the same time.
For example:
[ RUN ] FileMediaEngineTest.TestGetCapabilities
==================
WARNING: ThreadSanitizer: data race on vptr (ctor/dtor vs virtual call) (pid=2967)
Read of size 8 at 0x7d480000bd00 by thread T1:
#0 talk_base::Thread::PreRun(void*) /mnt/data/b/build/slave/Linux_Tsan_v2/build/src/out/Release/../../talk/base/thread.cc:353 (libjingle_media_unittest+0x000000234da8)
Previous write of size 8 at 0x7d480000bd00 by main thread:
#0 talk_base::Thread::~Thread() /mnt/data/b/build/slave/Linux_Tsan_v2/build/src/out/Release/../../talk/base/thread.cc:158 (libjingle_media_unittest+0x00000023478c)
#1 ~RtpSenderReceiver /mnt/data/b/build/slave/Linux_Tsan_v2/build/src/out/Release/../../talk/media/base/filemediaengine.cc:122 (libjingle_media_unittest+0x0000001b551f)
...
RISK=P2
TESTED=try bots and tsan
BUG=2078,2080
R=fischman@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/2428004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@4999 4adac7df-926f-26a2-2b94-8c16560cd09d
In r4966 this was disabled on Linux for WebRTC code in order to detect any new unused const variables.
This CL does the same for Mac.
BUG=none
TEST=added an unused const and verified compilation fails
when this patch is applied. Mac trybots passing as well.
R=andrew@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/2459004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@4997 4adac7df-926f-26a2-2b94-8c16560cd09d
Turns out I was running libjingle_unittest
instead of libjingle_peerconnection_unittest
on the bot machine when I was verifying the
suppressions added in r4991 on the bot.
This will hopefully be the last round.
BUG=2528
TEST=running libjingle_unittest with these
suppressions applied locally on the bot.
TBR=phoglund@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/2426004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@4993 4adac7df-926f-26a2-2b94-8c16560cd09d
Since we don't have a trybot for LSan, this is the only
way to resolve errors only happening on the bots
(except running at the bot themselves).
I suspect some errors only occurs on the bots since
the compiler version differs (4.6 on bots, 4.6.3 on
my machine).
This last suppressions round was tested on an actual
Chrome infra VM as well, with no errors.
BUG=2528
TEST=ran successfully on the bot.
TBR=phoglund@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/2424004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@4991 4adac7df-926f-26a2-2b94-8c16560cd09d
The suppressions in r4988 were not enough to green
up the LSan+ASan bot.
Here's another round of suppressions to get the bot green
which I have tested multiple runs without any leaks reported.
BUG=2527,2528
TEST=
GYP_DEFINES='asan=1 lsan=1 linux_use_tcmalloc=0 release_extra_cflags="-gline-tables-only"' gclient runhooks
ninja -C out/Release libjingle_unittest
export ASAN_SYMBOLIZER_PATH=`(pwd)`/third_party/llvm-build/Release+Asserts/bin/llvm-symbolizer
export ASAN_OPTIONS="detect_leaks=1 strict_memcmp=0"
export LSAN_OPTIONS="suppressions=tools/lsan/suppressions.txt"
out/Release/libjingle_peerconnection_unittest
out/Release/libjingle_unittest
TBR=phoglund@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/2422004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@4990 4adac7df-926f-26a2-2b94-8c16560cd09d
Add suppressions for libjingle tests so they pass under TSan v2.
Disable the following tests for TSan v2 (only) since they're failing:
* StunServerTest.TestGood
* JsepPeerConnectionP2PTestClient.*
See build logs at:
http://build.chromium.org/p/client.webrtc.fyi/builders/Linux%20Tsan%20v2/
for more details.
BUG=1205,2078,2079,2080,2517
TEST=Ran a successful run of each test locally on Linux using:
GYP_DEFINES='tsan=1 linux_use_tcmalloc=0 release_extra_cflags="-gline-tables-only"' gclient runhooks
ninja -C out/Release
For each test, run standing in trunk/:
TSAN_OPTIONS="suppressions=tools/valgrind-webrtc/tsan_v2/suppressions.txt print_suppressions=1 report_signal_unsafe=0 report_thread_leaks=0 history_size=7" out/Release/[libjingle_testname]
R=wu@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/2411004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@4977 4adac7df-926f-26a2-2b94-8c16560cd09d