[PATCH] performance tuning of helpex

Norbert Thiebaud (via Code Review) gerrit at gerrit.libreoffice.org
Thu Dec 6 19:20:59 PST 2012


I have submitted a patch for review:


To pull it, you can do:

    git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/62/1262/1

performance tuning of helpex

callgrind (on text/swriter/guide translated in 'fr')

before Ir = 889,687,925
after Ir = 406,372,177 (405,668,292 w/o the 'native' memory allocator)

time confirms:
before 0.288/0.272/0.016
after  0.146/0.131/0.015

the output before and after were diff-ed and every generated xhp files
are identical.

All improvements where done still using 'normal' sal and c++ API.

There are still some low-hanging fruits, like XMLUtil:QuoteHTML
(probably 20-30 millions Ir to shave there)

The destruction of XMLElements is also singularly high
(11% of the remaining Ir count)

But the bulk of what is left is OString management (alloc/acquire/release/
free/copy), and I/O using streams

Change-Id: Ia316c953cd4bd46fc33a58a0c10f26b0ffa042c2
M l10ntools/inc/xmlparse.hxx
M l10ntools/source/common.hxx
M l10ntools/source/helpex.cxx
M l10ntools/source/helpmerge.cxx
M l10ntools/source/merge.cxx
M l10ntools/source/po.cxx
M l10ntools/source/xmlparse.cxx
7 files changed, 657 insertions(+), 287 deletions(-)

To view, visit https://gerrit.libreoffice.org/1262
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia316c953cd4bd46fc33a58a0c10f26b0ffa042c2
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Norbert Thiebaud <nthiebaud at gmail.com>

More information about the LibreOffice mailing list