开发者

Importance of Critical region and Monitors as Synchronization mechanism

I read in many text books that critical region and monitors are high-level language mechanisms to provide synchronization mechanism.

I couldn't find a simpler explanation about these in any text. I have some doubts on these.

How compiler actually implements these?

Whether t开发者_如何学JAVAhese things are available in C, Java, Python . . ?

What is the importance of conditional constructs in monitors and critical region (conditional critical region)


In java, monitors are a built-in element of the language. They are accessed by the synchronized keyword, and have several functions related to them (such as wait()). You can google it to find out more about it.

Regarding how it is implemented, There are several algorithms that implement monitors, with different pros and cons. If you are interested in this, allow me to recommend Herlihy and Shavit's book - the art of multiprocessor programming.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜