Re: WaitForSingleObject() will not deadlock
- From: "Doug Harrison [MVP]" <dsh@xxxxxxxx>
- Date: Tue, 03 Jul 2007 18:49:15 -0500
On Tue, 03 Jul 2007 17:18:24 -0400, Joseph M. Newcomer
<newcomer@xxxxxxxxxxxx> wrote:
I agree. It makes no sense, athough the term "memory visibility guarantees" is not
actually defined anywhere I can find; the apparent interpretation that it guarantees that
all memory is consistent seems fundamental to any kind of locking structure. Otherwise,
the locks cannot possibly work.
See "Memory Ordering" here:
http://msdn2.microsoft.com/en-us/library/ms686355.aspx
In "Programming with POSIX Threads", Butenhof devotes a number of pages to
"Memory visibility between threads"; here's a link to page 89 where he
gives four rules POSIX obeys:
http://books.google.com/books?id=_xvnuFzo7q0C&pg=PA88&ots=Kl5R_S-7Y9&dq=%22memory+visibility%22+isbn:0201633922&num=50&sig=2L0dMbDOavxA9VVnDA2Ai28gIF8#PPA89,M1
--
Doug Harrison
Visual C++ MVP
.
- Follow-Ups:
- Re: WaitForSingleObject() will not deadlock
- From: Joseph M . Newcomer
- Re: WaitForSingleObject() will not deadlock
- References:
- Re: WaitForSingleObject() will not deadlock
- From: Joseph M . Newcomer
- Re: WaitForSingleObject() will not deadlock
- From: Frank Cusack
- Re: WaitForSingleObject() will not deadlock
- From: Joseph M . Newcomer
- Re: WaitForSingleObject() will not deadlock
- From: Alexander Grigoriev
- Re: WaitForSingleObject() will not deadlock
- From: Frank Cusack
- Re: WaitForSingleObject() will not deadlock
- From: Alexander Grigoriev
- Re: WaitForSingleObject() will not deadlock
- From: Frank Cusack
- Re: WaitForSingleObject() will not deadlock
- From: Doug Harrison [MVP]
- Re: WaitForSingleObject() will not deadlock
- From: Joseph M . Newcomer
- Re: WaitForSingleObject() will not deadlock
- Prev by Date: Re: Text window not displaying inside loop
- Next by Date: Re: Inheritance and MFC
- Previous by thread: Re: WaitForSingleObject() will not deadlock
- Next by thread: Re: WaitForSingleObject() will not deadlock
- Index(es):
Relevant Pages
|