Lightning Talk: A Spinlock Implementation - Fedor Pikus - CppNow 2022

Ғылым және технология

CppNow Website: www.cppnow.org​
CppNow Twitter: @CppNow​
---
Lightning Talk: A Spinlock Implementation - Fedor Pikus - CppNow 2022
---
Fedor Pikus presents this CppNow lightning talk on "A Spinlock Implementation" at the CppNow 2022 C++ conference held in Aspen, Colorado.
---
Fedor Pikus
---
Videos Filmed & Edited By Bash Films bashfilms.com/
KZread Channel Managed By Digital Medium Ltd: events.digital-medium.co.uk
#Boost​ #Cpp​ #CppNow​

Пікірлер: 9

  • @denispronin2417
    @denispronin2417 Жыл бұрын

    The second question is whether yield() call really works worse than just calling nanosleep, is it true? Linux kernel, when you call yield(), utilizes system call that does nothing but schedule() that places the current task at the end of the TASK_RUNNING process ready-to-work queue. I can't explain to myself why it is not the fastest way to give the CPU in and take it back as soon as possible

  • @bogdanivanovic3176
    @bogdanivanovic3176 Жыл бұрын

    thanks man you are great. you got a new subscriber :)

  • @piotrarturklos
    @piotrarturklos Жыл бұрын

    Awesome! And it's a lightning talk, which is more awesome still.

  • @BoostCon

    @BoostCon

    Жыл бұрын

    Glad you like it!

  • @joachimjoyaux179
    @joachimjoyaux179 Жыл бұрын

    Impressive ! thanks

  • @BoostCon

    @BoostCon

    Жыл бұрын

    Thanks for watching and commenting.

  • @denispronin2417
    @denispronin2417 Жыл бұрын

    How do you cope with preemption that you cannot control in userspace but you're able to control in kernel space? Suppose, you locked a spinlock and while being in critical section you were rescheduled and placed in the wait list, suspended and waited for the next portion of time to continue executing. Other threads will definitely be stuck on spinning around the locked spinlock. Do I correctly understand that your nanosleep technique will help to reschedule the tasks stuck on spinning around the spinlock letting eventually the task that owns the spinlock exit the wait list and continue executing in critical section?

  • @JoJo-fy2vb
    @JoJo-fy2vb Жыл бұрын

    what about `__builtin_ia32_pause()` / this_thread::yield() as opposed to nanosleep?

  • @peterfeatherstone9768
    @peterfeatherstone9768 Жыл бұрын

    Is there a way to turn this into a recursive spinlock?

Келесі