Jiayang Liu
bef8d2d020
Add a lock to NSSContext to fix data race
...
BUG=crbug/466784
R=juberti@webrtc.org , tommi@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/44669005
Cr-Commit-Position: refs/heads/master@{#8871}
2015-03-26 21:38:53 +00:00
tommi@webrtc.org
c7157da599
Use atomic operations for setting/reading the trace filter.
...
The filter is currently being set and read by a number of threads and tripping up tsan.
Original review: https://webrtc-codereview.appspot.com/47609004/
R=mflodman@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/47659004
Cr-Commit-Position: refs/heads/master@{#8789}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8789 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-03-19 09:30:45 +00:00
tommi@webrtc.org
25819b8294
Revert 8753 "Use atomic operations for setting/reading the trace..."
...
Caused VP9 test to fail on TSAN and doesn't build in some configuration due to
"../webrtc/base/criticalsection.h:181:12: error: cannot compile this atomic library call yet"
:-(
> Use atomic operations for setting/reading the trace filter.
> The filter is currently being set and read by a number of threads and tripping up tsan.
>
> R=mflodman@webrtc.org
> BUG=
>
> Review URL: https://webrtc-codereview.appspot.com/47609004
TBR=tommi@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/51369004
Cr-Commit-Position: refs/heads/master@{#8759}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8759 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-03-17 15:35:41 +00:00
tommi@webrtc.org
c383c24c2b
Use atomic operations for setting/reading the trace filter.
...
The filter is currently being set and read by a number of threads and tripping up tsan.
R=mflodman@webrtc.org
BUG=
Review URL: https://webrtc-codereview.appspot.com/47609004
Cr-Commit-Position: refs/heads/master@{#8753}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8753 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-03-17 13:47:16 +00:00
tommi@webrtc.org
a32f064e97
Fix build configuration bug with debug builds.
...
The problem we were running into on the Mac 10.9 debug bot in Chrome turned out to be good ol'fashion memory corruption. Part of webrtc was being compiled with _DEBUG, another half without it. This caused the definition of some symbols to be out of sync (notably pthread_mutex_t) and would cause code built from common.gypi, to overwrite memory allocated via common types from base/base.gypi derived code. Fun stuff to track down. This was a problem in particular with base/criticalsection.h since it's inlined into multiple object files but will have different definitions of what a mutex is.
TBR=pbos,kjellander
BUG=
Review URL: https://webrtc-codereview.appspot.com/43659004
Cr-Commit-Position: refs/heads/master@{#8646}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8646 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-03-08 07:39:22 +00:00
tommi@webrtc.org
679d2f1352
Disable CS_TRACK_OWNER on Mac in debug mode.
...
Local testing indicates that the pthread_t member variable might be causing alignment problems on the Chromium bots. After landing this (and once the Chromium tree is open again), I'll try a roll again to see if this has an effect.
R=magjed@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/48449004
Cr-Commit-Position: refs/heads/master@{#8644}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8644 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-03-07 20:15:24 +00:00
tommi@webrtc.org
4a4e688438
Remove dependecy on win32.h in criticalsection.h. This was causing build errors that we haven't fully figured out yet but somehow this caused override files to include the files they're supposed to override, which in turn included webrtc build files that then conflict with Chromium's configuration.
...
TBR=magjed@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/45479004
Cr-Commit-Position: refs/heads/master@{#8601}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8601 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-03-04 20:10:37 +00:00
tommi@webrtc.org
d31250518a
Test to try to track down the alignment problem on Mac 10.9.
...
There's no code change here, I'm rearranging member variables of the
trace class and adding a sizeof check to the CriticalSection
class + alignment attribute for the mutex, on Mac only.
TBR=pbos@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/38339004
Cr-Commit-Position: refs/heads/master@{#8540}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8540 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-02-28 00:01:56 +00:00
magjed@webrtc.org
a43fce6e02
Add functions rtc::AtomicOps::Load and rtc::RefCountedObject::HasOneRef
...
R=tommi@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/40819005
Cr-Commit-Position: refs/heads/master@{#8452}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8452 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-02-21 13:23:46 +00:00
tommi@webrtc.org
04cd466bd5
Move ThreadChecker into rtc_base_approved.
...
To do this, I'm removing ThreadChecker's dependency on the 'Thread' class, so that the checker works with any thread and doesn't rely on TLS.
Also simplifying CriticalSection's implementation on Windows since a critical section on Windows already knows what thread currently owns the lock.
BUG=
R=mflodman@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/40539004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8151 4adac7df-926f-26a2-2b94-8c16560cd09d
2015-01-26 15:27:29 +00:00
pbos@webrtc.org
d60d79a145
Thread annotation of rtc::CriticalSection.
...
Effectively re-lands r5516 which was reverted because talk/-only
checkouts existed. This now resides in webrtc/base/, so no talk/-only
checkouts should be possible.
This change also enables -Wthread-safety for talk/ and fixes a bug in
talk/media/webrtc/webrtcvideoengine2.cc where a guarded variable was
read without taking the corresponding lock.
R=andresp@webrtc.org , mflodman@webrtc.org , pthatcher@webrtc.org
BUG=
Review URL: https://webrtc-codereview.appspot.com/27569004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7284 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-09-24 07:10:57 +00:00
henrike@webrtc.org
f048872e91
Adds a modified copy of talk/base to webrtc/base. It is the first step in
...
migrating talk/base to webrtc/base.
BUG=N/A
R=niklas.enbom@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/17479005
git-svn-id: http://webrtc.googlecode.com/svn/trunk@6129 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-05-13 18:00:26 +00:00
perkj@webrtc.org
e9a604accd
Revert 6107 "Adds a modified copy of talk/base to webrtc/base. I..."
...
This breaks Chromium FYI builds and prevent roll of webrtc/libjingle to Chrome.
http://chromegw.corp.google.com/i/chromium.webrtc.fyi/builders/Win%20Builder/builds/457
> Adds a modified copy of talk/base to webrtc/base. It is the first step in migrating talk/base to webrtc/base.
>
> BUG=N/A
> R=andrew@webrtc.org , wu@webrtc.org
>
> Review URL: https://webrtc-codereview.appspot.com/12199004
TBR=henrike@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/14479004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@6116 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-05-13 08:15:48 +00:00
henrike@webrtc.org
2c7d1b39b9
Adds a modified copy of talk/base to webrtc/base. It is the first step in migrating talk/base to webrtc/base.
...
BUG=N/A
R=andrew@webrtc.org , wu@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/12199004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@6107 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-05-12 18:03:09 +00:00