For Students
Sunday, 11 March 2012
Bounded-Buffer
Producer process
item
nextProduced
;
while (1) {
while (counter == BUFFER_SIZE)
; /* do nothing */
buffer[in] =
nextProduced
;
in = (in + 1) % BUFFER_SIZE;
counter++;
}
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment