[parsec-users] How are pipeline threads synchronized in Dedup?
ybao at CS.Princeton.EDU
Sat Mar 31 10:40:38 EDT 2012
The synchronization operations are in these two functions -- enqueue() and dequeue() -- in the queue.c file.
Dedup uses pthread_cond_wait() and pthread_cond_signal() to synchronize the producers and consumers of one queue.
----- Original Message -----
From: "Akshatha mulki Bhat" <fdm546 at my.utsa.edu>
To: "PARSEC Users" <parsec-users at lists.cs.princeton.edu>
Sent: Friday, March 30, 2012 6:30:27 PM
Subject: [parsec-users] How are pipeline threads synchronized in Dedup?
I have a very basic question on the pipeline implementation of Dedup in PARSEC.
I understand that there are many threads (maximum being MAX_THREADS_PER_QUEUE) working on a single queue at the intermediate pipeline stages. In order to enqueue/dequeue items into the queue, there is a counter variable(for ex: tmp_count) which keeps track of the number of items to enqueue at a time(this is implemented for chunking purpose, i.e., atleast ITEMS_PER_FETCH amount of items are eneuqued/dequeued, in order to avoid lock contention on the queues). Although, what I don't understand is how are these counter variables synchronized among all the threads which work at the same time on a queue? Please let me know in these regards.
parsec-users mailing list
parsec-users at lists.cs.princeton.edu
More information about the parsec-users