summaryrefslogtreecommitdiffstats
path: root/src/corelib/thread/qmutex.cpp
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2025-01-16 11:07:34 -0800
committerThiago Macieira <thiago.macieira@intel.com>2025-01-20 19:43:16 -0800
commitef73a5f175f8d51a0bacbdd30cacbd3b6d151d36 (patch)
tree0cb0da994a8f9b210fc188129d4caebd60c8fb63 /src/corelib/thread/qmutex.cpp
parent1957597aa6bc6ebd8bd1f903389800897411ac5d (diff)
QMutex: improve codegen for non-futex lockInternal()
Amends commit ff9da1db0b0963f967f45ab430ec40a3051b70b4. QDeadlineTimer's Forever constructor is constexpr inline, while the one taking an integer is neither. In an LTO build, the compiler might have realized that it's constant, but let's be sure. Pick-to: 6.8 6.9 Change-Id: I2c07caec660e05efe695fffd6ac8ec3120258a96 Reviewed-by: MÃ¥rten Nordheim <marten.nordheim@qt.io>
Diffstat (limited to 'src/corelib/thread/qmutex.cpp')
-rw-r--r--src/corelib/thread/qmutex.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/thread/qmutex.cpp b/src/corelib/thread/qmutex.cpp
index fe816d958cf..bd3b269c0b7 100644
--- a/src/corelib/thread/qmutex.cpp
+++ b/src/corelib/thread/qmutex.cpp
@@ -654,7 +654,7 @@ void QBasicMutex::lockInternal() noexcept(FutexAlwaysAvailable)
}
Q_ASSERT(d_ptr.loadRelaxed());
} else {
- lockInternal(-1);
+ lockInternal(QDeadlineTimer::Forever);
}
}