Skip to content

bench(lint): baseline — no prefer-direct-reexport rule - #33

Open
mainframev wants to merge 2 commits into
bench/basefrom
bench/lint-baseline
Open

bench(lint): baseline — no prefer-direct-reexport rule#33
mainframev wants to merge 2 commits into
bench/basefrom
bench/lint-baseline

Conversation

@mainframev

Copy link
Copy Markdown
Owner

Purpose

Baseline for measuring the lint performance cost of the prefer-direct-reexport ESLint rule.

This branch is plain bench/base (upstream master) plus the benchmark CI job only — it contains no rule code.

Compare against: bench/lint-with-rule (the "with rule" PR), which is this branch plus the 4 rule files and nothing else.

Method

Both PRs run a byte-identical lint-benchmark job (literally the same commit), so the harness is not a variable:

yarn nx run-many -t lint --all --parallel=4 --skipNxCache --excludeTaskDependencies
Flag Why
--all identical project set on both sides; nx affected would skew asymmetrically
--skipNxCache lint is cache: true; otherwise we would time cache replays
--excludeTaskDependencies nx.json sets lint.dependsOn: ["build"]; keeps build time out of the measurement
no --nxBail the with-rule side has known violations; bailing would abort early and under-report time

Run 3× per PR; the fastest run is the least noise-contaminated estimate.

A second, runner-independent measurement runs TIMING=25 eslint src on react-components/react-button/library and dumps ESLint's per-rule profiler table into the job summary. This matters because the config uses projectService: true (type-aware linting), so TypeScript program construction may dominate total lint time and swamp the rule's own cost in wall-clock terms.

Fork CI enablement

Existing jobs are left untouched — they are gated on github.repository_owner == 'microsoft' and so skip automatically in this fork, leaving the runner to the new job. The new job is gated on github.repository_owner == 'mainframev'.

Throwaway branch; not intended to merge.

@mainframev

Copy link
Copy Markdown
Owner Author

Baseline side of the lint benchmark. Full results and analysis: #34 — summary: the rule adds +1s to a 1148s full workspace lint (+0.09%), below the runner noise floor, and profiles at 0.396 ms per package via ESLint's own profiler.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant