aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/qmlprofiler/memoryusagemodel.h
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2016-04-28 16:13:16 +0200
committerUlf Hermann <ulf.hermann@qt.io>2016-05-23 12:31:44 +0000
commit4a1e5a637a08299bd94428fba233d985a63f4675 (patch)
tree95200030f1509d6e95b4dea682ba3f44187cadb9 /src/plugins/qmlprofiler/memoryusagemodel.h
parentdd87df7e5d338663283cfd1fa24b7c069a580167 (diff)
QmlProfiler: Drive event loading from the model manager
We want to get rid of the big master list of QmlEvent in QmlProfilerDataModel, as that gets very large for longer traces. In order to reduce the dependencies on that list we load the events on the fly into the child models while they are being received, rather than having the child models query QmlProfilerDataModel for the event list later. As the trace client so far only emitted rangedEvent() for complete ranges we run into problems with models that need their events sorted. The rangedEvent() signals were sorted by end time, rather than start time which makes it inconvenient to analyze them in a stack based way, for aggregation. This is solved by passing on all the details from the trace client to the models, with the QmlProfilerDataModel aggregating the type information before having the events dispatched to the child models. Change-Id: I5831a20551f21cf91e27d298a709f604ebd96c3e Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'src/plugins/qmlprofiler/memoryusagemodel.h')
-rw-r--r--src/plugins/qmlprofiler/memoryusagemodel.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/plugins/qmlprofiler/memoryusagemodel.h b/src/plugins/qmlprofiler/memoryusagemodel.h
index 9cc1116823d..1fb280323ff 100644
--- a/src/plugins/qmlprofiler/memoryusagemodel.h
+++ b/src/plugins/qmlprofiler/memoryusagemodel.h
@@ -76,12 +76,11 @@ protected:
private:
struct RangeStackFrame {
- RangeStackFrame() : originTypeIndex(-1), startTime(-1), endTime(-1) {}
- RangeStackFrame(int originTypeIndex, qint64 startTime, qint64 endTime) :
- originTypeIndex(originTypeIndex), startTime(startTime), endTime(endTime) {}
+ RangeStackFrame() : originTypeIndex(-1), startTime(-1) {}
+ RangeStackFrame(int originTypeIndex, qint64 startTime) :
+ originTypeIndex(originTypeIndex), startTime(startTime) {}
int originTypeIndex;
qint64 startTime;
- qint64 endTime;
};
static QString memoryTypeName(int type);