[lttng-dev] [PATCH urcu] Add multiflavor compat identifiers
Mathieu Desnoyers
mathieu.desnoyers at efficios.com
Fri Jan 25 17:47:05 EST 2019
----- On Jan 25, 2019, at 3:15 PM, Michael Jeanson mjeanson at efficios.com wrote:
> This will maintain buildtime compatibility with softwares like lttng-ust
> that used the prior undocumented multiflavor API.
>
> Signed-off-by: Michael Jeanson <mjeanson at efficios.com>
> ---
> include/urcu/map/urcu-bp.h | 63 ++++++++++++++++++++++++++++++++++
> include/urcu/map/urcu-mb.h | 60 ++++++++++++++++++++++++++++++++
> include/urcu/map/urcu-memb.h | 62 +++++++++++++++++++++++++++++++++
> include/urcu/map/urcu-qsbr.h | 62 +++++++++++++++++++++++++++++++++
> include/urcu/map/urcu-signal.h | 62 +++++++++++++++++++++++++++++++++
> src/urcu-bp.c | 1 +
> src/urcu-qsbr.c | 1 +
> src/urcu.c | 1 +
> 8 files changed, 312 insertions(+)
>
[...]
> diff --git a/include/urcu/map/urcu-mb.h b/include/urcu/map/urcu-mb.h
> index fa77a1a..f4e89b9 100644
> --- a/include/urcu/map/urcu-mb.h
> +++ b/include/urcu/map/urcu-mb.h
> @@ -128,3 +128,63 @@
> #define alias_rcu_defer_barrier rcu_defer_barrier_mb
> #define alias_rcu_defer_barrier_thread rcu_defer_barrier_thread_mb
> #define alias_rcu_defer_exit rcu_defer_exit_mb
> +
> +
> +/* Compat identifiers for prior undocumented multiflavor usage */
> +#ifndef URCU_NO_COMPAT_IDENTIFIERS
> +
> +#define rcu_dereference_mb urcu_bp_dereference
> +#define rcu_cmpxchg_pointer_mb urcu_bp_cmpxchg_pointer
> +#define rcu_xchg_pointer_mb urcu_bp_xchg_pointer
> +#define rcu_set_pointer_mb urcu_bp_set_pointer
> +
> +#define rcu_mb_before_fork urcu_bp_before_fork
> +#define rcu_mb_after_fork_parent urcu_bp_after_fork_parent
> +#define rcu_mb_after_fork_child urcu_bp_after_fork_child
For the above: urcu_bp -> urcu_mb.
[...]
> +#endif /* URCU_NO_COMPAT_IDENTIFIERS */
> diff --git a/include/urcu/map/urcu-memb.h b/include/urcu/map/urcu-memb.h
> index 33f9a9b..f15a645 100644
> --- a/include/urcu/map/urcu-memb.h
> +++ b/include/urcu/map/urcu-memb.h
> @@ -128,3 +128,65 @@
> #define alias_rcu_defer_barrier rcu_defer_barrier_memb
> #define alias_rcu_defer_barrier_thread rcu_defer_barrier_thread_memb
> #define alias_rcu_defer_exit rcu_defer_exit_memb
> +
> +
> +/* Compat identifiers for prior undocumented multiflavor usage */
> +#ifndef URCU_NO_COMPAT_IDENTIFIERS
> +
> +#define rcu_dereference_memb urcu_bp_dereference
> +#define rcu_cmpxchg_pointer_memb urcu_bp_cmpxchg_pointer
> +#define rcu_xchg_pointer_memb urcu_bp_xchg_pointer
> +#define rcu_set_pointer_memb urcu_bp_set_pointer
> +
> +#define rcu_memb_before_fork urcu_bp_before_fork
> +#define rcu_memb_after_fork_parent urcu_bp_after_fork_parent
> +#define rcu_memb_after_fork_child urcu_bp_after_fork_child
For the above: urcu_bp -> urcu_memb.
[...]
> +#endif /* URCU_NO_COMPAT_IDENTIFIERS */
> diff --git a/include/urcu/map/urcu-qsbr.h b/include/urcu/map/urcu-qsbr.h
> index 2b4d861..1af8c54 100644
> --- a/include/urcu/map/urcu-qsbr.h
> +++ b/include/urcu/map/urcu-qsbr.h
> @@ -126,3 +126,65 @@
> #define alias_rcu_defer_barrier rcu_defer_barrier_qsbr
> #define alias_rcu_defer_barrier_thread rcu_defer_barrier_thread_qsbr
> #define alias_rcu_defer_exit rcu_defer_exit_qsbr
> +
> +
> +/* Compat identifiers for prior undocumented multiflavor usage */
> +#ifndef URCU_NO_COMPAT_IDENTIFIERS
> +
> +#define rcu_dereference_qsbr urcu_bp_dereference
> +#define rcu_cmpxchg_pointer_qsbr urcu_bp_cmpxchg_pointer
> +#define rcu_xchg_pointer_qsbr urcu_bp_xchg_pointer
> +#define rcu_set_pointer_qsbr urcu_bp_set_pointer
> +
> +#define rcu_qsbr_before_fork urcu_bp_before_fork
> +#define rcu_qsbr_after_fork_parent urcu_bp_after_fork_parent
> +#define rcu_qsbr_after_fork_child urcu_bp_after_fork_child
> +
For the above: urcu_bp -> urcu_qsbr.
[...]
Thanks!
Mathieu
--
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com
More information about the lttng-dev
mailing list