| OCR Text |
Show 131 if (event.evaddr >= LOWER_ADDRESS kk event.evaddr <= UPPER.ADDRESS kk event.evold == 0 kk event.evres != 0) return(l); return(O); Constants LOWER.ADDRESS and UPPER.ADDRESS represent array bounds. 5.2.6 Complex Monitoring Operations Filter covers only a subset of monitoring operations. Usually, the monitoring task is divided between the filter and the director. Since the director is a regular program, it can perform any computable monitoring function subject to time and space constraints. Parts of the monitoring task that cannot be performed by the filter are performed by the director. An example is the director to display control flow that was described in Section 4.5. The monitoring task is divided between the filter and the director. The filter reports events that change control flow. The director performs the mapping from events to a display on the screen. Some applications may require that parameters in the filter are dynamically changed. One example is the monitoring of linked data structures described in Section 4.5. Since it is impossible to predict the address of elements in advance, the filter can be only set dynamically after the actual allocation of space. An unrealistic example of a monitoring function is to check if the sum of the results of the last five additions is a prime. A simple filter that operates on an individual event is not able to combine values from separate events. The only support it can offer to the director is to signal each time an addition is completed. The director must maintain the last five values and check if their sum is a prime. This example illustrates how an arbitrary complex monitoring task can be specified. |