|
|
@ -54,7 +54,6 @@
|
|
|
|
unsigned int write_barrier; \
|
|
|
|
unsigned int write_barrier; \
|
|
|
|
unsigned int wait_limit; \
|
|
|
|
unsigned int wait_limit; \
|
|
|
|
}; \
|
|
|
|
}; \
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_wp_##N##_init(CK_RWCOHORT_WP_INSTANCE(N) *rw_cohort, \
|
|
|
|
ck_rwcohort_wp_##N##_init(CK_RWCOHORT_WP_INSTANCE(N) *rw_cohort, \
|
|
|
|
unsigned int wait_limit) \
|
|
|
|
unsigned int wait_limit) \
|
|
|
@ -65,7 +64,6 @@
|
|
|
|
ck_pr_barrier(); \
|
|
|
|
ck_pr_barrier(); \
|
|
|
|
return; \
|
|
|
|
return; \
|
|
|
|
} \
|
|
|
|
} \
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_wp_##N##_write_lock(CK_RWCOHORT_WP_INSTANCE(N) *rw_cohort, \
|
|
|
|
ck_rwcohort_wp_##N##_write_lock(CK_RWCOHORT_WP_INSTANCE(N) *rw_cohort, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
@ -83,7 +81,6 @@
|
|
|
|
\
|
|
|
|
\
|
|
|
|
return; \
|
|
|
|
return; \
|
|
|
|
} \
|
|
|
|
} \
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_wp_##N##_write_unlock(CK_RWCOHORT_WP_INSTANCE(N) *rw_cohort, \
|
|
|
|
ck_rwcohort_wp_##N##_write_unlock(CK_RWCOHORT_WP_INSTANCE(N) *rw_cohort, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
@ -92,7 +89,6 @@
|
|
|
|
(void)rw_cohort; \
|
|
|
|
(void)rw_cohort; \
|
|
|
|
CK_COHORT_UNLOCK(N, cohort, global_context, local_context); \
|
|
|
|
CK_COHORT_UNLOCK(N, cohort, global_context, local_context); \
|
|
|
|
} \
|
|
|
|
} \
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_wp_##N##_read_lock(CK_RWCOHORT_WP_INSTANCE(N) *rw_cohort, \
|
|
|
|
ck_rwcohort_wp_##N##_read_lock(CK_RWCOHORT_WP_INSTANCE(N) *rw_cohort, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
@ -123,7 +119,6 @@
|
|
|
|
\
|
|
|
|
\
|
|
|
|
return; \
|
|
|
|
return; \
|
|
|
|
} \
|
|
|
|
} \
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_wp_##N##_read_unlock(CK_RWCOHORT_WP_INSTANCE(N) *cohort) \
|
|
|
|
ck_rwcohort_wp_##N##_read_unlock(CK_RWCOHORT_WP_INSTANCE(N) *cohort) \
|
|
|
|
{ \
|
|
|
|
{ \
|
|
|
@ -152,7 +147,6 @@
|
|
|
|
unsigned int read_barrier; \
|
|
|
|
unsigned int read_barrier; \
|
|
|
|
unsigned int wait_limit; \
|
|
|
|
unsigned int wait_limit; \
|
|
|
|
}; \
|
|
|
|
}; \
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_rp_##N##_init(CK_RWCOHORT_RP_INSTANCE(N) *rw_cohort, \
|
|
|
|
ck_rwcohort_rp_##N##_init(CK_RWCOHORT_RP_INSTANCE(N) *rw_cohort, \
|
|
|
|
unsigned int wait_limit) \
|
|
|
|
unsigned int wait_limit) \
|
|
|
@ -163,7 +157,6 @@
|
|
|
|
ck_pr_barrier(); \
|
|
|
|
ck_pr_barrier(); \
|
|
|
|
return; \
|
|
|
|
return; \
|
|
|
|
} \
|
|
|
|
} \
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_rp_##N##_write_lock(CK_RWCOHORT_RP_INSTANCE(N) *rw_cohort, \
|
|
|
|
ck_rwcohort_rp_##N##_write_lock(CK_RWCOHORT_RP_INSTANCE(N) *rw_cohort, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
@ -194,7 +187,6 @@
|
|
|
|
\
|
|
|
|
\
|
|
|
|
return; \
|
|
|
|
return; \
|
|
|
|
} \
|
|
|
|
} \
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_rp_##N##_write_unlock(CK_RWCOHORT_RP_INSTANCE(N) *rw_cohort, \
|
|
|
|
ck_rwcohort_rp_##N##_write_unlock(CK_RWCOHORT_RP_INSTANCE(N) *rw_cohort, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, void *local_context) \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, void *local_context) \
|
|
|
@ -202,7 +194,6 @@
|
|
|
|
(void)rw_cohort; \
|
|
|
|
(void)rw_cohort; \
|
|
|
|
CK_COHORT_UNLOCK(N, cohort, global_context, local_context); \
|
|
|
|
CK_COHORT_UNLOCK(N, cohort, global_context, local_context); \
|
|
|
|
} \
|
|
|
|
} \
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_rp_##N##_read_lock(CK_RWCOHORT_RP_INSTANCE(N) *rw_cohort, \
|
|
|
|
ck_rwcohort_rp_##N##_read_lock(CK_RWCOHORT_RP_INSTANCE(N) *rw_cohort, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
@ -219,8 +210,6 @@
|
|
|
|
\
|
|
|
|
\
|
|
|
|
return; \
|
|
|
|
return; \
|
|
|
|
} \
|
|
|
|
} \
|
|
|
|
\
|
|
|
|
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_rp_##N##_read_unlock(CK_RWCOHORT_RP_INSTANCE(N) *cohort) \
|
|
|
|
ck_rwcohort_rp_##N##_read_unlock(CK_RWCOHORT_RP_INSTANCE(N) *cohort) \
|
|
|
|
{ \
|
|
|
|
{ \
|
|
|
@ -247,7 +236,6 @@
|
|
|
|
CK_RWCOHORT_NEUTRAL_INSTANCE(N) { \
|
|
|
|
CK_RWCOHORT_NEUTRAL_INSTANCE(N) { \
|
|
|
|
unsigned int read_counter; \
|
|
|
|
unsigned int read_counter; \
|
|
|
|
}; \
|
|
|
|
}; \
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_neutral_##N##_init(CK_RWCOHORT_NEUTRAL_INSTANCE(N) *rw_cohort) \
|
|
|
|
ck_rwcohort_neutral_##N##_init(CK_RWCOHORT_NEUTRAL_INSTANCE(N) *rw_cohort) \
|
|
|
|
{ \
|
|
|
|
{ \
|
|
|
@ -255,7 +243,6 @@
|
|
|
|
ck_pr_barrier(); \
|
|
|
|
ck_pr_barrier(); \
|
|
|
|
return; \
|
|
|
|
return; \
|
|
|
|
} \
|
|
|
|
} \
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_neutral_##N##_write_lock(CK_RWCOHORT_NEUTRAL_INSTANCE(N) *rw_cohort, \
|
|
|
|
ck_rwcohort_neutral_##N##_write_lock(CK_RWCOHORT_NEUTRAL_INSTANCE(N) *rw_cohort, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
@ -267,7 +254,6 @@
|
|
|
|
} \
|
|
|
|
} \
|
|
|
|
return; \
|
|
|
|
return; \
|
|
|
|
} \
|
|
|
|
} \
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_neutral_##N##_write_unlock(CK_RWCOHORT_NEUTRAL_INSTANCE(N) *rw_cohort, \
|
|
|
|
ck_rwcohort_neutral_##N##_write_unlock(CK_RWCOHORT_NEUTRAL_INSTANCE(N) *rw_cohort, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, void *local_context) \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, void *local_context) \
|
|
|
@ -275,7 +261,6 @@
|
|
|
|
(void)rw_cohort; \
|
|
|
|
(void)rw_cohort; \
|
|
|
|
CK_COHORT_UNLOCK(N, cohort, global_context, local_context); \
|
|
|
|
CK_COHORT_UNLOCK(N, cohort, global_context, local_context); \
|
|
|
|
} \
|
|
|
|
} \
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_neutral_##N##_read_lock(CK_RWCOHORT_NEUTRAL_INSTANCE(N) *rw_cohort, \
|
|
|
|
ck_rwcohort_neutral_##N##_read_lock(CK_RWCOHORT_NEUTRAL_INSTANCE(N) *rw_cohort, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
|
CK_COHORT_INSTANCE(N) *cohort, void *global_context, \
|
|
|
@ -287,8 +272,6 @@
|
|
|
|
\
|
|
|
|
\
|
|
|
|
return; \
|
|
|
|
return; \
|
|
|
|
} \
|
|
|
|
} \
|
|
|
|
\
|
|
|
|
|
|
|
|
\
|
|
|
|
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
CK_CC_INLINE static void \
|
|
|
|
ck_rwcohort_neutral_##N##_read_unlock(CK_RWCOHORT_NEUTRAL_INSTANCE(N) *cohort) \
|
|
|
|
ck_rwcohort_neutral_##N##_read_unlock(CK_RWCOHORT_NEUTRAL_INSTANCE(N) *cohort) \
|
|
|
|
{ \
|
|
|
|
{ \
|
|
|
|