Contents Up << >>

Wait statements

The wait statement provides a more flexible way to specify how a process should be suspended and resumed. A process without a sensitivity list may contain 0 or more wait statements. There are three main components in the wait statement, shown in the following rule: When the wait statement is encountered, the process is unconditionally suspended. The three parts of the wait statement specify when the process may be resumed. The sensitivity list is a list of signals that will cause the process to resume if an event occurs on them. If the condition part appears, then when an event occurs on a signal in the sensitivity list or referenced in the condition expression, the condition expression is evaluated and the process is resumed only if the resulting value is true. The time expression specifies a time out value. When the wait statement is first encountered, the expression is evaluated and the result is the maximum time that the process may be suspended regardless of a sensitivity-list or condition clause. If none of the three parts is used, then the process will never resume.