There are HAVE_ATOMIC_BUILTINS and HAVE_ATOMIC_BUILTINS_64 macros'.
MONITOR_ATOMIC_INC is defined as MONITOR_MUTEX_INC for case when HAVE_ATOMIC_BUILTINS_64 is not defined.
Other places do check like:
# if defined(HAVE_ATOMIC_BUILTINS) && UNIV_WORD_SIZE == 8
In Lucid 32-bit HAVE_ATOMIC_BUILTINS is defined, HAVE_ATOMIC_BUILTINS_64 is not defined and MONITOR_ATOMIC_INC is in fact trying to use mutex because it is shortcut for MONITOR_MUTEX_INC in this case.
Fix is to check HAVE_ATOMIC_BUILTINS_64 or HAVE_ATOMIC_BUILTINS and UNIV_WORD_SIZE.
It is totally counter-intuitive
There are HAVE_ATOMIC_ BUILTINS and HAVE_ATOMIC_ BUILTINS_ 64 macros'.
MONITOR_ATOMIC_INC is defined as MONITOR_MUTEX_INC for case when HAVE_ATOMIC_ BUILTINS_ 64 is not defined.
Other places do check like:
# if defined( HAVE_ATOMIC_ BUILTINS) && UNIV_WORD_SIZE == 8
In Lucid 32-bit HAVE_ATOMIC_ BUILTINS is defined, HAVE_ATOMIC_ BUILTINS_ 64 is not defined and MONITOR_ATOMIC_INC is in fact trying to use mutex because it is shortcut for MONITOR_MUTEX_INC in this case.
Fix is to check HAVE_ATOMIC_ BUILTINS_ 64 or HAVE_ATOMIC_ BUILTINS and UNIV_WORD_SIZE.