Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CpuBoundWork#CpuBoundWork(): don't spin on atomic int to acquire slot #9990

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Commits on Feb 20, 2024

  1. Configuration menu
    Copy the full SHA
    48db480 View commit details
    Browse the repository at this point in the history
  2. /v1/events: just release CpuBoundWork instead of using IoBoundWorkSlot

    IoBoundWorkSlot#~IoBoundWorkSlot() will wait for a free semaphore slot
    which will be almost immediately released by CpuBoundWork#~CpuBoundWork().
    Just releasing the already aquired slot via CpuBoundWork#Done()
    is more efficient.
    Al2Klimov committed Feb 20, 2024
    Configuration menu
    Copy the full SHA
    02afd55 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    d34c754 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    f70bf0e View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    b899611 View commit details
    Browse the repository at this point in the history

Commits on Feb 22, 2024

  1. CpuBoundWork#CpuBoundWork(): don't spin on atomic int to acquire slot

    This is inefficient and involves unfair scheduling. The latter implies
    possible bad surprises regarding waiting durations on busy nodes. Instead,
    use AsioConditionVariable#Wait() if there are no free slots. It's notified
    by others' CpuBoundWork#~CpuBoundWork() once finished.
    Al2Klimov committed Feb 22, 2024
    Configuration menu
    Copy the full SHA
    a00262f View commit details
    Browse the repository at this point in the history