Skip to content
Tcl Source Code Artifact [dd629d3c95]
Login

Artifact [dd629d3c95]

Artifact dd629d3c95ec7af887729cb4f38799197020b4e778e076d49c42ebb76ffb7c06:

Ticket change [dd629d3c95] - Ticket [446565ffffffffff|446565ffff] <i>Capturing parens are very slow</i> status still Open with 4 other changes by serhiy.storchaka on 2026-10-11 07:06:58.
D 2026-10-11T07:06:58.677
J foundin 8.6.18,\s9.0.5,\s9.1.0
J icomment Still\sthe\ssame\sin\s8.6,\s9.0\sand\s9.1.\sFinding\sthe\ssubmatch\sboundaries\sof\sthis\sRE\sis\smuch\smore\sexpensive\sthan\sfinding\sthe\smatch,\sand\s<tt>regsub</tt>\salways\sasked\sthe\sregexp\sengine\sfor\s10\ssubmatches,\seven\swhen\sthe\sreplacement\sstring\sdoes\snot\srefer\sto\sany\sof\sthem.\n\nProposed\sfix\sin\sbranch\s[/timeline?r=regsub-needed-submatches|regsub-needed-submatches]:\s<tt>regsub</tt>\sasks\sonly\sfor\sthe\ssubmatches\sthat\sthe\sreplacement\sstring\srefers\sto,\sso\sthe\sattached\sexample\snow\stakes\smilliseconds\sinstead\sof\sa\ssecond.\sA\sreplacement\swith\s<tt>\\1</tt>\sor\s<tt>\\2</tt>,\sand\s<tt>regexp</tt>\swith\ssubmatch\svariables,\sare\sstill\sslow\swith\ssuch\sREs.\sTests\sregexp-31.1\sto\s31.5.
J login serhiy.storchaka
J mimetype text/x-fossil-wiki
K 446565ffffffffffffffffffffffffffffffffff
U serhiy.storchaka
Z b907f8cf75cdb28f6a5b126796a0b947