diff options
author | Ulf Hermann <ulf.hermann@theqtcompany.com> | 2016-03-02 16:26:36 +0100 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@theqtcompany.com> | 2016-03-11 09:18:54 +0000 |
commit | d87572053a15474a577dcf5714187fbdb4cfec0d (patch) | |
tree | 7bfdaa1bc40d2c201881db44b0d9a68888f4f52c /src/plugins/qmltooling/qmldbg_quickprofiler | |
parent | c44413067da24f5d768f3fde25248cdba5a566bd (diff) |
QmlProfiler: Send events in smaller batches
This enables more parallel data processing and limits the memory
usage. Benchmarks with the "planets" example from canvas3d show that
this change reduces the time between the profiling being stopped and
the last events arriving in the profiling client by about 50%.
Change-Id: Iea16f9e2ae3adf584ec4a3c7fc766eaa21740f98
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Diffstat (limited to 'src/plugins/qmltooling/qmldbg_quickprofiler')
-rw-r--r-- | src/plugins/qmltooling/qmldbg_quickprofiler/qquickprofileradapter.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/qmltooling/qmldbg_quickprofiler/qquickprofileradapter.cpp b/src/plugins/qmltooling/qmldbg_quickprofiler/qquickprofileradapter.cpp index 5ca64fda15..0f44ba3dc2 100644 --- a/src/plugins/qmltooling/qmldbg_quickprofiler/qquickprofileradapter.cpp +++ b/src/plugins/qmltooling/qmldbg_quickprofiler/qquickprofileradapter.cpp @@ -153,7 +153,7 @@ static void qQuickProfilerDataToByteArrays(const QQuickProfilerData &data, qint64 QQuickProfilerAdapter::sendMessages(qint64 until, QList<QByteArray> &messages) { while (next < m_data.size()) { - if (m_data[next].time <= until) + if (m_data[next].time <= until && messages.length() <= s_numMessagesPerBatch) qQuickProfilerDataToByteArrays(m_data[next++], messages); else return m_data[next].time; |