Skip to content

[ascii] faster reading in AsciiFilter.

Alexander Semke requested to merge work/optimize-asciifilter into master

When reading numerical data the options removeQuotesEnabled, simplifyWhitespacesEnabled and skipEmptyParts are not relevant and we can provide a more faster version that avoids many of string allocations, etc.

QString::split() is slow and also requres working with QStringList where the constructions and destruction of these temporary objects takes time. Replaced it with QStringTokenizer from KDAB which avoid many of string alloctions and allows to "iterate" with QStringView over the string line.

This commit reduces the time to read a 2.9GB file from ca. 70s to ca. 20s (with all options deactivated).

Merge request reports

Loading