Repository navigation
perf(checker): cut type-fest check time ~29% with ordered array mappers and bulk tuple spreads - #1127
Conversation
Merging this PR will not alter performanceWarning oxc-project has exceeded the Hobby plan limit of 5 active contributors. Upgrade your plan or apply to the open source program by December 8, 2026 to keep using CodSpeed. 1 warning
Comparing Footnotes
|
Performance change vs mainWorkflow run Β· main Clef gate: Clef estimated 84.6% default and single-threaded wall time, 70.4% peak RSS, 95.4% single-threaded instruction count impact probability. Release builds in fast mode (TSRS_FAST=1) with Hyperfine 2 hardware counters. After warming each binary, alternating main/PR pairs measure wall time at both the fast preset's default checker count and with --singleThreaded, with ten pairs per configuration by default. Instructions come from the single-threaded runs; peak RSS comes from the default-count runs.
Negative means the PR used less; positive means it used more. Deltas are medians of paired PR/main ratios for wall time and instructions. Single-threaded runs reduce scheduling noise; shared CI machines can still add noise to wall time. Measured medians (main β PR)
tsrs-lintRelease
Negative means the PR used less. Wall and CPU time deltas are medians of paired PR/main ratios; peak RSS compares medians. Measured lint medians (main β PR)
|
on
type-fest,TypeMapper::maplinearly scanned long array mappers on every lookup, andTupleNormalizercopied all-required tuple spreads one element at a time.new_array_type_mappernow puts lists of 32+ sources with strictly increasing type ids into an out-of-lineOrderedArrayvariant that binary-searches by id and confirms the handle matches.TupleNormalizercopies all-required spreads in bulk and stops its optional-to-required fixup loop at the last optional or rest element. no new unsafe sites, and adds thelong-array-mapperandrequired-tuple-spreadregression fixtures matching pinned tsgo.type-fest(x86_64, 16 pairs,--noEmit --incremental false) and CI catalog:type-festdefault checkerstype-festsingle-threadedtype-fest--fastt3code-server-0.6%)