summaryrefslogtreecommitdiffstats
path: root/tests/auto/corelib/global/qflags/qflags.pro
diff options
context:
space:
mode:
authorJędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>2014-10-28 12:21:13 +0100
committerJędrzej Nowacki <jedrzej.nowacki@digia.com>2014-10-30 16:41:39 +0100
commit053e8c41d7f87a07cb1a74cd95bd030ac138dc4e (patch)
tree935142c0b5058421aade79b3f1000da7439bac19 /tests/auto/corelib/global/qflags/qflags.pro
parent8c77a7f77a8111bcbe51532f788679777910ebd5 (diff)
Use file mapping in moc.
The change reduces heap allocations by using file mapping instead of reading a whole file into memory just to create a slightly modified copy of it. For this small test case: moc <<EOF class X : public QObject { Q_OBJECT Q_PROPERTY(int x) }; EOF massif shows improvement from: peak cost: "26,8 KB" heap "2,1 KB" heap extra "0 B" stacks to: peak cost: "11,3 KB" heap "2,2 KB" heap extra "0 B" stacks In general, depending on source file high peak memory usage is reduced from few to few hundreds KB, especially that the allocation used to happen for each include file too. Change-Id: I9c1c848be848444156af25a991b67161fb9d8b29 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Diffstat (limited to 'tests/auto/corelib/global/qflags/qflags.pro')
0 files changed, 0 insertions, 0 deletions