redesign cross-thread registration/signalling system
authorPaul Davis <paul@linuxaudiosystems.com>
Mon, 28 Dec 2015 15:14:17 +0000 (10:14 -0500)
committerPaul Davis <paul@linuxaudiosystems.com>
Mon, 28 Dec 2015 15:14:17 +0000 (10:14 -0500)
commit0d9efc11484c901795ff4e9549a1a39715d0474d
tree956ab3cd570670bcb1ff68856553f5aec4a8e470
parentdb4834027858b10f313c822c7fb3fad1617f11aa
redesign cross-thread registration/signalling system

This new design will work even when threads that need to receive
messages from RT threads are created *after* the RT threads. The
existing design would fail because the RT thread(s) would never
be known the later created threads, and so signals emitted by the
RT thread and causing call_slot() in the receiver would end up
being enqueued using a lock-protected list. The new design ensures
that communication always uses a lock-free FIFO instead
25 files changed:
gtk2_ardour/strip_silence_dialog.cc
libs/ardour/ardour/control_protocol_manager.h
libs/ardour/ardour/midi_ui.h
libs/ardour/audioengine.cc
libs/ardour/control_protocol_manager.cc
libs/ardour/globals.cc
libs/ardour/midi_ui.cc
libs/gtkmm2ext/gtk_ui.cc
libs/pbd/event_loop.cc
libs/pbd/pbd/abstract_ui.cc
libs/pbd/pbd/abstract_ui.h
libs/pbd/pbd/event_loop.h
libs/pbd/pbd/pthread_utils.h
libs/pbd/pthread_utils.cc
libs/surfaces/control_protocol/control_protocol/control_protocol.h
libs/surfaces/faderport/faderport.cc
libs/surfaces/faderport/faderport.h
libs/surfaces/faderport/faderport_interface.cc
libs/surfaces/mackie/interface.cc
libs/surfaces/mackie/mackie_control_protocol.cc
libs/surfaces/mackie/mackie_control_protocol.h
libs/surfaces/osc/interface.cc
libs/surfaces/osc/osc.cc
libs/surfaces/osc/osc.h
libs/surfaces/wiimote/wiimote.cc