01.06.2014 Views

Concurrent Systems II - Bad Request - Trinity College Dublin

Concurrent Systems II - Bad Request - Trinity College Dublin

Concurrent Systems II - Bad Request - Trinity College Dublin

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Problems<br />

• Voluntary<br />

◾Mutexes ‘protect’ code.<br />

◾Other programmers don’t have to use them to get access to the<br />

variables the code accesses.<br />

• Unfair<br />

• This is part of the tradeoff. Use processes rather than threads if you<br />

want better protection.<br />

◾If multiple threads are blocked on a mutex, the order in which<br />

they waken up is not guaranteed to be any particular order.<br />

54<br />

<strong>Trinity</strong> <strong>College</strong> <strong>Dublin</strong><br />

© Mike Brady 2007

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!