SMP: Optimize ticket lock implementation

This reverts the relevant part of commit
da06fe948c.  The acquire/release order is
superfluous for the next ticket increment.  The mutual exclusion is
guaranteed by the acquire load from and release store to the next
serving atomic variable.
This commit is contained in:
Sebastian Huber
2015-10-02 07:59:24 +02:00
parent 08317ef3ff
commit ba1ed5240b

View File

@@ -277,7 +277,7 @@ static inline void _SMP_ticket_lock_Do_acquire(
#endif #endif
my_ticket = my_ticket =
_Atomic_Fetch_add_uint( &lock->next_ticket, 1U, ATOMIC_ORDER_ACQ_REL ); _Atomic_Fetch_add_uint( &lock->next_ticket, 1U, ATOMIC_ORDER_RELAXED );
#if defined( RTEMS_PROFILING ) #if defined( RTEMS_PROFILING )
now_serving = now_serving =