Skip to content

Speed up suppressed deps options processing#20806

Merged
JukkaL merged 1 commit intomasterfrom
optimize-suppressed
Feb 13, 2026
Merged

Speed up suppressed deps options processing#20806
JukkaL merged 1 commit intomasterfrom
optimize-suppressed

Conversation

@JukkaL
Copy link
Copy Markdown
Collaborator

@JukkaL JukkaL commented Feb 13, 2026

suppressed_deps_opts was consuming 5% of total CPU in a small incremental run targeting a very large codebase. Make it faster by avoiding json dump, and overall using a more efficient encoding.

We could still make this faster by encoding the options as a single integer, but maybe this is already good enough.

`suppressed_deps_opts` was consuming 5% of total CPU in a small
incremental run targeting a very large codebase. Make it faster
by avoiding json dump, and overall using a more efficient encoding.

We could still make this faster by encoding the options as a single
integer, but maybe this is already good enough.
@JukkaL JukkaL requested a review from ilevkivskyi February 13, 2026 16:22
@JukkaL JukkaL changed the title Speed up suppressed deps options evaluation Speed up suppressed deps options processing Feb 13, 2026
Copy link
Copy Markdown
Member

@ilevkivskyi ilevkivskyi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess you didn't read my comment in #20800 earlier this morning :-)

Btw we may want to micro-optimize that one as well for large code bases that use --follow-imports=skip, LOL. I can do this while fixing this issue

Anyway, I didn't start working on this yet, so no merge conflicts.

@JukkaL
Copy link
Copy Markdown
Collaborator Author

JukkaL commented Feb 13, 2026

I guess you didn't read my comment in #20800 earlier this morning :-)

Oops, missed that one. But this wasn't much effort anyway.

@github-actions
Copy link
Copy Markdown
Contributor

According to mypy_primer, this change doesn't affect type check results on a corpus of open source code. ✅

@JukkaL JukkaL merged commit 608134f into master Feb 13, 2026
23 checks passed
@JukkaL JukkaL deleted the optimize-suppressed branch February 13, 2026 16:54
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.

2 participants