From c8c8cb0bce47c5ecebb4a4b6932820e0fd04cdcc Mon Sep 17 00:00:00 2001 From: Ivan Maidanski Date: Wed, 2 Jan 2013 12:31:08 +0400 Subject: [PATCH] Fix AO_XSIZE_load/store definition order in generalize-small template * src/atomic_ops/generalize-small.template (AO_XSIZE_load): Move definition (which is based on AO_XSIZE_load_acquire) down to be after AO_XSIZE_load_acquire definition. * src/atomic_ops/generalize-small.template (AO_XSIZE_store): Move definition (which is based on AO_XSIZE_store_release) down to be after AO_XSIZE_store_release definition. * src/atomic_ops/generalize-small.h : Regenerate. --- src/atomic_ops/generalize-small.h | 60 ++++++++++++------------ src/atomic_ops/generalize-small.template | 20 ++++---- 2 files changed, 40 insertions(+), 40 deletions(-) diff --git a/src/atomic_ops/generalize-small.h b/src/atomic_ops/generalize-small.h index 2b17f21..076b4cb 100644 --- a/src/atomic_ops/generalize-small.h +++ b/src/atomic_ops/generalize-small.h @@ -21,16 +21,16 @@ */ /* char_load */ -#if defined(AO_HAVE_char_load_acquire) && !defined(AO_HAVE_char_load) -# define AO_char_load(addr) AO_char_load_acquire(addr) -# define AO_HAVE_char_load -#endif - #if defined(AO_HAVE_char_load_full) && !defined(AO_HAVE_char_load_acquire) # define AO_char_load_acquire(addr) AO_char_load_full(addr) # define AO_HAVE_char_load_acquire #endif +#if defined(AO_HAVE_char_load_acquire) && !defined(AO_HAVE_char_load) +# define AO_char_load(addr) AO_char_load_acquire(addr) +# define AO_HAVE_char_load +#endif + #if defined(AO_HAVE_char_load_full) && !defined(AO_HAVE_char_load_read) # define AO_char_load_read(addr) AO_char_load_full(addr) # define AO_HAVE_char_load_read @@ -100,16 +100,16 @@ #endif /* !AO_NO_DD_ORDERING */ /* char_store */ -#if defined(AO_HAVE_char_store_release) && !defined(AO_HAVE_char_store) -# define AO_char_store(addr, val) AO_char_store_release(addr,val) -# define AO_HAVE_char_store -#endif - #if defined(AO_HAVE_char_store_full) && !defined(AO_HAVE_char_store_release) # define AO_char_store_release(addr,val) AO_char_store_full(addr,val) # define AO_HAVE_char_store_release #endif +#if defined(AO_HAVE_char_store_release) && !defined(AO_HAVE_char_store) +# define AO_char_store(addr, val) AO_char_store_release(addr,val) +# define AO_HAVE_char_store +#endif + #if defined(AO_HAVE_char_store_full) && !defined(AO_HAVE_char_store_write) # define AO_char_store_write(addr,val) AO_char_store_full(addr,val) # define AO_HAVE_char_store_write @@ -647,16 +647,16 @@ */ /* short_load */ -#if defined(AO_HAVE_short_load_acquire) && !defined(AO_HAVE_short_load) -# define AO_short_load(addr) AO_short_load_acquire(addr) -# define AO_HAVE_short_load -#endif - #if defined(AO_HAVE_short_load_full) && !defined(AO_HAVE_short_load_acquire) # define AO_short_load_acquire(addr) AO_short_load_full(addr) # define AO_HAVE_short_load_acquire #endif +#if defined(AO_HAVE_short_load_acquire) && !defined(AO_HAVE_short_load) +# define AO_short_load(addr) AO_short_load_acquire(addr) +# define AO_HAVE_short_load +#endif + #if defined(AO_HAVE_short_load_full) && !defined(AO_HAVE_short_load_read) # define AO_short_load_read(addr) AO_short_load_full(addr) # define AO_HAVE_short_load_read @@ -726,16 +726,16 @@ #endif /* !AO_NO_DD_ORDERING */ /* short_store */ -#if defined(AO_HAVE_short_store_release) && !defined(AO_HAVE_short_store) -# define AO_short_store(addr, val) AO_short_store_release(addr,val) -# define AO_HAVE_short_store -#endif - #if defined(AO_HAVE_short_store_full) && !defined(AO_HAVE_short_store_release) # define AO_short_store_release(addr,val) AO_short_store_full(addr,val) # define AO_HAVE_short_store_release #endif +#if defined(AO_HAVE_short_store_release) && !defined(AO_HAVE_short_store) +# define AO_short_store(addr, val) AO_short_store_release(addr,val) +# define AO_HAVE_short_store +#endif + #if defined(AO_HAVE_short_store_full) && !defined(AO_HAVE_short_store_write) # define AO_short_store_write(addr,val) AO_short_store_full(addr,val) # define AO_HAVE_short_store_write @@ -1273,16 +1273,16 @@ */ /* int_load */ -#if defined(AO_HAVE_int_load_acquire) && !defined(AO_HAVE_int_load) -# define AO_int_load(addr) AO_int_load_acquire(addr) -# define AO_HAVE_int_load -#endif - #if defined(AO_HAVE_int_load_full) && !defined(AO_HAVE_int_load_acquire) # define AO_int_load_acquire(addr) AO_int_load_full(addr) # define AO_HAVE_int_load_acquire #endif +#if defined(AO_HAVE_int_load_acquire) && !defined(AO_HAVE_int_load) +# define AO_int_load(addr) AO_int_load_acquire(addr) +# define AO_HAVE_int_load +#endif + #if defined(AO_HAVE_int_load_full) && !defined(AO_HAVE_int_load_read) # define AO_int_load_read(addr) AO_int_load_full(addr) # define AO_HAVE_int_load_read @@ -1352,16 +1352,16 @@ #endif /* !AO_NO_DD_ORDERING */ /* int_store */ -#if defined(AO_HAVE_int_store_release) && !defined(AO_HAVE_int_store) -# define AO_int_store(addr, val) AO_int_store_release(addr,val) -# define AO_HAVE_int_store -#endif - #if defined(AO_HAVE_int_store_full) && !defined(AO_HAVE_int_store_release) # define AO_int_store_release(addr,val) AO_int_store_full(addr,val) # define AO_HAVE_int_store_release #endif +#if defined(AO_HAVE_int_store_release) && !defined(AO_HAVE_int_store) +# define AO_int_store(addr, val) AO_int_store_release(addr,val) +# define AO_HAVE_int_store +#endif + #if defined(AO_HAVE_int_store_full) && !defined(AO_HAVE_int_store_write) # define AO_int_store_write(addr,val) AO_int_store_full(addr,val) # define AO_HAVE_int_store_write diff --git a/src/atomic_ops/generalize-small.template b/src/atomic_ops/generalize-small.template index 95f27c1..4cefce4 100644 --- a/src/atomic_ops/generalize-small.template +++ b/src/atomic_ops/generalize-small.template @@ -21,16 +21,16 @@ */ /* XSIZE_load */ -#if defined(AO_HAVE_XSIZE_load_acquire) && !defined(AO_HAVE_XSIZE_load) -# define AO_XSIZE_load(addr) AO_XSIZE_load_acquire(addr) -# define AO_HAVE_XSIZE_load -#endif - #if defined(AO_HAVE_XSIZE_load_full) && !defined(AO_HAVE_XSIZE_load_acquire) # define AO_XSIZE_load_acquire(addr) AO_XSIZE_load_full(addr) # define AO_HAVE_XSIZE_load_acquire #endif +#if defined(AO_HAVE_XSIZE_load_acquire) && !defined(AO_HAVE_XSIZE_load) +# define AO_XSIZE_load(addr) AO_XSIZE_load_acquire(addr) +# define AO_HAVE_XSIZE_load +#endif + #if defined(AO_HAVE_XSIZE_load_full) && !defined(AO_HAVE_XSIZE_load_read) # define AO_XSIZE_load_read(addr) AO_XSIZE_load_full(addr) # define AO_HAVE_XSIZE_load_read @@ -100,16 +100,16 @@ #endif /* !AO_NO_DD_ORDERING */ /* XSIZE_store */ -#if defined(AO_HAVE_XSIZE_store_release) && !defined(AO_HAVE_XSIZE_store) -# define AO_XSIZE_store(addr, val) AO_XSIZE_store_release(addr,val) -# define AO_HAVE_XSIZE_store -#endif - #if defined(AO_HAVE_XSIZE_store_full) && !defined(AO_HAVE_XSIZE_store_release) # define AO_XSIZE_store_release(addr,val) AO_XSIZE_store_full(addr,val) # define AO_HAVE_XSIZE_store_release #endif +#if defined(AO_HAVE_XSIZE_store_release) && !defined(AO_HAVE_XSIZE_store) +# define AO_XSIZE_store(addr, val) AO_XSIZE_store_release(addr,val) +# define AO_HAVE_XSIZE_store +#endif + #if defined(AO_HAVE_XSIZE_store_full) && !defined(AO_HAVE_XSIZE_store_write) # define AO_XSIZE_store_write(addr,val) AO_XSIZE_store_full(addr,val) # define AO_HAVE_XSIZE_store_write -- 2.49.0