A memory leak problem about Q_PROPERTY of QList<int>
I meet a problem seems memory leak when using Q_PROPERTY of QList<int>.
There are some codes below.
Q_PROPERTY(QList<int> data READ data NOTIFY dataChanged)
data[index](index: 0~~10000) in some qml files, and the dataChanged signal is emitted on 200ms.
The problem is increasing memory consumption, which have trend like 90M→100M→95M→120M→103M. But if I stop emitting dataChanged signal, memory consumption will not increase and be stable.
what`s wrong with it? Please help me.
Until the garbage collector runs, that memory will not be truly freed.
If you're accessing it a lot, you will be seeing a lot of fragmentation due to many small allocations.
See also http://doc.qt.io/qt-5/qtquick-performance.html#sequence-tips for more information.
The problem just happened While I use Qt 5.5.0.(no problem with Qt 5.4.1)