Efficiently Controlling Communication in Ada using Preference Control

The need for simple, readable and efficient communication software in Ada is apparent. This paper suggests an elegant and efficient solution for real time communication software that considers the urgency of a message and the security level associated with such messages. We propose the use of the preference control construct, "pref", for the explicit control of preferences among different entries within the select statement. The preference control construct makes our solution much more readable, understandable, easy to modify and more efficient. We argue the necessity for the preference control construct in Ada. We also give a possible solution without the use of explicit preference control; but the resulting software does not measure up to the high quality software engineering standards that are attained with the use of explicit preference control. An example of message routing software is included in this paper. The advantages of using explicit preference control are discussed from two complementary aspects. First, the run time analysis shows that the response time is much faster using explicit preference control. The response time is obviously a very important constraint on military communication software. Secondly, we state a general principle called the branching wide horizons principle, which captures the necessary expressive power needed for the efficient control of communication. The preference control used in our communication is a natural implementation of this principle.