Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qwaitcondition_p.h
Go to the documentation of this file.
1
// Copyright (C) 2019 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com, author Marc Mutz <marc.mutz@kdab.com>
2
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
#ifndef QWAITCONDITION_P_H
4
#define QWAITCONDITION_P_H
5
6
//
7
// W A R N I N G
8
// -------------
9
//
10
// This file is not part of the Qt API. It exists for the convenience of
11
// qmutex.cpp and qmutex_unix.cpp. This header file may change from version to
12
// version without notice, or even be removed.
13
//
14
// We mean it.
15
//
16
17
#include <QtCore/QWaitCondition>
18
#include <QtCore/QMutex>
19
#include <QtCore/QDeadlineTimer>
20
#include <QtCore/private/qglobal_p.h>
21
22
#include <condition_variable>
23
#include <mutex>
24
25
QT_BEGIN_NAMESPACE
26
27
namespace
QtPrivate
{
28
// Ideal alignment for mutex and condition_variable: it's the hardware
29
// interference size (size of a cache line) if the types are likely to contain
30
// the actual data structures, otherwise just that of a pointer.
31
static
constexpr
quintptr
IdealMutexAlignment
=
32
sizeof
(std::mutex) >
sizeof
(
void
*) &&
33
sizeof
(std::condition_variable) >
sizeof
(
void
*) ?
34
64 :
alignof
(
void
*);
35
36
}
// namespace QtPrivate
37
38
QT_END_NAMESPACE
39
40
#endif
/* QWAITCONDITION_P_H */
QT_BEGIN_NAMESPACE
Combined button and popup list for selecting options.
Definition
qstandardpaths_haiku.cpp:21
QT_END_NAMESPACE
Definition
qsharedpointer.cpp:1590
QtPrivate
\macro QT_NO_KEYWORDS >
Definition
qtconcurrentcompilertest.h:13
QtPrivate::IdealMutexAlignment
static constexpr quintptr IdealMutexAlignment
Definition
qwaitcondition_p.h:31
quintptr
size_t quintptr
Definition
qtypes.h:167
qtbase
src
corelib
thread
qwaitcondition_p.h
Generated by
1.10.0