STREAMS-UX Programmer's Guide (February 2007)

Synchronization Levels
Elsewhere Level Synchronization
Appendix F
285
Elsewhere Level Synchronization
The elsewhere level synchronization serializes a group of different modules. This synchronization ensures
that only one request to the entire group of modules can be processed at a time. Requests to other queues that
are not in this group can run concurrently.
For example, if the echo and dlpi drivers in Figure F-1, “Synchronization Levels,” are configured to be
members of an elsewhere synchronization group, and the sad driver is configured to be in a different
elsewhere group, then only one driver function in ECHO-A, ECHO-B and DLPI-A can run at a time. However,
a function in ECHO-A, ECHO-B or DLPI-A can run in parallel with a function in SAD-A.
Modules in a group can share data, since no two functions in a module group can run concurrently under the
elsewhere level synchronization.
Global Level Synchronization
The global level synchronization serializes all the requests to the modules configured at the global level
synchronization. Only one request to all modules under the global level synchronization can be processed at a
time. Requests to modules that are not configured under global level synchronization can run concurrently.
For example, in Figure F-1,Synchronization Levels,if the echo, dlpi, and sad drivers are configured for
global synchronization, only one driver function in ECHO-A, ECHO-B, DLPI-A, and SAD-A can run at a time.
However, one of these drivers could run in parallel with a module configured for a different synchronization
level.
All modules configured with global synchronization can share data.
Global level synchronization may cause a system-wide performance impact. Therefore, it is highly
recommended not to use global level synchronization.
NOSYNC Level synchronization
NOSYNC level synchronization provides the highest level of concurrency. For a given queue, it allows
multiple requests to be processed at the same time. Requests to different queues can run in parallel.
For example, if the echo driver in Figure F-1 is configured for NOSYNC synchronization, STREAMS/UX
cannot run the following procedures concurrently:
Multiple instances of ECHO-A's echo_rsrv procedures.
Multiple instances of ECHO-A's echo_wsrv procedures.
However, in this synchronization mode, STREAMS/UX can run the following procedures concurrently:
Multiple instances of ECHO-A's echo_rput procedures.
Multiple instances of ECHO-A's echo_wput procedures
Multiple instances of ECHO-A's echo_rput and a single instance of echo_rsrv procedures.