From 74f483f23140aaf77ab062bd53478cbb949fd2e2 Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Mon, 16 Jun 2014 13:33:33 +0200 Subject: Write memory events into tracefiles generated by qmlprofiler Change-Id: Ic01505194f29967ed1aad16fe36e14dc5532ae25 Reviewed-by: Simon Hausmann --- tools/qmlprofiler/qmlprofilerclient.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'tools/qmlprofiler/qmlprofilerclient.cpp') diff --git a/tools/qmlprofiler/qmlprofilerclient.cpp b/tools/qmlprofiler/qmlprofilerclient.cpp index 9322158280..14fc817807 100644 --- a/tools/qmlprofiler/qmlprofilerclient.cpp +++ b/tools/qmlprofiler/qmlprofilerclient.cpp @@ -216,6 +216,12 @@ void QmlProfilerClient::messageReceived(const QByteArray &data) emit pixmapCache((QQmlProfilerService::PixmapEventType)pixEvTy, time, QmlEventLocation(pixUrl,0,0), width, height, refcount); d->maximumTime = qMax(time, d->maximumTime); + } else if (messageType == QQmlProfilerService::MemoryAllocation) { + int type; + qint64 delta; + stream >> type >> delta; + emit memoryAllocation((QQmlProfilerService::MemoryType)type, time, delta); + d->maximumTime = qMax(time, d->maximumTime); } else { int range; stream >> range; -- cgit v1.2.3