QMetaObjectBuilder: replace an inefficient QList with QVector
ints are only half the size of void* on 64-bit, so QVector<int> uses only 50% of per-element memory, compared to a QList. Saves ~1800B of text size on GCC 4.9 optimized C++11 AMD64 Linux builds, even though it wasn't the last instance of QList<int> in QtCore, yet. Change-Id: Ibf04b26cff78c428e4253aaab7c280866906db58 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
This commit is contained in:
parent
d4cee10bf8
commit
b9331eff91
@ -193,7 +193,7 @@ public:
|
||||
QByteArray name;
|
||||
bool isFlag;
|
||||
QList<QByteArray> keys;
|
||||
QList<int> values;
|
||||
QVector<int> values;
|
||||
};
|
||||
Q_DECLARE_TYPEINFO(QMetaEnumBuilderPrivate, Q_MOVABLE_TYPE);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user