aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlengine.cpp
diff options
context:
space:
mode:
authorErik Verbruggen <erik.verbruggen@digia.com>2016-03-30 14:54:00 +0200
committerErik Verbruggen <erik.verbruggen@theqtcompany.com>2016-04-05 13:52:57 +0000
commit90374e136e03f37990cc6725703da21ee8b710ec (patch)
treedbc73535c8e4f7cc68664f307c356c17246f85e3 /src/qml/qml/qqmlengine.cpp
parentaac611fdb8aacc494956a080bf38cb9b7eb4c2e8 (diff)
QML: add some hot-path hints for the compiler.
Change-Id: Ic68691639e81a8450311c03e86bcde14e7bd7dd4 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
Diffstat (limited to 'src/qml/qml/qqmlengine.cpp')
-rw-r--r--src/qml/qml/qqmlengine.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qml/qml/qqmlengine.cpp b/src/qml/qml/qqmlengine.cpp
index 0978af78a9..55053c8733 100644
--- a/src/qml/qml/qqmlengine.cpp
+++ b/src/qml/qml/qqmlengine.cpp
@@ -1906,7 +1906,7 @@ void QQmlEnginePrivate::dereferenceScarceResources()
// if the refcount is zero, then evaluation of the "top level"
// expression must have completed. We can safely release the
// scarce resources.
- if (scarceResourcesRefCount == 0) {
+ if (Q_UNLIKELY(scarceResourcesRefCount == 0)) {
// iterate through the list and release them all.
// note that the actual SRD is owned by the JS engine,
// so we cannot delete the SRD; but we can free the