Chapter 16. Project: Producer Consumer Synchronization

Team-FLY

This chapter focuses on variations of producer-consumer synchronization using mutex locks, semaphores, condition variables and signals. Implementations for different types of stopping conditions are developed with careful attention to error handling and shutdown. The chapter describes two projects, a parallel file copy and a print server. The parallel file copy uses bounded buffers; the print server uses unbounded buffers.

Objectives

  • Learn about producer-consumer synchronization

  • Experiment with complex synchronization problems

  • Explore how ending conditions affect synchronization

  • Use a large number of threads in a realistic application

  • Understand thread interaction and synchronization

Team-FLY


Unix Systems Programming
UNIX Systems Programming: Communication, Concurrency and Threads
ISBN: 0130424110
EAN: 2147483647
Year: 2003
Pages: 274

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net