Lines Matching defs:EXCLUSIVE_LOCKS_REQUIRED
20 #define EXCLUSIVE_LOCKS_REQUIRED(...) \
21 __attribute__ ((exclusive_locks_required(__VA_ARGS__)))
1064 #if !__has_attribute(exclusive_locks_required)
1065 #error "Should support exclusive_locks_required attribute"
1070 void elr_function() __attribute__((exclusive_locks_required)); // \
1071 // expected-error {{'exclusive_locks_required' attribute takes at least 1 argument}}
1073 void elr_function_arg() EXCLUSIVE_LOCKS_REQUIRED(mu1);
1075 void elr_function_args() EXCLUSIVE_LOCKS_REQUIRED(mu1, mu2);
1077 int elr_testfn(int y) EXCLUSIVE_LOCKS_REQUIRED(mu1);
1080 int x EXCLUSIVE_LOCKS_REQUIRED(mu1) = y; // \
1081 // expected-warning {{'exclusive_locks_required' attribute only applies to functions}}
1085 int elr_test_var EXCLUSIVE_LOCKS_REQUIRED(mu1); // \
1086 // expected-warning {{'exclusive_locks_required' attribute only applies to functions}}
1088 void elr_fun_params(int lvar EXCLUSIVE_LOCKS_REQUIRED(mu1)); // \
1089 // expected-warning {{'exclusive_locks_required' attribute only applies to functions}}
1093 int test_field EXCLUSIVE_LOCKS_REQUIRED(mu1); // \
1094 // expected-warning {{'exclusive_locks_required' attribute only applies to functions}}
1095 void test_method() EXCLUSIVE_LOCKS_REQUIRED(mu1);
1098 class EXCLUSIVE_LOCKS_REQUIRED(mu1) ElrTestClass { // \
1099 // expected-warning {{'exclusive_locks_required' attribute only applies to functions}}
1105 int elr_function_1() EXCLUSIVE_LOCKS_REQUIRED(muWrapper.mu);
1106 int elr_function_2() EXCLUSIVE_LOCKS_REQUIRED(muDoubleWrapper.muWrapper->mu);
1107 int elr_function_3() EXCLUSIVE_LOCKS_REQUIRED(muWrapper.getMu());
1108 int elr_function_4() EXCLUSIVE_LOCKS_REQUIRED(*muWrapper.getMuPointer());
1109 int elr_function_5() EXCLUSIVE_LOCKS_REQUIRED(&mu1);
1110 int elr_function_6() EXCLUSIVE_LOCKS_REQUIRED(muRef);
1111 int elr_function_7() EXCLUSIVE_LOCKS_REQUIRED(muDoubleWrapper.getWrapper()->getMu());
1112 int elr_function_8() EXCLUSIVE_LOCKS_REQUIRED(muPointer);
1116 int elr_function_bad_1() EXCLUSIVE_LOCKS_REQUIRED(1); // \
1117 // expected-warning {{'exclusive_locks_required' attribute requires arguments whose type is annotated with 'capability' attribute; type here is 'int'}}
1118 int elr_function_bad_2() EXCLUSIVE_LOCKS_REQUIRED("mu"); // \
1119 // expected-warning {{ignoring 'exclusive_locks_required' attribute because its argument is invalid}}
1120 int elr_function_bad_3() EXCLUSIVE_LOCKS_REQUIRED(muDoublePointer); // \
1121 // expected-warning {{'exclusive_locks_required' attribute requires arguments whose type is annotated with 'capability' attribute; type here is 'Mutex **'}}
1122 int elr_function_bad_4() EXCLUSIVE_LOCKS_REQUIRED(umu); // \
1123 // expected-warning {{'exclusive_locks_required' attribute requires arguments whose type is annotated with 'capability' attribute}}
1263 void foo1() EXCLUSIVE_LOCKS_REQUIRED(gmu) { }
1264 void foo2() EXCLUSIVE_LOCKS_REQUIRED(mu) { }
1265 void foo3(Mutex *m) EXCLUSIVE_LOCKS_REQUIRED(m) { }
1266 EXCLUSIVE_LOCKS_REQUIRED(f->mu) { }
1267 void foo4(FooLate *f) EXCLUSIVE_LOCKS_REQUIRED(f->mu);
1269 static void foo5() EXCLUSIVE_LOCKS_REQUIRED(mu); // \
1273 void foo6() EXCLUSIVE_LOCKS_REQUIRED(T::statmu) { }
1276 void foo7(T* f) EXCLUSIVE_LOCKS_REQUIRED(f->mu) { }
1312 void Foo::foo1() EXCLUSIVE_LOCKS_REQUIRED(mu_) { }
1313 void Foo::foo2(Foo *f) EXCLUSIVE_LOCKS_REQUIRED(f->mu_) { }
1316 void Bar<T>::bar() EXCLUSIVE_LOCKS_REQUIRED(mu_) { }
1318 void baz(Foo *f) EXCLUSIVE_LOCKS_REQUIRED(f->mu_) { }
1344 void bar() EXCLUSIVE_LOCKS_REQUIRED(mu) { a = 0; }
1345 void bar2(Bar* b) EXCLUSIVE_LOCKS_REQUIRED(b->mu) { b->a = 0; }
1346 void bar3(Foo* f) EXCLUSIVE_LOCKS_REQUIRED(f->fooMu) { f->a = 0; }
1362 void testEmptyAttributeFunction() EXCLUSIVE_LOCKS_REQUIRED("");
1373 void foo() EXCLUSIVE_LOCKS_REQUIRED(&Graph::mu_);
1435 void foo() EXCLUSIVE_LOCKS_REQUIRED(mu1_, mu2_) {
1467 static void foo() EXCLUSIVE_LOCKS_REQUIRED(mu); // \
1471 EXCLUSIVE_LOCKS_REQUIRED(mu); // \
1495 void foo() EXCLUSIVE_LOCKS_REQUIRED(mu); // \