Hardware Reference
In-Depth Information
acq1
acq2
edge1
edge2
disp
shape
H
rec
Figure 2.8
Precedence task graph associated with the industrial application illustrated in
Figure 2.7.
acquisition task completes. Task shape is based on the object contour extracted by the
low-level image processing; therefore, it must wait for the termination of both edge1
and edge2 . The same is true for task disp , which however can be executed in parallel
with task shape . Then, task H can only start as disp completes and, finally, task rec
must wait the completion of H and shape . The resulting precedence graph is shown in
Figure 2.8.
2.2.3
RESOURCE CONSTRAINTS
From a process point of view, a resource is any software structure that can be used by
the process to advance its execution. Typically, a resource can be a data structure, a
set of variables, a main memory area, a file, a piece of program, or a set of registers of
a peripheral device. A resource dedicated to a particular process is said to be private ,
whereas a resource that can be used by more tasks is called a shared resource .
To maintain data consistency, many shared resources do not allow simultaneous ac-
cesses by competing tasks, but require their mutual exclusion. This means that a task
cannot access a resource R if another task is inside R manipulating its data structures.
In this case, R is called a mutually exclusive resource . A piece of code executed under
mutual exclusion constraints is called a critical section .
Search WWH ::




Custom Search