Re: [HACKERS] Race conditions in shm_mq.c

2015-08-07 Thread Robert Haas
On Thu, Aug 6, 2015 at 5:59 PM, Antonin Houska wrote: > Robert Haas wrote: >> On Thu, Aug 6, 2015 at 2:38 PM, Robert Haas wrote: >> > On Thu, Aug 6, 2015 at 10:10 AM, Antonin Houska wrote: >> >> During my experiments with parallel workers I sometimes saw the "master" >> >> and >> >> worker pro

Re: [HACKERS] Race conditions in shm_mq.c

2015-08-06 Thread Antonin Houska
Robert Haas wrote: > On Thu, Aug 6, 2015 at 2:38 PM, Robert Haas wrote: > > On Thu, Aug 6, 2015 at 10:10 AM, Antonin Houska wrote: > >> During my experiments with parallel workers I sometimes saw the "master" > >> and > >> worker process blocked. The master uses shm queue to send data to the >

Re: [HACKERS] Race conditions in shm_mq.c

2015-08-06 Thread Robert Haas
On Thu, Aug 6, 2015 at 2:38 PM, Robert Haas wrote: > On Thu, Aug 6, 2015 at 10:10 AM, Antonin Houska wrote: >> During my experiments with parallel workers I sometimes saw the "master" and >> worker process blocked. The master uses shm queue to send data to the worker, >> both sides nowait==false.

Re: [HACKERS] Race conditions in shm_mq.c

2015-08-06 Thread Robert Haas
On Thu, Aug 6, 2015 at 10:10 AM, Antonin Houska wrote: > During my experiments with parallel workers I sometimes saw the "master" and > worker process blocked. The master uses shm queue to send data to the worker, > both sides nowait==false. I concluded that the following happened: > > The worker

[HACKERS] Race conditions in shm_mq.c

2015-08-06 Thread Antonin Houska
During my experiments with parallel workers I sometimes saw the "master" and worker process blocked. The master uses shm queue to send data to the worker, both sides nowait==false. I concluded that the following happened: The worker process set itself as a receiver on the queue after shm_mq_wait_i