• Home
  • Raw
  • Download

Lines Matching full:mutex

11 class LOCKABLE Mutex {  class
26 const Mutex& operator!() const { return *this; } in operator !()
34 MutexLock(Mutex *mu) EXCLUSIVE_LOCK_FUNCTION(mu);
35 MutexLock(Mutex *mu, bool adopt) EXCLUSIVE_LOCKS_REQUIRED(mu);
41 ReaderMutexLock(Mutex *mu) SHARED_LOCK_FUNCTION(mu);
42 ReaderMutexLock(Mutex *mu, bool adopt) SHARED_LOCKS_REQUIRED(mu);
48 ReleasableMutexLock(Mutex *mu) EXCLUSIVE_LOCK_FUNCTION(mu);
56 DoubleMutexLock(Mutex *mu1, Mutex *mu2) EXCLUSIVE_LOCK_FUNCTION(mu1, mu2);
126 Mutex sls_mu;
128 Mutex sls_mu2 __attribute__((acquired_after(sls_mu)));
136 Mutex mu;
238 // expected-warning{{releasing mutex 'sls_mu' that was not held}} in sls_fun_bad_1()
242 sls_mu.Lock(); // expected-note{{mutex acquired here}} in sls_fun_bad_2()
244 // expected-warning{{acquiring mutex 'sls_mu' that is already held}} in sls_fun_bad_2()
249 sls_mu.Lock(); // expected-note {{mutex acquired here}} in sls_fun_bad_3()
250 } // expected-warning{{mutex 'sls_mu' is still held at the end of function}} in sls_fun_bad_3()
254 sls_mu.Lock(); // expected-note{{mutex acquired here}} in sls_fun_bad_4()
256 sls_mu2.Lock(); // expected-note{{mutex acquired here}} in sls_fun_bad_4()
257 } // expected-warning{{mutex 'sls_mu' is not held on every path through here}} \ in sls_fun_bad_4()
258 // expected-warning{{mutex 'sls_mu2' is not held on every path through here}}
261 sls_mu.Lock(); // expected-note {{mutex acquired here}} in sls_fun_bad_5()
264 } // expected-warning{{mutex 'sls_mu' is not held on every path through here}} in sls_fun_bad_5()
268 sls_mu.Lock(); // expected-note {{mutex acquired here}} in sls_fun_bad_6()
277 expected-warning{{mutex 'sls_mu' is not held on every path through here}}\ in sls_fun_bad_6()
278 expected-warning{{releasing mutex 'sls_mu' that was not held}} in sls_fun_bad_6()
288 expected-warning{{expecting mutex 'sls_mu' to be held at start of each loop}} in sls_fun_bad_7()
291 sls_mu.Lock(); // expected-note {{mutex acquired here}} in sls_fun_bad_7()
297 sls_mu.Lock(); // expected-note{{mutex acquired here}} in sls_fun_bad_8()
300 … sls_mu.Unlock(); // expected-warning{{expecting mutex 'sls_mu' to be held at start of each loop}} in sls_fun_bad_8()
307 // expected-warning{{expecting mutex 'sls_mu' to be held at start of each loop}} \ in sls_fun_bad_9()
308 // expected-note{{mutex acquired here}} in sls_fun_bad_9()
314 sls_mu.Lock(); // expected-note 2{{mutex acquired here}} in sls_fun_bad_10()
315 …while(getBool()) { // expected-warning{{expecting mutex 'sls_mu' to be held at start of each loop… in sls_fun_bad_10()
318 } // expected-warning{{mutex 'sls_mu' is still held at the end of function}} in sls_fun_bad_10()
322 expected-warning{{expecting mutex 'sls_mu' to be held at start of each loop}} in sls_fun_bad_11()
323 sls_mu.Lock(); // expected-note {{mutex acquired here}} in sls_fun_bad_11()
326 // expected-warning{{releasing mutex 'sls_mu' that was not held}} in sls_fun_bad_11()
330 sls_mu.Lock(); // expected-note {{mutex acquired here}} in sls_fun_bad_12()
335 break; // expected-warning{{mutex 'sls_mu' is not held on every path through here}} in sls_fun_bad_12()
347 Mutex aa_mu;
364 // expected-warning{{releasing mutex 'aa_mu' that was not held}} in aa_fun_bad_1()
368 glock.globalLock(); // expected-note{{mutex acquired here}} in aa_fun_bad_2()
370 // expected-warning{{acquiring mutex 'aa_mu' that is already held}} in aa_fun_bad_2()
375 glock.globalLock(); // expected-note{{mutex acquired here}} in aa_fun_bad_3()
376 } // expected-warning{{mutex 'aa_mu' is still held at the end of function}} in aa_fun_bad_3()
382 Mutex wmu;
388 wmu.Lock(); // EXPECTED-NOTE {{mutex acquired here}} in WeirdMethods()
389 } // EXPECTED-WARNING {{mutex 'wmu' is still held at the end of function}} in WeirdMethods()
391 wmu.Lock(); // EXPECTED-NOTE {{mutex acquired here}} in ~WeirdMethods()
392 } // EXPECTED-WARNING {{mutex 'wmu' is still held at the end of function}} in ~WeirdMethods()
394 wmu.Lock(); // expected-note {{mutex acquired here}} in operator ++()
395 } // expected-warning {{mutex 'wmu' is still held at the end of function}} in operator ++()
397 wmu.Lock(); // expected-note {{mutex acquired here}} in operator int*()
399 } // expected-warning {{mutex 'wmu' is still held at the end of function}} in operator int*()
416 … // expected-warning {{writing variable 'pgb_field' requires holding mutex 'sls_mu2' exclusively}} in testFoo()
417 …*pgb_field = x; // expected-warning {{reading variable 'pgb_field' requires holding mutex 'sls_mu2… in testFoo()
418 …// expected-warning {{writing the value pointed to by 'pgb_field' requires holding mutex 'sls_mu' … in testFoo()
419 …x = *pgb_field; // expected-warning {{reading variable 'pgb_field' requires holding mutex 'sls_mu2… in testFoo()
420 …// expected-warning {{reading the value pointed to by 'pgb_field' requires holding mutex 'sls_mu'}} in testFoo()
421 …(*pgb_field)++; // expected-warning {{reading variable 'pgb_field' requires holding mutex 'sls_mu2… in testFoo()
422 …// expected-warning {{writing the value pointed to by 'pgb_field' requires holding mutex 'sls_mu' … in testFoo()
432 … // expected-warning {{writing variable 'gb_field' requires holding mutex 'sls_mu' exclusively}} in testFoo()
465 // expected-warning{{writing variable 'sls_guard_var' requires holding any mutex exclusively}} in gb_bad_0()
470 // expected-warning{{reading variable 'sls_guard_var' requires holding any mutex}} in gb_bad_1()
475 …// expected-warning {{writing variable 'sls_guardby_var' requires holding mutex 'sls_mu' exclusive… in gb_bad_2()
480 // expected-warning {{reading variable 'sls_guardby_var' requires holding mutex 'sls_mu'}} in gb_bad_3()
485 …// expected-warning {{writing the value pointed to by 'pgb_gvar' requires holding any mutex exclus… in gb_bad_4()
490 // expected-warning {{reading the value pointed to by 'pgb_gvar' requires holding any mutex}} in gb_bad_5()
495 …// expected-warning {{writing the value pointed to by 'pgb_var' requires holding mutex 'sls_mu' ex… in gb_bad_6()
500 … // expected-warning {{reading the value pointed to by 'pgb_var' requires holding mutex 'sls_mu'}} in gb_bad_7()
506 // expected-warning {{writing variable 'gb_field' requires holding mutex 'sls_mu'}} in gb_bad_8()
511 // expected-warning{{writing variable 'sls_guard_var' requires holding any mutex exclusively}} in gb_bad_9()
513 // expected-warning{{writing variable 'sls_guard_var' requires holding any mutex exclusively}} in gb_bad_9()
515 // expected-warning{{writing variable 'sls_guard_var' requires holding any mutex exclusively}} in gb_bad_9()
517 // expected-warning{{writing variable 'sls_guard_var' requires holding any mutex exclusively}} in gb_bad_9()
533 // expected-warning{{writing variable 'a' requires holding mutex 'mu' exclusively}} in test()
535 // expected-warning {{reading variable 'a' requires holding mutex 'mu'}} in test()
537 // expected-warning {{writing variable 'c' requires holding mutex 'mu' exclusively}} in test()
542 Mutex mu;
550 Mutex mu1_;
551 Mutex mu;
579 // expected-warning{{writing variable 'a' requires holding mutex 'fooB.mu' exclusively}} \ in late_bad_0()
585 Mutex mu; in late_bad_1()
590 // expected-warning{{reading the value pointed to by 'q' requires holding mutex 'b1.mu'}} in late_bad_1()
600 // expected-warning{{writing variable 'a' requires holding mutex 'BarA.Foo.mu' exclusively}} \ in late_bad_2()
609 …// expected-warning{{writing variable 'a' requires holding mutex 'BarA.FooPointer->mu' exclusively… in late_bad_3()
618 // expected-warning{{writing variable 'a' requires holding mutex 'BarA.Foo2.mu' exclusively}} \ in late_bad_4()
638 // expected-warning {{mutex 'sls_mu' is acquired exclusively and shared in the same scope}} in shared_fun_1()
642 // expected-note {{the other acquisition of mutex 'sls_mu' is here}} in shared_fun_1()
668 // expected-warning {{mutex 'sls_mu' is acquired exclusively and shared in the same scope}} in shared_fun_8()
671 // expected-note {{the other acquisition of mutex 'sls_mu' is here}} in shared_fun_8()
697 // expected-warning {{mutex 'sls_mu' is acquired exclusively and shared in the same scope}} in shared_bad_0()
701 // expected-note {{the other acquisition of mutex 'sls_mu' is here}} in shared_bad_0()
709 // expected-warning {{mutex 'sls_mu' is acquired exclusively and shared in the same scope}} in shared_bad_1()
712 // expected-note {{the other acquisition of mutex 'sls_mu' is here}} in shared_bad_1()
720 // expected-warning {{mutex 'sls_mu' is acquired exclusively and shared in the same scope}} in shared_bad_2()
723 // expected-note {{the other acquisition of mutex 'sls_mu' is here}} in shared_bad_2()
729 sls_mu.Lock(); // expected-note {{mutex acquired here}} in shared_bad_3()
731 // expected-warning {{releasing mutex 'sls_mu' using shared access, expected exclusive access}} in shared_bad_3()
735 sls_mu.ReaderLock(); // expected-note {{mutex acquired here}} in shared_bad_4()
737 // expected-warning {{releasing mutex 'sls_mu' using exclusive access, expected shared access}} in shared_bad_4()
741 sls_mu.Lock(); // expected-note {{mutex acquired here}} in shared_bad_5()
743 // expected-warning {{releasing mutex 'sls_mu' using shared access, expected exclusive access}} in shared_bad_5()
748 sls_mu.ReaderLock(); // expected-note {{mutex acquired here}} in shared_bad_6()
750 // expected-warning {{releasing mutex 'sls_mu' using exclusive access, expected shared access}} in shared_bad_6()
838 // expected-warning {{calling function 'aa_elr_fun' requires holding mutex 'aa_mu' exclusively}} in es_bad_0()
844 // expected-warning {{calling function 'aa_elr_fun' requires holding mutex 'aa_mu' exclusively}} in es_bad_1()
850 // expected-warning {{calling function 'aa_elr_fun_s' requires holding mutex 'aa_mu'}} in es_bad_2()
855 // expected-warning {{calling function 'test' requires holding mutex 'sls_mu' exclusively}} in es_bad_3()
860 // expected-warning {{calling function 'testShared' requires holding mutex 'sls_mu2'}} in es_bad_4()
866 // expected-warning {{calling function 'test' requires holding mutex 'sls_mu' exclusively}} in es_bad_5()
873 // expected-warning {{cannot call function 'le_fun' while mutex 'sls_mu' is held}} in es_bad_6()
880 // expected-warning {{cannot call function 'le_fun' while mutex 'sls_mu' is held}} in es_bad_7()
908 static Mutex mu1_;
927 Mutex mu;
934 Mutex mu1_ ACQUIRED_AFTER(mu);
961 Mutex mu1;
962 Mutex mu2 ACQUIRED_AFTER(mu1);
1006 Mutex mu_;
1022 Mutex *mu_;
1047 Mutex foo_mu_;
1053 Mutex bar_mu_ ACQUIRED_AFTER(foo->foo_mu_);
1120 Mutex mu;
1126 Mutex *mu1;
1127 Mutex *mu2;
1155 Mutex mu_;
1170 Mutex mu_;
1207 Mutex mu;
1226 Mutex mu_;
1256 Mutex mu1;
1257 Mutex mu2;
1270 Mutex mu_ ACQUIRED_AFTER(mu1);
1285 x = foo(); // expected-warning {{calling function 'foo' requires holding mutex 'mu2' exclusively}} in bar()
1299 f1.bar(); // expected-warning {{cannot call function 'bar' while mutex 'f1.mu_' is held}} in main()
1305 f2->bar(); // expected-warning {{cannot call function 'bar' while mutex 'f2->mu_' is held}} in main()
1324 Mutex mu1_;
1334 // expected-warning {{writing variable 'a_' requires holding mutex 'b2->mu1_' exclusively}} \ in func()
1345 Mutex mu;
1352 Mutex mu1_ ACQUIRED_AFTER(mu);
1364 …res = b1.a_ + b3->b_; // expected-warning {{reading variable 'a_' requires holding mutex 'b1.mu1_'… in func()
1365 // expected-warning {{writing variable 'res' requires holding mutex 'mu' exclusively}} \ in func()
1367 *p = i; // expected-warning {{reading variable 'p' requires holding mutex 'mu'}} \ in func()
1368 …// expected-warning {{writing the value pointed to by 'p' requires holding mutex 'mu' exclusively}} in func()
1369 b1.a_ = res + b3->b_; // expected-warning {{reading variable 'res' requires holding mutex 'mu'}} \ in func()
1370 // expected-warning {{writing variable 'a_' requires holding mutex 'b1.mu1_' exclusively}} \ in func()
1372 …b3->b_ = *b1.q; // expected-warning {{reading the value pointed to by 'q' requires holding mutex '… in func()
1374 b1.b_ = res; // expected-warning {{reading variable 'res' requires holding mutex 'mu'}} in func()
1375 x = res; // expected-warning {{reading variable 'res' requires holding mutex 'mu'}} in func()
1385 Mutex lock_;
1397 … // expected-warning {{calling function 'bar' requires holding mutex 'child->lock_' exclusively}} \ in Func()
1400 … // expected-warning {{writing variable 'a_' requires holding mutex 'child->lock_' exclusively}} \ in Func()
1424 Mutex lock_;
1438 …child->Func(new_foo); // expected-warning {{cannot call function 'Func' while mutex 'child->lock_'… in Func()
1464 Mutex mu1, mu2, mu3;
1477 f2(); // expected-warning {{cannot call function 'f2' while mutex 'mu1' is held}} \ in f1()
1478 // expected-warning {{cannot call function 'f2' while mutex 'mu2' is held}} in f1()
1486 …foo->f1(); // expected-warning {{calling function 'f1' requires holding mutex 'foo->mu2' exclusive… in func()
1487 … // expected-warning {{calling function 'f1' requires holding mutex 'foo->mu1' exclusively}} in func()
1497 Mutex mu_;
1510 …b->func1(); // expected-warning {{calling function 'func1' requires holding mutex 'b->mu_' exclusi… in main()
1512 b->func2(); // expected-warning {{cannot call function 'func2' while mutex 'b->mu_' is held}} in main()
1515 …c->func1(); // expected-warning {{calling function 'func1' requires holding mutex 'c->mu_' exclusi… in main()
1517 c->func2(); // expected-warning {{cannot call function 'func2' while mutex 'c->mu_' is held}} in main()
1526 Mutex mu;
1527 Mutex mu3;
1533 Mutex *mu1;
1534 Mutex *mu2;
1544 a.method1(1); // expected-warning {{calling function 'method1' requires holding mutex 'a.mu1'}} \ in main()
1545 // expected-warning {{calling function 'method1' requires holding mutex 'mu'}} \ in main()
1546 // expected-warning {{calling function 'method1' requires holding mutex 'a.mu2'}} \ in main()
1547 // expected-warning {{calling function 'method1' requires holding mutex 'mu3'}} in main()
1555 Mutex mu;
1590 dlr.lockData(d1); // expected-note {{mutex acquired here}} in bar3()
1592 // expected-warning {{releasing mutex 'd2->mu' that was not held}} in bar3()
1593 } // expected-warning {{mutex 'd1->mu' is still held at the end of function}} in bar3()
1599 // expected-warning {{calling function 'foo' requires holding mutex 'd2->mu' exclusively}} \ in bar4()
1609 Mutex fooMu;
1629 Mutex m;
1632 Mutex m;
1642 u->n = 0; // expected-warning {{reading variable 'u' requires holding mutex 'm'}} in DoNaughtyThings()
1643 return t->s->n; // expected-warning {{reading variable 's' requires holding mutex 't->m'}} in DoNaughtyThings()
1653 Mutex m;
1659 v.p->f(u); // expected-warning {{reading variable 'p' requires holding mutex 'v.m'}} in f()
1669 Mutex mu1;
1670 Mutex mu2;
1694 MutexLock mulock_a(&mu1); // expected-note{{mutex acquired here}} in foo3()
1696 // expected-warning {{acquiring mutex 'mu1' that is already held}} in foo3()
1719 Mutex mu_;
1728 …foo(); // expected-warning {{calling function 'foo' requires holding mutex 'fooObj.mu_' exclusive… in bar()
1740 Mutex mu;
1819 a = 8; // expected-warning {{writing variable 'a' requires holding mutex 'mu' exclusively}} in foo8()
1845 … a = 10; // expected-warning {{writing variable 'a' requires holding mutex 'mu' exclusively}} in foo10()
1890 if (mu.TryLock() ? 0 : 1) // expected-note{{mutex acquired here}} in foo15()
1891 mu.Unlock(); // expected-warning{{releasing mutex 'mu' that was not held}} in foo15()
1892 …} // expected-warning{{mutex 'mu' is not held on every path through here… in foo15()
1902 Mutex mu_;
1909 Mutex mu_;
1956 Mutex mu_;
1990 …nction 'barTD<TestTemplateAttributeInstantiation::Foo1>' requires holding mutex 'f1.mu_' exclusive… in test()
1999 // expected-warning {{writing variable 'data' requires holding mutex 'cell.mu_' exclusively}} in test()
2029 Mutex mu_;
2030 static Mutex static_mu_;
2054 Mutex mu_;
2068 // expected-warning {{calling function 'foo1' requires holding mutex 'myfoo.mu_' exclusively}} in test()
2078 struct LOCKABLE mutex { struct
2085 mutex m;
2094 continue; // expected-warning {{expecting mutex 'm' to be held at start of each loop}} in test()
2098 m.lock(); // expected-note {{mutex acquired here}} in test()
2121 Mutex mu_;
2130 Mutex mu_;
2183 // expected-warning {{calling function 'foo2' requires holding mutex 'myFoo.mu_' exclusively}} in test()
2185 // expected-warning {{calling function 'foo3' requires holding mutex 'myFoo.mu_' exclusively}} in test()
2187 …// expected-warning {{calling function 'fooT1<int>' requires holding mutex 'myFoo.mu_' exclusively… in test()
2190 …// expected-warning {{calling function 'fooT2<int>' requires holding mutex 'myFoo.mu_' exclusively… in test()
2193 // expected-warning {{calling function 'fooF1' requires holding mutex 'myFoo.mu_' exclusively}} in test()
2195 // expected-warning {{calling function 'fooF2' requires holding mutex 'myFoo.mu_' exclusively}} in test()
2197 // expected-warning {{calling function 'fooF3' requires holding mutex 'myFoo.mu_' exclusively}} in test()
2213 // expected-warning {{calling function 'foo' requires holding mutex 'myFooT.mu_' exclusively}} in test()
2241 // expected-warning {{writing variable 'foo' requires holding mutex 'this' exclusively}} in test()
2248 Mutex mu_;
2271 Mutex* mutex_;
2284 Mutex mu_;
2306 // expected-warning {{writing variable 'a' requires holding mutex 'mu_' exclusively}} in foo()
2308 // expected-warning {{writing variable 'b' requires holding mutex 'mu_' exclusively}} in foo()
2310 // expected-warning {{writing variable 'c' requires holding mutex 'mu_' exclusively}} in foo()
2314 Mutex mu_;
2337 Mutex mu_;
2411 …// expected-warning {{writing variable 'a' requires holding mutex 'bar.getFooey().mu_' exclusively… in test2()
2417 …// expected-warning {{writing variable 'a' requires holding mutex 'bar.getFoo2(b).mu_' exclusively… in test2()
2423 …// expected-warning {{writing variable 'a' requires holding mutex 'bar.getFoo3(a, c).mu_' exclusiv… in test2()
2429 …// expected-warning {{writing variable 'a' requires holding mutex 'getBarFoo(bar, b).mu_' exclusiv… in test2()
2435 …// expected-warning {{writing variable 'a' requires holding mutex '((0 < a) ? fooArray[b] : fooArr… in test2()
2447 Mutex mu;
2474 Mutex* getMu() LOCK_RETURNED(mu_);
2476 Mutex mu_;
2478 static Mutex* getMu(Foo* f) LOCK_RETURNED(f->mu_);
2484 …f1->a = 0; // expected-warning {{writing variable 'a' requires holding mutex 'f1->mu_' exclu… in test1()
2485 …f1->foo(); // expected-warning {{calling function 'foo' requires holding mutex 'f1->mu_' exc… in test1()
2487 …f1->foo2(f2); // expected-warning {{calling function 'foo2' requires holding mutex 'f1->mu_' ex… in test1()
2488 … // expected-warning {{calling function 'foo2' requires holding mutex 'f2->mu_' exclusively}} in test1()
2489 …Foo::sfoo(f1); // expected-warning {{calling function 'sfoo' requires holding mutex 'f1->mu_' ex… in test1()
2496 // expected-warning {{calling function 'foo2' requires holding mutex 'f2->mu_' exclusively}} \ in test1()
2509 Mutex* getFooMu(Foo* f) LOCK_RETURNED(Foo::getMu(f));
2526 …b1->b = 0; // expected-warning {{writing variable 'b' requires holding mutex 'b1->mu_' exclu… in test2()
2527 …b1->bar(); // expected-warning {{calling function 'bar' requires holding mutex 'b1->mu_' exc… in test2()
2528 …b1->bar2(b2); // expected-warning {{calling function 'bar2' requires holding mutex 'b1->mu_' ex… in test2()
2529 … // expected-warning {{calling function 'bar2' requires holding mutex 'b2->mu_' exclusively}} in test2()
2530 …Bar::sbar(b1); // expected-warning {{calling function 'sbar' requires holding mutex 'b1->mu_' ex… in test2()
2531 …Bar::sbar2(b1); // expected-warning {{calling function 'sbar2' requires holding mutex 'b1->mu_' e… in test2()
2538 // expected-warning {{calling function 'bar2' requires holding mutex 'b2->mu_' exclusively}} \ in test2()
2553 // Sanity check -- lock the mutex directly, but use attributes that call getMu()
2554 // Also lock the mutex using getFooMu, which calls a lock_returned function.
2576 Mutex mu_;
2604 a = 1; // expected-warning {{writing variable 'a' requires holding mutex 'mu_' exclusively}} in test3()
2609 rlock.Release(); // expected-note{{mutex released here}} in test4()
2610 rlock.Release(); // expected-warning {{releasing mutex 'mu_' that was not held}} in test4()
2619 rlock.Release(); // expected-warning {{releasing mutex 'mu_' that was not held}} in test5()
2632 RelockableExclusiveMutexLock(Mutex *mu) EXCLUSIVE_LOCK_FUNCTION(mu);
2633 RelockableExclusiveMutexLock(Mutex *mu, DeferTraits) LOCKS_EXCLUDED(mu);
2645 RelockableMutexLock(Mutex *mu, DeferTraits) LOCKS_EXCLUDED(mu);
2646 RelockableMutexLock(Mutex *mu, SharedTraits) SHARED_LOCK_FUNCTION(mu);
2647 RelockableMutexLock(Mutex *mu, ExclusiveTraits) EXCLUSIVE_LOCK_FUNCTION(mu);
2660 Mutex mu;
2670 x = 3; // expected-warning {{writing variable 'x' requires holding mutex 'mu' exclusively}} in relock()
2678 x = 2; // expected-warning {{writing variable 'x' requires holding mutex 'mu' exclusively}} in deferLock()
2686 x = 2; // expected-warning {{writing variable 'x' requires holding mutex 'mu' exclusively}} in relockExclusive()
2689 print(x); // expected-warning {{reading variable 'x' requires holding mutex 'mu'}} in relockExclusive()
2697 x = 5; // expected-warning {{writing variable 'x' requires holding mutex 'mu' exclusively}} in relockExclusive()
2706 print(x); // expected-warning {{reading variable 'x' requires holding mutex 'mu'}} in relockShared()
2710 x = 4; // expected-warning {{writing variable 'x' requires holding mutex 'mu' exclusively}} in relockShared()
2719 print(x); // expected-warning {{reading variable 'x' requires holding mutex 'mu'}} in deferLockShared()
2722 x = 2; // expected-warning {{writing variable 'x' requires holding mutex 'mu' exclusively}} in deferLockShared()
2727 scope.Unlock(); // expected-note{{mutex released here}} in doubleUnlock()
2728 scope.Unlock(); // expected-warning {{releasing mutex 'mu' that was not held}} in doubleUnlock()
2732 RelockableExclusiveMutexLock scope(&mu); // expected-note{{mutex acquired here}} in doubleLock1()
2733 scope.Lock(); // expected-warning {{acquiring mutex 'mu' that is already held}} in doubleLock1()
2739 scope.Lock(); // expected-note{{mutex acquired here}} in doubleLock2()
2740 scope.Lock(); // expected-warning {{acquiring mutex 'mu' that is already held}} in doubleLock2()
2769 MemberLock() EXCLUSIVE_LOCK_FUNCTION(mutex);
2770 ~MemberLock() UNLOCK_FUNCTION(mutex);
2771 void Lock() EXCLUSIVE_LOCK_FUNCTION(mutex);
2772 Mutex mutex; member in RelockableScopedLock::MemberLock
2776 MemberLock lock; // expected-note{{mutex acquired here}} in relockShared2()
2777 lock.Lock(); // expected-warning {{acquiring mutex 'lock.mutex' that is already held}} in relockShared2()
2782 Mutex *other;
2785 WeirdScope(Mutex *mutex) EXCLUSIVE_LOCK_FUNCTION(mutex);
2796 scope.unlock(); // expected-warning {{releasing mutex 'scope.other' that was not held}} in relockWeird()
2798 // expected-warning {{writing variable 'x' requires holding mutex 'mu' exclusively}} in relockWeird()
2800 …// expected-warning {{calling function 'requireOther' requires holding mutex 'scope.other' exclusi… in relockWeird()
2801 scope.lock(); // expected-note {{mutex acquired here}} in relockWeird()
2804 } // expected-warning {{mutex 'scope.other' is still held at the end of function}} in relockWeird()
2813 MutexUnlock(Mutex *mu) EXCLUSIVE_UNLOCK_FUNCTION(mu);
2822 ReaderMutexUnlock(Mutex *mu) SHARED_UNLOCK_FUNCTION(mu);
2829 Mutex mu;
2837 x = 2; // expected-warning {{writing variable 'x' requires holding mutex 'mu' exclusively}} in simple()
2843 print(x); // expected-warning {{reading variable 'x' requires holding mutex 'mu'}} in simpleShared()
2850 x = 1; // expected-warning {{writing variable 'x' requires holding mutex 'mu' exclusively}} in innerUnlock()
2859 print(x); // expected-warning {{reading variable 'x' requires holding mutex 'mu'}} in innerUnlockShared()
2869 x = 3; // expected-warning {{writing variable 'x' requires holding mutex 'mu' exclusively}} in manual()
2875 scope.Lock(); // expected-note{{mutex acquired here}} in join()
2877 // expected-warning@+1{{mutex 'mu' is not held on every path through here}} in join()
2883 scope.Lock(); // expected-note{{mutex acquired here}} in doubleLock()
2884 scope.Lock(); // expected-warning {{acquiring mutex 'mu' that is already held}} in doubleLock()
2888 MutexUnlock scope(&mu); // expected-note{{mutex released here}} in doubleUnlock()
2889 scope.Unlock(); // expected-warning {{releasing mutex 'mu' that was not held}} in doubleUnlock()
2894 …MutexLockUnlock(Mutex *mu1, Mutex *mu2) EXCLUSIVE_UNLOCK_FUNCTION(mu1) EXCLUSIVE_LOCK_FUNCTION(mu2…
2901 Mutex other;
2907 x = 1; // expected-warning {{writing variable 'x' requires holding mutex 'mu' exclusively}} in lockUnlock()
2917 Mutex mu1_;
2918 Mutex mu2_;
2947 Mutex mu_;
2971 Mutex mutex_;
2973 void foo1() EXCLUSIVE_LOCKS_REQUIRED(mutex_) { // expected-note {{mutex acquired here}} in foo1()
2975 } // expected-warning {{expecting mutex 'mutex_' to be held at the end of function}} in foo1()
2978 void foo2() SHARED_LOCKS_REQUIRED(mutex_) { // expected-note {{mutex acquired here}} in foo2()
2980 } // expected-warning {{expecting mutex 'mutex_' to be held at the end of function}} in foo2()
2991 WTF_ScopedLockable(Mutex* mu) EXCLUSIVE_LOCK_FUNCTION(mu);
3001 Mutex mu_;
3013 WTF_ScopedLockable wtf(&mu_); // expected-note {{mutex acquired here}} in test2()
3014 } // expected-warning {{mutex 'mu_' is still held at the end of function}} in test2()
3035 WTF_ScopedLockable wtf(&mu_); // expected-note {{mutex acquired here}} in test5()
3037 } // expected-warning {{mutex 'mu_' is not held on every path through here}} in test5()
3044 WTF_ScopedLockable wtf(&mu_); // expected-note {{mutex acquired here}} in test6()
3046 } // expected-warning {{mutex 'mu_' is not held on every path through here}} in test6()
3059 SmartPtr<Mutex> getMutexPtr();
3070 int b = a; // expected-warning {{reading variable 'a' requires holding mutex 'getMutexPtr()'}} in test()
3095 SmartPtr<Mutex> mu_;
3115 a = 0; // expected-warning {{writing variable 'a' requires holding mutex 'mu_' exclusively}} in test0()
3116 b = 0; // expected-warning {{writing variable 'b' requires holding mutex 'mu_' exclusively}} in test0()
3117 c = 0; // expected-warning {{writing variable 'c' requires holding mutex 'mu_' exclusively}} in test0()
3200 mu_->Lock(); // expected-note 2 {{mutex acquired here}} in test8()
3201 mu_.get()->Lock(); // expected-warning {{acquiring mutex 'mu_' that is already held}} in test8()
3202 (*mu_).Lock(); // expected-warning {{acquiring mutex 'mu_' that is already held}} in test8()
3203 mu_.get()->Unlock(); // expected-note {{mutex released here}} in test8()
3204 Unlock(); // expected-warning {{releasing mutex 'mu_' that was not held}} in test8()
3219 …foo->a = 0; // expected-warning {{writing variable 'a' requires holding mutex 'foo->mu_' e… in test0()
3220 …(*foo).b = 0; // expected-warning {{writing variable 'b' requires holding mutex 'foo->mu_' e… in test0()
3221 …foo.get()->c = 0; // expected-warning {{writing variable 'c' requires holding mutex 'foo->mu_' e… in test0()
3258 Mutex mu1_;
3259 Mutex mu2_;
3260 Mutex mu3_;
3334 foo.lock(); // expected-note{{mutex acquired here}} in test0()
3335 foo.lock(); // expected-warning {{acquiring mutex 'foo' that is already held}} in test0()
3336 foo.unlock(); // expected-note{{mutex released here}} in test0()
3337 foo.unlock(); // expected-warning {{releasing mutex 'foo' that was not held}} in test0()
3347 foo.lock1(); // expected-note{{mutex acquired here}} in test1()
3348 foo.lock1(); // expected-warning {{acquiring mutex 'foo.mu1_' that is already held}} in test1()
3350 foo.unlock1(); // expected-note{{mutex released here}} in test1()
3351 foo.unlock1(); // expected-warning {{releasing mutex 'foo.mu1_' that was not held}} in test1()
3361 foo.slock1(); // expected-note{{mutex acquired here}} in test2()
3362 foo.slock1(); // expected-warning {{acquiring mutex 'foo.mu1_' that is already held}} in test2()
3364 foo.unlock1(); // expected-note{{mutex released here}} in test2()
3365 foo.unlock1(); // expected-warning {{releasing mutex 'foo.mu1_' that was not held}} in test2()
3378 foo.lock3(); // expected-note 3 {{mutex acquired here}} in test3()
3380 // expected-warning {{acquiring mutex 'foo.mu1_' that is already held}} \ in test3()
3381 // expected-warning {{acquiring mutex 'foo.mu2_' that is already held}} \ in test3()
3382 // expected-warning {{acquiring mutex 'foo.mu3_' that is already held}} in test3()
3386 foo.unlock3(); // expected-note 3 {{mutex released here}} in test3()
3388 // expected-warning {{releasing mutex 'foo.mu1_' that was not held}} \ in test3()
3389 // expected-warning {{releasing mutex 'foo.mu2_' that was not held}} \ in test3()
3390 // expected-warning {{releasing mutex 'foo.mu3_' that was not held}} in test3()
3402 foo.locklots(); // expected-note 3 {{mutex acquired here}} in testlots()
3404 // expected-warning {{acquiring mutex 'foo.mu1_' that is already held}} \ in testlots()
3405 // expected-warning {{acquiring mutex 'foo.mu2_' that is already held}} \ in testlots()
3406 // expected-warning {{acquiring mutex 'foo.mu3_' that is already held}} in testlots()
3410 foo.unlocklots(); // expected-note 3 {{mutex released here}} in testlots()
3412 // expected-warning {{releasing mutex 'foo.mu1_' that was not held}} \ in testlots()
3413 // expected-warning {{releasing mutex 'foo.mu2_' that was not held}} \ in testlots()
3414 // expected-warning {{releasing mutex 'foo.mu3_' that was not held}} in testlots()
3424 Mutex mu_;
3429 Mutex* tryLockMutexP() EXCLUSIVE_TRYLOCK_FUNCTION(1, mu_);
3439 a = 0; // expected-warning {{writing variable 'a' requires holding mutex 'mu_' exclusively}} in test1()
3461 a = 0; // expected-warning {{writing variable 'a' requires holding mutex 'mu_' exclusively}} in test1()
3468 a = 0; // expected-warning {{writing variable 'a' requires holding mutex 'mu_' exclusively}} in test1()
3480 a = 0; // expected-warning {{writing variable 'a' requires holding mutex 'mu_' exclusively}} in test1()
3491 a = 0; // expected-warning {{writing variable 'a' requires holding mutex 'mu_' exclusively}} in test1()
3496 a = 0; // expected-warning {{writing variable 'a' requires holding mutex 'mu_' exclusively}} in test1()
3511 Mutex mu_;
3532 …n1.a = 0; // expected-warning {{writing variable 'a' requires holding mutex '&ExistentialPattern… in test()
3533 …n1.foo(); // expected-warning {{calling function 'foo' requires holding mutex '&ExistentialPatte… in test()
3539 …n1.foo2(); // expected-warning {{cannot call function 'foo2' while mutex '&ExistentialPatternMatc… in test()
3545 …n1.foo2(); // expected-warning {{cannot call function 'foo2' while mutex '&ExistentialPatternMatc… in test()
3551 …n1.foo2(); // expected-warning {{cannot call function 'foo2' while mutex '&ExistentialPatternMatc… in test()
3560 LockAllGraphs(); // expected-note{{mutex acquired here}} in test()
3561 g1.mu_.Lock(); // expected-warning {{acquiring mutex 'g1.mu_' that is already held}} in test()
3572 Mutex mu_;
3600 const Mutex& getLock(const Inner* i);
3611 Mutex lock_;
3616 const Mutex& Base::getLock(const Inner* i) LOCK_RETURNED(i->lock_) { in getLock()
3642 Mutex mu_;
3662 Mutex mu_;
3689 // expected-warning {{writing variable 'a' requires holding mutex 'mu_' exclusively}} in test2()
3691 // expected-warning {{releasing mutex '*' that was not held}} in test2()
3739 Mutex* get_mutex() LOCK_RETURNED(mutex_) { return &mutex_; } in get_mutex()
3741 Mutex mutex_;
3760 Mutex mu_;
3799 static Mutex mu_;
3809 static Mutex mu_;
3819 …Foo f; // expected-warning {{calling function 'Foo' requires holding mutex 'mu_' exclusi… in test1()
3820 …int a = f[0]; // expected-warning {{calling function 'operator[]' requires holding mutex 'mu_' … in test1()
3821 } // expected-warning {{calling function '~Foo' requires holding mutex 'mu_' exclu… in test1()
3827 Bar b; // expected-warning {{cannot call function 'Bar' while mutex 'mu_' is held}} in test2()
3828 … int a = b[0]; // expected-warning {{cannot call function 'operator[]' while mutex 'mu_' is held}} in test2()
3829 } // expected-warning {{cannot call function '~Bar' while mutex 'mu_' is held}} in test2()
3847 Mutex fatalmu_;
3879 virtual Mutex* getMutex() = 0;
3884 Mutex* getMutex();
3889 Mutex* getMutex();
3894 Mutex* getMutex(); // overrides Base::getMutex()
3911 Mutex* mu_;
3928 … // expected-warning {{calling function 'elr<int>' requires holding mutex 'cell.mu_' exclusively}} in test()
3941 …// expected-warning {{calling function 'globalELR<int>' requires holding mutex 'cell.mu_' exclusiv… in globalTest()
3962 …// expected-warning {{calling function 'globalELR2<int>' requires holding mutex 'cell.mu_' exclusi… in globalTest2()
3979 // expected-warning {{calling function 'elr' requires holding mutex 'cell.mu_' exclusively}} in testFooT()
3994 Mutex mu_;
4022 Mutex mu1_;
4023 Mutex mu2_;
4188 // expected-warning {{reading variable 'data_' requires holding mutex 'mu_'}} in test()
4190 // expected-warning {{reading variable 'data_' requires holding mutex 'mu_'}} in test()
4193 // expected-warning {{reading variable 'datap1_' requires holding mutex 'mu_'}} in test()
4195 // expected-warning {{reading variable 'datap1_' requires holding mutex 'mu_'}} in test()
4198 // expected-warning {{reading the value pointed to by 'datap2_' requires holding mutex 'mu_'}} in test()
4200 // expected-warning {{reading the value pointed to by 'datap2_' requires holding mutex 'mu_'}} in test()
4203 // expected-warning {{reading the value pointed to by 'datap2_' requires holding mutex 'mu_'}} in test()
4205 // expected-warning {{reading the value pointed to by 'datap2_' requires holding mutex 'mu_'}} in test()
4223 …data_ = Data(1); // expected-warning {{writing variable 'data_' requires holding mutex 'mu_' … in test2()
4224 …*datap1_ = data_; // expected-warning {{reading variable 'datap1_' requires holding mutex 'mu_… in test2()
4225 … // expected-warning {{reading variable 'data_' requires holding mutex 'mu_'}} in test2()
4226 …cted-warning {{writing the value pointed to by 'datap2_' requires holding mutex 'mu_' exclusively}… in test2()
4227 … // expected-warning {{reading variable 'data_' requires holding mutex 'mu_'}} in test2()
4228 …data_ = *datap1_; // expected-warning {{writing variable 'data_' requires holding mutex 'mu_' … in test2()
4229 … // expected-warning {{reading variable 'datap1_' requires holding mutex 'mu_'}} in test2()
4230 …data_ = *datap2_; // expected-warning {{writing variable 'data_' requires holding mutex 'mu_' … in test2()
4231 … // expected-warning {{reading the value pointed to by 'datap2_' requires holding mutex 'mu_'}} in test2()
4233 …data_[0] = 0; // expected-warning {{reading variable 'data_' requires holding mutex 'mu_'}} in test2()
4234 …; // expected-warning {{reading the value pointed to by 'datap2_' requires holding mutex 'mu_'}} in test2()
4236 …data_(); // expected-warning {{reading variable 'data_' requires holding mutex 'mu_'}} in test2()
4241 …Data mydat(data_); // expected-warning {{reading variable 'data_' requires holding mutex 'mu_… in test3()
4244 …//showDataCell(data_); // xpected-warning {{reading variable 'data_' requires holding mutex 'mu… in test3()
4245 …p2_); // xpected-warning {{reading the value pointed to by 'datap2_' requires holding mutex 'mu_'}} in test3()
4247 …int a = data_[0]; // expected-warning {{reading variable 'data_' requires holding mutex 'mu_… in test3()
4251 Mutex mu_;
4280 Mutex cell_mu_;
4286 Mutex mu_;
4291 foo.myMethod(); // expected-warning {{reading variable 'foo' requires holding mutex 'mu_'}} in test()
4293 int fa = foo.a; // expected-warning {{reading variable 'foo' requires holding mutex 'mu_'}} in test()
4294 …foo.a = fa; // expected-warning {{writing variable 'foo' requires holding mutex 'mu_' exc… in test()
4296 … // expected-warning {{reading the value pointed to by 'foop' requires holding mutex 'mu_'}} in test()
4297 …xpected-warning {{writing the value pointed to by 'foop' requires holding mutex 'mu_' exclusively}} in test()
4299 …a; // expected-warning {{reading the value pointed to by 'foop' requires holding mutex 'mu_'}} in test()
4300 …xpected-warning {{writing the value pointed to by 'foop' requires holding mutex 'mu_' exclusively}} in test()
4302 … foo.c = Cell(0); // expected-warning {{writing variable 'foo' requires holding mutex 'mu_'}} \ in test()
4303 … // expected-warning {{writing variable 'c' requires holding mutex 'foo.cell_mu_' exclusively}} in test()
4304 … foo.c.cellMethod(); // expected-warning {{reading variable 'foo' requires holding mutex 'mu_'}} \ in test()
4305 … // expected-warning {{reading variable 'c' requires holding mutex 'foo.cell_mu_'}} in test()
4307 …); // expected-warning {{writing the value pointed to by 'foop' requires holding mutex 'mu_'}} \ in test()
4308 … // expected-warning {{writing variable 'c' requires holding mutex 'foop->cell_mu_' exclusively}} in test()
4309 …d(); // expected-warning {{reading the value pointed to by 'foop' requires holding mutex 'mu_'}} \ in test()
4310 … // expected-warning {{reading variable 'c' requires holding mutex 'foop->cell_mu_'}} in test()
4312 …); // expected-warning {{writing the value pointed to by 'foop' requires holding mutex 'mu_'}} \ in test()
4313 … // expected-warning {{writing variable 'c' requires holding mutex 'foop->cell_mu_' exclusively}} in test()
4314 …d(); // expected-warning {{reading the value pointed to by 'foop' requires holding mutex 'mu_'}} \ in test()
4315 … // expected-warning {{reading variable 'c' requires holding mutex 'foop->cell_mu_'}} in test()
4325 Mutex mu_;
4345 static inline Mutex* getMutex1();
4346 static inline Mutex* getMutex2();
4365 Mutex mu_;
4393 void lockBad() EXCLUSIVE_LOCK_FUNCTION(mu_) { // expected-note {{mutex acquired here}} in lockBad()
4396 } // expected-warning {{expecting mutex 'mu_' to be held at the end of function}} in lockBad()
4398 void readerLockBad() SHARED_LOCK_FUNCTION(mu_) { // expected-note {{mutex acquired here}} in readerLockBad()
4401 } // expected-warning {{expecting mutex 'mu_' to be held at the end of function}} in readerLockBad()
4403 void unlockBad() UNLOCK_FUNCTION(mu_) { // expected-note {{mutex acquired here}} in unlockBad()
4406 } // expected-warning {{mutex 'mu_' is still held at the end of function}} in unlockBad()
4409 void lockBad2() EXCLUSIVE_LOCK_FUNCTION(mu_) { // expected-note {{mutex acquired here}} in lockBad2()
4410 mu2_.Lock(); // expected-note {{mutex acquired here}} in lockBad2()
4411 } // expected-warning {{expecting mutex 'mu_' to be held at the end of function}} \ in lockBad2()
4412 // expected-warning {{mutex 'mu2_' is still held at the end of function}}
4415 void readerLockBad2() SHARED_LOCK_FUNCTION(mu_) { // expected-note {{mutex acquired here}} in readerLockBad2()
4416 mu2_.ReaderLock(); // expected-note {{mutex acquired here}} in readerLockBad2()
4417 } // expected-warning {{expecting mutex 'mu_' to be held at the end of function}} \ in readerLockBad2()
4418 // expected-warning {{mutex 'mu2_' is still held at the end of function}}
4421 void unlockBad2() UNLOCK_FUNCTION(mu_) { // expected-note {{mutex acquired here}} in unlockBad2()
4422 mu2_.Unlock(); // expected-warning {{releasing mutex 'mu2_' that was not held}} in unlockBad2()
4423 } // expected-warning {{mutex 'mu_' is still held at the end of function}} in unlockBad2()
4426 Mutex mu_;
4427 Mutex mu2_;
4439 Mutex mu_;
4450 a = 0; // expected-warning {{writing variable 'a' requires holding mutex 'mu_' exclusively}} in test2()
4509 mu_.Lock(); // expected-note {{mutex acquired here}} in test9()
4511 } // expected-warning {{mutex 'mu_' is still held at the end of function}} in test9()
4515 mu_.Lock(); // expected-note {{mutex acquired here}} in test10()
4520 } // expected-warning {{mutex 'mu_' is still held at the end of function}} in test10()
4538 Mutex mu;
4636 Mutex mu1;
4637 Mutex mu2;
4657 …ng(); // expected-warning {{reading the value pointed to by 'a' requires holding mutex 'mu2'}} in test2()
4658 …/ expected-warning {{writing the value pointed to by 'a' requires holding mutex 'mu2' exclusively}} in test2()
4660 …hing(); // expected-warning {{reading the value pointed to by 'c' requires holding mutex 'mu2'}} in test2()
4661 …/ expected-warning {{writing the value pointed to by 'c' requires holding mutex 'mu2' exclusively}} in test2()
4663 …ething(); // expected-warning {{reading the value pointed to by 'c' requires holding mutex 'mu2'}} in test2()
4664 …/ expected-warning {{writing the value pointed to by 'c' requires holding mutex 'mu2' exclusively}} in test2()
4666 …ing(); // expected-warning {{reading the value pointed to by 'a' requires holding mutex 'mu2'}} in test2()
4667 …/ expected-warning {{writing the value pointed to by 'a' requires holding mutex 'mu2' exclusively}} in test2()
4668 …thing(); // expected-warning {{reading the value pointed to by 'c' requires holding mutex 'mu2'}} in test2()
4669 …/ expected-warning {{writing the value pointed to by 'c' requires holding mutex 'mu2' exclusively}} in test2()
4675 …== 0) doSomething(); // expected-warning {{reading variable 'a' requires holding mutex 'mu1'}} in test3()
4676 … // expected-warning {{reading variable 'a' requires holding mutex 'mu1'}} in test3()
4678 …a == 0) doSomething(); // expected-warning {{reading variable 'c' requires holding mutex 'mu1'}} in test3()
4679 …0; // expected-warning {{reading variable 'c' requires holding mutex 'mu1'}} in test3()
4681 …).a == 0) doSomething(); // expected-warning {{reading variable 'c' requires holding mutex 'mu1'}} in test3()
4682 …= 0; // expected-warning {{reading variable 'c' requires holding mutex 'mu1'}} in test3()
4684 …== 42) doSomething(); // expected-warning {{reading variable 'a' requires holding mutex 'mu1'}} in test3()
4685 …; // expected-warning {{reading variable 'a' requires holding mutex 'mu1'}} in test3()
4686 …a == 42) doSomething(); // expected-warning {{reading variable 'c' requires holding mutex 'mu1'}} in test3()
4687 …57; // expected-warning {{reading variable 'c' requires holding mutex 'mu1'}} in test3()
4692 …= 42) doSomething(); // expected-warning {{reading variable 'sa' requires holding mutex 'mu1'}} in test4()
4693 … // expected-warning {{writing variable 'sa' requires holding mutex 'mu1' exclusively}} in test4()
4694 … == 42) doSomething(); // expected-warning {{reading variable 'sc' requires holding mutex 'mu1'}} in test4()
4695 … // expected-warning {{writing variable 'sc' requires holding mutex 'mu1' exclusively}} in test4()
4697 …42) doSomething(); // expected-warning {{reading variable 'sa' requires holding mutex 'mu1'}} in test4()
4698 … // expected-warning {{writing variable 'sa' requires holding mutex 'mu1' exclusively}} in test4()
4699 … == 42) doSomething(); // expected-warning {{reading variable 'sc' requires holding mutex 'mu1'}} in test4()
4700 … // expected-warning {{writing variable 'sc' requires holding mutex 'mu1' exclusively}} in test4()
4701 …= 42) doSomething(); // expected-warning {{reading variable 'sc' requires holding mutex 'mu1'}} in test4()
4702 … // expected-warning {{writing variable 'sc' requires holding mutex 'mu1' exclusively}} in test4()
4723 Mutex mu1;
4724 Mutex mu2;
4747 …(); // expected-warning {{reading variable 'sp' requires holding mutex 'mu1'}} in test2()
4748 …p == 0) doSomething(); // expected-warning {{reading variable 'sp' requires holding mutex 'mu1'}} in test2()
4749 …0; // expected-warning {{reading variable 'sp' requires holding mutex 'mu1'}} in test2()
4750 …= 0; // expected-warning {{reading variable 'sq' requires holding mutex 'mu1'}} in test2()
4752 …] == 0) doSomething(); // expected-warning {{reading variable 'sp' requires holding mutex 'mu1'}} in test2()
4753 …0; // expected-warning {{reading variable 'sp' requires holding mutex 'mu1'}} in test2()
4754 …].a == 0) doSomething(); // expected-warning {{reading variable 'sq' requires holding mutex 'mu1'}} in test2()
4755 …= 0; // expected-warning {{reading variable 'sq' requires holding mutex 'mu1'}} in test2()
4764 …hing(); // expected-warning {{reading the value pointed to by 'sp' requires holding mutex 'mu2'}} in test3()
4765 … // expected-warning {{reading the value pointed to by 'sp' requires holding mutex 'mu2'}} in test3()
4766 … // expected-warning {{reading the value pointed to by 'sq' requires holding mutex 'mu2'}} in test3()
4768 …hing(); // expected-warning {{reading the value pointed to by 'sp' requires holding mutex 'mu2'}} in test3()
4769 … // expected-warning {{reading the value pointed to by 'sp' requires holding mutex 'mu2'}} in test3()
4770 …ething(); // expected-warning {{reading the value pointed to by 'sq' requires holding mutex 'mu2'}} in test3()
4771 … // expected-warning {{reading the value pointed to by 'sq' requires holding mutex 'mu2'}} in test3()
4784 …(RunHelper)(); // expected-warning {{calling function 'RunHelper' requires holding mutex 'M' excl… in Run()
4788 Mutex M;
4811 Mutex mu_;
4828 …func1(); // expected-warning {{calling function 'operator()' requires holding mutex 'mu_' exclusi… in test()
4844 Mutex* getMu() LOCK_RETURNED("");
4845 Mutex* getUniv() LOCK_RETURNED("*");
4855 void foo(Mutex* mu) EXCLUSIVE_LOCKS_REQUIRED(mu);
4864 struct MuCell { Mutex* mu; };
4866 MyMap<MyString, Mutex*> map;
4887 SmartPtr<Mutex> mu;
4892 … (a.val == b.val); // expected-warning {{reading variable 'val' requires holding mutex 'b.mu'}} \ in compare()
4901 SmartPtr<Mutex> mu;
4951 Mutex* getMutex(Opaque* o) LOCK_RETURNED("");
4963 Mutex mu;
4976 Mutex mu;
4982 baz(); // expected-warning {{cannot call function 'baz' while mutex 'mu' is held}} in foo()
5028 …dispatch_log("wrong"); /* expected-warning {{cannot call function 'dispatch_log' while mutex 'Flig… in flight_control_entry()
5072 Mutex mu;
5092 Mutex mu;
5099 int b = a; // expected-warning {{reading variable 'a' requires holding mutex 'mu'}} in nonref_test()
5104 auto b = a; // expected-warning {{reading variable 'a' requires holding mutex 'mu'}} in auto_test()
5107 …c = 0; // expected-warning {{writing variable 'a' requires holding mutex 'mu' excl… in auto_test()
5114 …b = 0; // expected-warning {{writing variable 'a' requires holding mutex 'mu' excl… in ref_test()
5115 …c = 0; // expected-warning {{writing variable 'a' requires holding mutex 'mu' excl… in ref_test()
5116 …d = 0; // expected-warning {{writing variable 'a' requires holding mutex 'mu' excl… in ref_test()
5119 …rs.a = 0; // expected-warning {{writing variable 's' requires holding mutex 'mu' excl… in ref_test()
5122 …rarr[2] = 0; // expected-warning {{writing variable 'arr' requires holding mutex 'mu' ex… in ref_test()
5132 …for (int i : cntr) { // expected-warning2 {{reading variable 'cntr' requires holding mutex 'mu'}} in for_test()
5194 Mutex mu;
5215 … copy(foo); // expected-warning {{reading variable 'foo' requires holding mutex 'mu'}} in test1()
5216 …; // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5217 …foo); // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5218 … // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5219 …oo); // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5220 …ove(foo)); // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5222 … copyVariadic(foo); // expected-warning {{reading variable 'foo' requires holding mutex 'mu'}} in test1()
5223 …c(foo); // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5224 …ic(foo); // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5225 … copyVariadicC(1, foo); // expected-warning {{reading variable 'foo' requires holding mutex 'mu'}} in test1()
5227 …der(foo); // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5228 …iter(foo); // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5230 …; // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5231 …foo); // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5232 … // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5233 …oo); // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5235 …; // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5236 …foo); // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5237 … // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5238 …oo); // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5240 …foo + foo2; // expected-warning {{reading variable 'foo' requires holding mutex 'mu'}… in test1()
5241 … // expected-warning {{passing variable 'foo2' by reference requires holding mutex 'mu'}} in test1()
5242 …foo / foo2; // expected-warning {{reading variable 'foo' requires holding mutex 'mu'}… in test1()
5243 … // expected-warning {{passing variable 'foo2' by reference requires holding mutex 'mu'}} in test1()
5244 …foo * foo2; // expected-warning {{reading variable 'foo' requires holding mutex 'mu'}… in test1()
5245 … // expected-warning {{passing variable 'foo2' by reference requires holding mutex 'mu'}} in test1()
5246 …foo[foo2]; // expected-warning {{reading variable 'foo' requires holding mutex 'mu'}… in test1()
5247 … // expected-warning {{passing variable 'foo2' by reference requires holding mutex 'mu'}} in test1()
5248 …foo(); // expected-warning {{reading variable 'foo' requires holding mutex 'mu'}} in test1()
5249 …o; // expected-warning {{passing variable 'foo' by reference requires holding mutex 'mu'}} in test1()
5251 … // expected-warning {{reading the value pointed to by 'foop' requires holding mutex 'mu'}} in test1()
5252 …pected-warning {{passing the value that 'foop' points to by reference requires holding mutex 'mu'}} in test1()
5253 …pected-warning {{passing the value that 'foop' points to by reference requires holding mutex 'mu'}} in test1()
5254 …pected-warning {{passing the value that 'foop' points to by reference requires holding mutex 'mu'}} in test1()
5255 …pected-warning {{passing the value that 'foop' points to by reference requires holding mutex 'mu'}} in test1()
5256 …pected-warning {{passing the value that 'foop' points to by reference requires holding mutex 'mu'}} in test1()
5258 … // expected-warning {{reading the value pointed to by 'foosp' requires holding mutex 'mu'}} in test1()
5259 … // expected-warning {{reading the value pointed to by 'foosp' requires holding mutex 'mu'}} in test1()
5260 …; // expected-warning {{reading the value pointed to by 'foosp' requires holding mutex 'mu'}} in test1()
5261 … // expected-warning {{reading the value pointed to by 'foosp' requires holding mutex 'mu'}} in test1()
5262 … // expected-warning {{reading the value pointed to by 'foosp' requires holding mutex 'mu'}} in test1()
5263 …osp)); // expected-warning {{reading the value pointed to by 'foosp' requires holding mutex 'mu'}} in test1()
5282 Mutex mu1 ACQUIRED_BEFORE(mu2, mu3);
5283 Mutex mu2;
5284 Mutex mu3;
5298 mu1.Lock(); // expected-warning {{mutex 'mu1' must be acquired before 'mu2'}} in test2()
5305 mu1.Lock(); // expected-warning {{mutex 'mu1' must be acquired before 'mu3'}} in test3()
5316 mu1.Lock(); // expected-warning {{mutex 'mu1' must be acquired before 'mu2'}} in test5()
5331 Mutex mu1;
5332 Mutex mu2 ACQUIRED_AFTER(mu1);
5333 Mutex mu3 ACQUIRED_AFTER(mu1);
5347 mu1.Lock(); // expected-warning {{mutex 'mu1' must be acquired before 'mu2'}} in test2()
5354 mu1.Lock(); // expected-warning {{mutex 'mu1' must be acquired before 'mu3'}} in test3()
5362 Mutex mu1 ACQUIRED_BEFORE(mu2);
5363 Mutex mu2;
5364 Mutex mu3 ACQUIRED_AFTER(mu2) ACQUIRED_BEFORE(mu4);
5365 Mutex mu4;
5381 mu2.Lock(); // expected-warning {{mutex 'mu2' must be acquired before 'mu4'}} in test2()
5389 mu1.Lock(); // expected-warning {{mutex 'mu1' must be acquired before 'mu4'}} in test3()
5397 mu1.Lock(); // expected-warning {{mutex 'mu1' must be acquired before 'mu3'}} in test4()
5407 Mutex mu1;
5408 Mutex mu2 ACQUIRED_AFTER(mu1);
5409 Mutex mu3 ACQUIRED_AFTER(mu1);
5410 Mutex mu4 ACQUIRED_AFTER(mu2, mu3);
5411 Mutex mu5 ACQUIRED_AFTER(mu4);
5412 Mutex mu6 ACQUIRED_AFTER(mu4);
5413 Mutex mu7 ACQUIRED_AFTER(mu5, mu6);
5414 Mutex mu8 ACQUIRED_AFTER(mu7);
5418 mu1.Lock(); // expected-warning {{mutex 'mu1' must be acquired before 'mu8'}} in test()
5427 Mutex mu1 ACQUIRED_BEFORE(mu2, mu3);
5428 Mutex mu2 ACQUIRED_BEFORE(mu4);
5429 Mutex mu3 ACQUIRED_BEFORE(mu4);
5430 Mutex mu4 ACQUIRED_BEFORE(mu5, mu6);
5431 Mutex mu5 ACQUIRED_BEFORE(mu7);
5432 Mutex mu6 ACQUIRED_BEFORE(mu7);
5433 Mutex mu7 ACQUIRED_BEFORE(mu8);
5434 Mutex mu8;
5438 mu1.Lock(); // expected-warning {{mutex 'mu1' must be acquired before 'mu8'}} in test()
5446Mutex mu1 ACQUIRED_AFTER(mu3); // expected-warning {{Cycle in acquired_before/after dependenci…
5447Mutex mu2 ACQUIRED_AFTER(mu1); // expected-warning {{Cycle in acquired_before/after dependenci…
5448Mutex mu3 ACQUIRED_AFTER(mu2); // expected-warning {{Cycle in acquired_before/after dependenci…
5450Mutex mu_b ACQUIRED_BEFORE(mu_b); // expected-warning {{Cycle in acquired_before/after dependenci…
5451Mutex mu_a ACQUIRED_AFTER(mu_a); // expected-warning {{Cycle in acquired_before/after dependenci…
5491 Mutex mu;
5505 void test3() EXCLUSIVE_LOCKS_REQUIRED(mu) { // expected-note {{mutex acquired here}} in test3()
5508 } // expected-warning {{expecting mutex 'mu' to be held at the end of function}} in test3()
5510 void test4() SHARED_LOCKS_REQUIRED(mu) { // expected-note {{mutex acquired here}} in test4()
5513 } // expected-warning {{expecting mutex 'mu' to be held at the end of function}} in test4()
5549 Mutex mu;
5575 Mutex mu1;
5576 Mutex mu2 ACQUIRED_AFTER(mu1);
5580 mu1.Lock(); // expected-warning {{mutex 'mu1' must be acquired before 'mu2'}} in test3()
5618 muun1.Lock(); // expected-warning {{mutex 'muun1' must be acquired before 'muun2'}} in test()
5629 } // expected-warning {{mutex 'lock_' is still held at the end of function}} in WaitUntilSpaceAvailable()
5630 Mutex lock_ ACQUIRED_BEFORE("");
5651 ReadLockedPtr(Object *ptr) SHARED_LOCK_FUNCTION((*this)->mutex);
5652 ReadLockedPtr(ReadLockedPtr &&) SHARED_LOCK_FUNCTION((*this)->mutex);
5662 int f() SHARED_LOCKS_REQUIRED(mutex);
5663 Mutex mutex; member
5703 SmartPtr_Derived<Mutex> mu_;
5712 a = 1; // expected-warning {{writing variable 'a' requires holding mutex 'mu_' exclusively}} in test0()
5713 b = 1; // expected-warning {{writing variable 'b' requires holding mutex 'mu_' exclusively}} in test0()
5714 c = 1; // expected-warning {{writing variable 'c' requires holding mutex 'mu_' exclusively}} in test0()
5730 …foo->a = 1; // expected-warning {{writing variable 'a' requires holding mutex 'foo->mu_' ex… in test0()
5731 …(*foo).b = 1; // expected-warning {{writing variable 'b' requires holding mutex 'foo->mu_' ex… in test0()
5732 …foo.get()->c = 1; // expected-warning {{writing variable 'c' requires holding mutex 'foo->mu_' ex… in test0()
5750 Mutex mu1;
5751 Mutex mu2;
5755 i.get(); // expected-warning {{reading variable 'i' requires holding mutex 'mu1'}} in test0()
5756 *i = 2; // expected-warning {{reading variable 'i' requires holding mutex 'mu1'}} \ in test0()
5757 … // expected-warning {{reading the value pointed to by 'i' requires holding mutex 'mu2'}} in test0()
5765 … *i = 2; // expected-warning {{reading the value pointed to by 'i' requires holding mutex 'mu2'}} in test1()
5773 i.get(); // expected-warning {{reading variable 'i' requires holding mutex 'mu1'}} in test2()
5774 *i = 2; // expected-warning {{reading variable 'i' requires holding mutex 'mu1'}} in test2()