On Fri, Oct 19, 2018 at 5:41 PM Anthony Williams <anthony....@gmail.com> wrote:
>
> On 19/10/2018 17:15, Dmitry Vyukov wrote:
> > On Thu, Oct 18, 2018 at 10:02 AM Anthony Williams <anthony....@gmail.com> 
> > wrote:
> >>
> >> On 18/10/2018 09:23, 饶萌 wrote:
> >>> I've just created a real wait-free MPMC queue in 100+ lines of C++11
> >>> code: WFMPMC <https://github.com/MengRao/WFMPMC>.
> >>>
> >>> Appreciate it if you can help check.
> >>
> >> This is not wait free. If you have two writers, and both take an index.
> >> The writer with the lower index then gets suspended, but the writer with
> >> the higher index completes.
> >>
> >> Now, the next reader has to wait, because the slot it is trying to read
> >> from isn't complete yet, even though there is ready data in another slot.
> >
> > Hi Anthony,
> >
> > This sounds more like non-linerizable rather then non-wait-free.
>
> For something to be wait-free, you can suspend any subset of threads
> indefinitely and all other threads will proceed OK.
>
> In this case, if a thread is suspended mid-insert then other threads
> will be unable to proceed, even when there is meaningful work to be done.

You are right!
But non-linearazible too.

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"Scalable Synchronization Algorithms" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to lock-free+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/lock-free/CAEeQi3vhXmK-hGEMDQOWPg_RpeTdY2W9BuZ_zFv%3DBE05chxK6Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to