cyclonedds/src
Erik Boasson ba46cb1140 rework listener invocation and entity status flags
Listener/status management invocation was rather expensive, and
especially the cost of checking listeners, then setting status flags and
triggering waitsets ran into severe lock contention.

A major cost was the repeated use of dds_entity_lock and
dds_entity_unlock, these have been eliminated.  Another cost was that
each time an event occurred (with DATA_AVAILABLE the most problematic
one) it would walk the chain of ancestors to see if any had a relevant
listener, and only if none of them had any, it would set the status
flags.

The locking/unlocking of the entity has been eliminated by moving the
listener/status flag manipulation from the general entity lock to its
m_observers_lock.  That lock has a much smaller scope, and consequently
contention has been significantly reduced.

Instead of walking the entity hierarchy looking for listeners, an entity
now inherits the ancestors' listeners.  The set_listener operation has
been made a little more complicated by the need to not only set the
listeners for the specified entity, but to also update any inherited
listeners its descendants.

The commit is a bit larger than strictly needed ... I've started
reformatting the code to reduce the variety of styles ... as there I
haven't been able to find a single tool that does what I want, it may
well end up as manual work.

Signed-off-by: Erik Boasson <eb@ilities.com>
2019-01-17 10:18:14 +01:00
..
cmake Remove unnecessary CMake modules and fixup os/CMakeLists.txt 2019-01-07 18:15:07 +01:00
core rework listener invocation and entity status flags 2019-01-17 10:18:14 +01:00
docs Rename get and set of enabled status to mask 2018-12-11 11:07:09 +01:00
etc Let dds_create_participant determine domain id if config specifies "any" (new default) 2018-10-14 14:02:47 +08:00
examples trivial modifications to pacify gcc -O2 and clang --analyze 2019-01-02 15:03:20 +01:00
idlc Fix build with openJDK-10 2018-06-23 21:51:21 +02:00
os skip testing lookup of an invalid hostname, it times out in some configurations 2019-01-17 10:18:14 +01:00
scripts Initial contribution 2018-04-10 17:03:59 +02:00
tools fix formatting error for durations in ddsls 2019-01-09 08:38:56 +01:00
util Remove unnecessary CMake modules and fixup os/CMakeLists.txt 2019-01-07 18:15:07 +01:00
CMakeLists.txt enable tons of warnings in Xcode 2019-01-17 10:18:14 +01:00