• Clemens Hammacher's avatar
    [platform] Use condition variable instead of semaphore · 78f88ef0
    Clemens Hammacher authored
    The MessageLoopBehavior might change over time: Sometimes we want to
    wait because wasm background compilation is going on, sometimes we
    don't. This makes the semaphore go out of sync with the task queue (we
    always notify it when a new task is scheduled, but we only sometimes
    wait on it).
    Using a condition variable instead of a semaphore avoids this problem.
    
    R=ahaas@chromium.org
    
    Change-Id: Ib9850efc634f5988d3f824895b6566bd76475985
    Reviewed-on: https://chromium-review.googlesource.com/969122Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
    Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#52057}
    78f88ef0
default-foreground-task-runner.cc 4.07 KB