Vadim Peretokin
2018-04-22 14:30:29 UTC
I'm looking at optimizing an applications save performance - it is too slow
right now and causes too much of a freeze. We're using QXmlStreamWriter,
here's the implementation
<https://github.com/Mudlet/Mudlet/blob/development/src/XMLexport.cpp>.
Profiling suggests that Qt's write element / attribute method is too slow (
screenshot <https://imgur.com/a/UUVSp4I>, results attached). Is there
anything I can do it speed it up? I tried giving it a QBuffer instead of a
QFile, but the difference was marginal.
A lot of time seems to be spent resizing the buffer, and unfortunately
there doesn't seem to be a way to pre-set the QBuffer size to something
reasonable to begin with.
Anyone have tips?
right now and causes too much of a freeze. We're using QXmlStreamWriter,
here's the implementation
<https://github.com/Mudlet/Mudlet/blob/development/src/XMLexport.cpp>.
Profiling suggests that Qt's write element / attribute method is too slow (
screenshot <https://imgur.com/a/UUVSp4I>, results attached). Is there
anything I can do it speed it up? I tried giving it a QBuffer instead of a
QFile, but the difference was marginal.
A lot of time seems to be spent resizing the buffer, and unfortunately
there doesn't seem to be a way to pre-set the QBuffer size to something
reasonable to begin with.
Anyone have tips?