- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
do queuing_mutex and spin_mutex are categorized under monitors>>??and what is blocking synchronization..and if we want to do enqueue and dequeue elements in a queue parallel could it be possible by these mutexes??
Link Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Quoting - praveen.satishgmail.com
do queuing_mutex and spin_mutex are categorized under monitors>>??and what is blocking synchronization..and if we want to do enqueue and dequeue elements in a queue parallel could it be possible by these mutexes??
Yes both the queuing mutex and the spin mutex can be used to implement monitors ala Per Brinch Hansenand as such you could use them to write functions to enqueue and dequeue elements in parallel. Or you could just use the TBB concurrent_queue, which has the monitors built in to provide thread safe enqueue/dequeue functions.
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page