From: Ivan Maidanski Date: Mon, 3 Sep 2018 20:21:18 +0000 (+0300) Subject: Eliminate 'redundant blank line at start/end of block' CodeFactor warning X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=44fbab31e3aeb64b750b3b165ffbac98f4ccb691;p=libatomic_ops Eliminate 'redundant blank line at start/end of block' CodeFactor warning (code refactoring) * src/atomic_ops/sysdeps/armcc/arm_v6.h (AO_test_and_set): Remove redundant blank line at the start of a code block. * src/atomic_ops/sysdeps/hpc/ia64.h (AO_fetch_compare_and_swap_release, AO_char_fetch_compare_and_swap_acquire, AO_char_fetch_compare_and_swap_release, AO_short_fetch_compare_and_swap_acquire, AO_short_fetch_compare_and_swap_release): Remove redundant blank line at the end of a code block. --- diff --git a/src/atomic_ops/sysdeps/armcc/arm_v6.h b/src/atomic_ops/sysdeps/armcc/arm_v6.h index 03aa1d6..ad48b9c 100644 --- a/src/atomic_ops/sysdeps/armcc/arm_v6.h +++ b/src/atomic_ops/sysdeps/armcc/arm_v6.h @@ -100,7 +100,6 @@ __asm { #ifndef AO_PREFER_GENERALIZED AO_INLINE AO_TS_VAL_t AO_test_and_set(volatile AO_TS_t *addr) { - AO_TS_VAL_t oldval; unsigned long tmp; unsigned long one = 1; diff --git a/src/atomic_ops/sysdeps/hpc/ia64.h b/src/atomic_ops/sysdeps/hpc/ia64.h index e71f5e8..061e55b 100644 --- a/src/atomic_ops/sysdeps/hpc/ia64.h +++ b/src/atomic_ops/sysdeps/hpc/ia64.h @@ -100,7 +100,6 @@ AO_fetch_compare_and_swap_release(volatile AO_t *addr, AO_t old_val, _Asm_mov_to_ar(_AREG_CCV, old_val, _UP_MEM_FENCE); return _Asm_cmpxchg(AO_T_SIZE, _SEM_REL, addr, new_val, _LDHINT_NONE, _UP_MEM_FENCE); - } #define AO_HAVE_fetch_compare_and_swap_release @@ -111,7 +110,6 @@ AO_char_fetch_compare_and_swap_acquire(volatile unsigned char *addr, _Asm_mov_to_ar(_AREG_CCV, old_val, _DOWN_MEM_FENCE); return _Asm_cmpxchg(_SZ_B, _SEM_ACQ, addr, new_val, _LDHINT_NONE, _DOWN_MEM_FENCE); - } #define AO_HAVE_char_fetch_compare_and_swap_acquire @@ -122,7 +120,6 @@ AO_char_fetch_compare_and_swap_release(volatile unsigned char *addr, _Asm_mov_to_ar(_AREG_CCV, old_val, _UP_MEM_FENCE); return _Asm_cmpxchg(_SZ_B, _SEM_REL, addr, new_val, _LDHINT_NONE, _UP_MEM_FENCE); - } #define AO_HAVE_char_fetch_compare_and_swap_release @@ -134,7 +131,6 @@ AO_short_fetch_compare_and_swap_acquire(volatile unsigned short *addr, _Asm_mov_to_ar(_AREG_CCV, old_val, _DOWN_MEM_FENCE); return _Asm_cmpxchg(_SZ_B, _SEM_ACQ, addr, new_val, _LDHINT_NONE, _DOWN_MEM_FENCE); - } #define AO_HAVE_short_fetch_compare_and_swap_acquire @@ -146,7 +142,6 @@ AO_short_fetch_compare_and_swap_release(volatile unsigned short *addr, _Asm_mov_to_ar(_AREG_CCV, old_val, _UP_MEM_FENCE); return _Asm_cmpxchg(_SZ_B, _SEM_REL, addr, new_val, _LDHINT_NONE, _UP_MEM_FENCE); - } #define AO_HAVE_short_fetch_compare_and_swap_release