Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-92148

QSemaphore::acquire is not woken when release is called()

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P1: Critical
    • 6.2.0 Alpha
    • 6.2
    • Core: Threads
    • None
    • Windows
    • 587e3bb0ba6def90906f1f6b8c60c8f33ec88571 (qt/qtbase/dev)

    Description

      As seen in a precheck, tst_QSemaphore::tryAcquireWithTimeoutStarvation ran for 900 seconds with no progress. Given how the test is implemented this shouldn't be possible. Was also able to reproduce locally. A possible indication of what the issue is is that `if (futexNeedsWake(prevValue)) {` in QSemaphore::release returns false, thus was not waking the main thread which is stuck on `semaphore.acquire();` in the test.

      Extend time_t-based handling all the way to the end of time_t (Ib8001b5a) · Gerrit Code Review (qt-project.org)

      The issue is likely only relevant for 6.2, since the code-path is futex specific, and Windows only recently gained support for that. However, it could possibly also be an issue on Linux in earlier versions.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            manordheim Mårten Nordheim
            manordheim Mårten Nordheim
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes