qt5base-lts/src/gui/text
Robin Burchell ca9ed9619f Improve performance of Qt::mightBeRichText by using QStringRef
I noted this taking around 1% of QtQuick Text creation with a few simple bindings
which is quite considerable, so hopefully improvements here will add up gradually.

Also add a benchmark measuring changes:

                  Test                 |      From      |       To       |        Details
+--------------------------------------+----------------+----------------+-----------------------+
  mightBeRichText:br-invalidspace      | 14466.00 instr | 10563.00 instr | -26.98% FASTER! :)
  mightBeRichText:br-nospace           | 18581.00 instr | 14635.00 instr | -21.24% FASTER! :)
  mightBeRichText:br-space             | 18470.00 instr | 14377.00 instr | -22.16% FASTER! :)
  mightBeRichText:documentation-header | 16336.00 instr | 12992.00 instr | -20.47% FASTER! :)
  mightBeRichText:empty                | 2618.00 instr  | 2618.00 instr  | more or less the same
  mightBeRichText:invalid closing tag  | 11102.00 instr | 7159.00 instr  | -35.52% FASTER! :)
  mightBeRichText:no tags              | 12503.00 instr | 8581.00 instr  | -31.37% FASTER! :)
  mightBeRichText:simple               | 17316.00 instr | 14074.00 instr | -18.72% FASTER! :)
  mightBeRichText:simple2              | 14394.00 instr | 10745.00 instr | -25.35% FASTER! :)
+--------------------------------------+----------------+----------------+-----------------------+
             Overall result            |                                        -201.81% :)

Change-Id: I1817a69959d176b381bcbf27b72bb751885c3e9b
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2016-07-11 12:30:31 +00:00
..
qabstracttextdocumentlayout_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qabstracttextdocumentlayout.cpp Add QAbstractTextDocumentLayout::imageAt(), formatAt() 2016-03-18 19:02:13 +00:00
qabstracttextdocumentlayout.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qcssparser_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qcssparser.cpp Merge remote-tracking branch 'origin/5.7' into dev 2016-06-13 12:46:46 +02:00
qcssscanner.cpp Updated license headers 2016-01-15 12:25:24 +00:00
qdistancefield_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qdistancefield.cpp Merge remote-tracking branch 'origin/5.7' into dev 2016-06-21 08:39:41 +02:00
qfont_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qfont.cpp QtGui: use QStringRef to optimize memory allocation 2016-06-02 12:57:42 +00:00
qfont.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qfontdatabase.cpp Merge remote-tracking branch 'origin/5.6' into 5.7 2016-06-10 23:27:10 +02:00
qfontdatabase.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qfontengine_ft_p.h Support color font rendering for freetype engine 2016-05-03 22:58:49 +00:00
qfontengine_ft.cpp Support color font rendering for freetype engine 2016-05-03 22:58:49 +00:00
qfontengine_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qfontengine_qpf2_p.h Updated license headers 2016-01-15 12:25:24 +00:00
qfontengine_qpf2.cpp Use void instead of uchar in the endian-swapping function parameters 2016-05-26 18:02:49 +00:00
qfontengine.cpp Merge remote-tracking branch 'origin/5.7' into dev 2016-06-13 12:46:46 +02:00
qfontengineglyphcache_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qfontengineglyphcache.cpp Updated license headers 2016-01-15 12:25:24 +00:00
qfontinfo.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qfontmetrics.cpp Merge remote-tracking branch 'origin/5.6' into 5.7 2016-02-18 20:50:35 +01:00
qfontmetrics.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qfontsubset_agl.cpp Updated license headers 2016-01-15 12:25:24 +00:00
qfontsubset_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qfontsubset.cpp Use void instead of uchar in the endian-swapping function parameters 2016-05-26 18:02:49 +00:00
qfragmentmap_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qfragmentmap.cpp Updated license headers 2016-01-15 12:25:24 +00:00
qglyphrun_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qglyphrun.cpp Use QFlags::setFlag where prudent in qtbase 2016-02-12 19:32:05 +00:00
qglyphrun.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qharfbuzzng_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qharfbuzzng.cpp QFontEngine: use RAII for font_, face_ members 2016-03-04 10:37:25 +00:00
qplatformfontdatabase.cpp QtGui: use printf-style qWarning/qDebug where possible (I) 2016-03-04 10:29:08 +00:00
qplatformfontdatabase.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qrawfont_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qrawfont.cpp Fix font fallback for an overridden Common script cases 2016-04-27 00:40:02 +00:00
qrawfont.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qstatictext_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qstatictext.cpp Updated license headers 2016-01-15 12:25:24 +00:00
qstatictext.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qsyntaxhighlighter.cpp Updated license headers 2016-01-15 12:25:24 +00:00
qsyntaxhighlighter.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextcursor_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextcursor.cpp Merge remote-tracking branch 'origin/5.6' into 5.7 2016-02-18 20:50:35 +01:00
qtextcursor.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextdocument_p.cpp Merge remote-tracking branch 'origin/5.7' into dev 2016-06-13 12:46:46 +02:00
qtextdocument_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextdocument.cpp Improve performance of Qt::mightBeRichText by using QStringRef 2016-07-11 12:30:31 +00:00
qtextdocument.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextdocumentfragment_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextdocumentfragment.cpp Gui: use const (and const APIs) more 2016-06-01 09:35:29 +00:00
qtextdocumentfragment.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextdocumentlayout_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextdocumentlayout.cpp Merge remote-tracking branch 'origin/5.7' into dev 2016-06-13 12:46:46 +02:00
qtextdocumentwriter.cpp QtGui: Introduce delegating constructors. 2016-05-09 19:47:53 +00:00
qtextdocumentwriter.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextengine_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextengine.cpp Merge remote-tracking branch 'origin/5.7' into dev 2016-06-13 12:46:46 +02:00
qtextformat_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextformat.cpp Merge remote-tracking branch 'origin/5.6' into 5.7 2016-06-06 09:04:55 +02:00
qtextformat.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtexthtmlparser_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtexthtmlparser.cpp Gui: use const (and const APIs) more 2016-06-01 09:35:29 +00:00
qtextimagehandler_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextimagehandler.cpp Updated license headers 2016-01-15 12:25:24 +00:00
qtextlayout.cpp Merge remote-tracking branch 'origin/5.7' into dev 2016-05-03 15:49:15 +02:00
qtextlayout.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextlist.cpp Updated license headers 2016-01-15 12:25:24 +00:00
qtextlist.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextobject_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextobject.cpp Merge remote-tracking branch 'origin/5.6' into 5.7 2016-05-06 15:36:44 +02:00
qtextobject.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextodfwriter_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtextodfwriter.cpp Merge remote-tracking branch 'origin/5.7' into dev 2016-06-13 12:46:46 +02:00
qtextoption.cpp Add flag for showing document terminator in text 2016-04-08 12:30:42 +00:00
qtextoption.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtexttable_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qtexttable.cpp Gui: use const (and const APIs) more 2016-06-01 09:35:29 +00:00
qtexttable.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qzip.cpp Merge remote-tracking branch 'origin/5.6' into 5.7 2016-04-29 17:55:20 +02:00
qzipreader_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
qzipwriter_p.h Add qtguiglobal.h and qtguiglobal_p.h 2016-07-03 07:55:57 +00:00
text.pri src/gui/text/text.pri: add missing header qabstracttextdocumentlayout_p.h 2015-06-01 05:22:05 +00:00