From f594bff17405030616b8443141e9dae188bf7055 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ralph=20K=C3=BCpper?= Date: Sun, 13 Sep 2026 12:20:20 +0000 Subject: [PATCH 1/2] deps: take perex 0.1.4 (required-text search from the requested start) perex 0.1.4 (published 2026-09-13T12:17:29Z from 0d3d3f2) starts the initial required-text search at the requested start on ASCII storage for programs carrying the forward-admission claim. Before this, a pattern such as /[a-z]+[0-9]+ /g paid for every earlier occurrence of its required text on each search, so JS exec/test loops over it were O(lastIndex) per call. Checksum 1542e48011813fbdf3c075da4a4ed53ee93c816eef62e36eb5064a6fd2be10a5, verified against the downloaded crate. Locked with a one-time publish-age override approved for this version only. Claude-Session: https://claude.ai/code/session_01Da12JXeG5XuVBma5yWp5C9 --- Cargo.lock | 4 ++-- Cargo.toml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index c55de3dccc..43df258da9 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -5684,9 +5684,9 @@ checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220" [[package]] name = "perex" -version = "0.1.3" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "060b4682849d20ebcba05d68f9584a1bba20af4b7838c688cfb37af572f562f4" +checksum = "1542e48011813fbdf3c075da4a4ed53ee93c816eef62e36eb5064a6fd2be10a5" [[package]] name = "perry" diff --git a/Cargo.toml b/Cargo.toml index 81fc773085..8c3a08be33 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -399,7 +399,7 @@ chrono = "0.4" regex = "1.12" aho-corasick = "1.1" # The single regular-expression engine, through crates/perry-perex. -perex = "0.1.3" +perex = "0.1.4" hex = "0.4" tempfile = "3" itoa = "1.0" From b141b85b84c439847449789b900f58b7252c8eb3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ralph=20K=C3=BCpper?= Date: Sun, 13 Sep 2026 12:37:38 +0000 Subject: [PATCH 2/2] changelog: add fragment for #10201 Claude-Session: https://claude.ai/code/session_01Da12JXeG5XuVBma5yWp5C9 --- changelog.d/10201-regex-perex-0.1.4.md | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 changelog.d/10201-regex-perex-0.1.4.md diff --git a/changelog.d/10201-regex-perex-0.1.4.md b/changelog.d/10201-regex-perex-0.1.4.md new file mode 100644 index 0000000000..59cc1ebfff --- /dev/null +++ b/changelog.d/10201-regex-perex-0.1.4.md @@ -0,0 +1,3 @@ +### Performance + +- **Required text after a character-class repeat no longer makes each RegExp search cost its start position** (#10201). A pattern such as `/([a-z]+)([0-9]+) /g` or `/[a-z]+[0-9]+ /y` made every `exec` or `test` call over an ASCII string pay work proportional to `lastIndex`, so a loop over one string was quadratic: 21 s for 40,000 matches over a 200,000-character string. The same loop now takes 85 ms. Requires `perex` 0.1.4.