Date: Mon, 30 Aug 2021 21:28:58 +0300
On Mon, 30 Aug 2021 at 21:25, Thiago Macieira <thiago_at_[hidden]> wrote:
>
> On Monday, 30 August 2021 10:29:48 PDT Ville Voutilainen wrote:
> > > Anyway, can I ask that we get a spinlock before we get a mutex? Before
> > > C++17 it was impossible to get it right with std::atomic_flag; right,
> > > it's just non- obvious.
> >
> > The marching order of an atomic_mutex and spinlock is completely
> > non-obvious to me, I happily don't program
> > at these levels much, so I'll also happily defer this to Marko. :)
>
> mutex = spinlock + futex (wait / wake) + optional goodies
Oh, I know where it sits in the abstraction-hierarchy of these things,
but that doesn't make
it in any way obvious that it should go first.
>
> On Monday, 30 August 2021 10:29:48 PDT Ville Voutilainen wrote:
> > > Anyway, can I ask that we get a spinlock before we get a mutex? Before
> > > C++17 it was impossible to get it right with std::atomic_flag; right,
> > > it's just non- obvious.
> >
> > The marching order of an atomic_mutex and spinlock is completely
> > non-obvious to me, I happily don't program
> > at these levels much, so I'll also happily defer this to Marko. :)
>
> mutex = spinlock + futex (wait / wake) + optional goodies
Oh, I know where it sits in the abstraction-hierarchy of these things,
but that doesn't make
it in any way obvious that it should go first.
Received on 2021-08-30 13:29:13