|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
follow-up commit to https://gerrit.libreoffice.org/#/c/9226/ .
text_cat -s was documented as "Not very efficient yet, because
language models are re-loaded after each line." So if we want
to use text_cat -s for thousands of lines, better
read the language models only once and store them.
When tested on svl/source, the speed-up was a futher factor 1.5
(reduced from 6 s to 4 s).
Change-Id: I654a250b0e369e01c5eac5970b64df1390f0ef35
Reviewed-on: https://gerrit.libreoffice.org/9227
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Instead of recreating a text_cat sub-process for every string, start a
single text-cat process (with the -s flag, "per line") and reuse that.
Testing on svl/source shows a speed-up of 7.5 x, down from 45.6s to 6.1s!
To avoid blocking on the pipes set autoflush in text-cat, and use
read_line instead of read on the find-german-comments side.
Change-Id: Ic6c00fc3c1e7cbcbbfff65512bf54ad11f900697
Reviewed-on: https://gerrit.libreoffice.org/9226
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Michael Meeks <michael.meeks@collabora.com>
|