Adjust link buffer sizes to the size of the messages

Use the MSC logical link statistics to determine what the messages sizes are for an MSC link and adjust the buffer sizes for the link and message queues so that most messages can be received with a single I/O operation and two QGET (one GU and one DEQ) calls.

The high, low, and average message size statistics returned by the type-2 command QUERY MSLINK are derived from the total sizes of the messages in the send and receive message queues, including the prefix data and user data segments, as they are logged in the X'01' and X'03' log records.

Adjust the buffer sizes so that IMS uses no more than a single I/O operation and two QMGR calls to either send or receive a message on an MSC link: two QGET calls (one GU and one DEQ) and two QPUT calls (one ISRT and one ENQ).

The QPUT calls on the sending side of an MSC link operate differently from the QGET calls on the receiving side of an MSC link. Each QPUT call is for a message segment, and each QGET GU call is for a message queue buffer. A message with two user segments in one queue buffer requires three QPUT calls (two ISRT calls and one ENQ call) and two QGET calls (one GU call and one DEQ call). For single segment messages, IMS uses the same number of QPUT and QGET calls on each side of an MSC link.