[RISCV] Match vcompress during shuffle lowering (#117748)
[llvm-project.git] / clang / test / Analysis / Inputs / system-header-simulator-for-pthread-lock.h
blob591ec0ea818ff7b9715e27da92cc8e4ba4c0376d
1 // Like the compiler, the static analyzer treats some functions differently if
2 // they come from a system header -- for example, pthread_mutex* functions
3 // should not invalidate regions of their arguments.
4 #pragma clang system_header
6 typedef struct {
7 void *foo;
8 } pthread_mutex_t;
10 typedef struct {
11 void *foo;
12 } pthread_mutexattr_t;
14 typedef struct {
15 void *foo;
16 } lck_grp_t;
18 typedef struct {
19 void *foo;
20 } lck_rw_t;
22 typedef pthread_mutex_t lck_mtx_t;
24 extern void fake_system_function();
25 extern void fake_system_function_that_takes_a_mutex(pthread_mutex_t *mtx);
27 extern int pthread_mutex_lock(pthread_mutex_t *);
28 extern int pthread_mutex_unlock(pthread_mutex_t *);
29 extern int pthread_mutex_trylock(pthread_mutex_t *);
30 extern int pthread_mutex_destroy(pthread_mutex_t *);
31 extern int pthread_mutex_init(pthread_mutex_t *mutex, const pthread_mutexattr_t *mutexattr);
33 typedef int boolean_t;
34 extern void lck_mtx_lock(lck_mtx_t *);
35 extern void lck_mtx_unlock(lck_mtx_t *);
36 extern boolean_t lck_mtx_try_lock(lck_mtx_t *);
37 extern void lck_mtx_destroy(lck_mtx_t *lck, lck_grp_t *grp);
39 extern void lck_rw_lock_exclusive(lck_rw_t *lck);
40 extern void lck_rw_unlock_exclusive(lck_rw_t *lck);
41 extern void lck_rw_lock_shared(lck_rw_t *lck);
42 extern void lck_rw_unlock_shared(lck_rw_t *lck);