-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Improve incremental use of lint filtering #145220
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
rustbot has assigned @petrochenkov. Use |
@bors2 try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
Improve incremental use of lint filtering
|
||
needs_to_run | ||
} | ||
|
||
fn lints_that_dont_need_to_run(tcx: TyCtxt<'_>, (): ()) -> UnordSet<LintId> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few ideas:
- make the return type a dedicated struct;
- replace
dont_need_to_run.contains(lint)
by a call to inherent methodshould_run(lint)
; - perform the check for future breakage and
lint_cap
in that method; - compute this query per module, and only recurse inside that module.
This comment has been minimized.
This comment has been minimized.
Finished benchmarking commit (30964bb): comparison URL. Overall result: ❌ regressions - please read the text belowBenchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf. Next Steps: If you can justify the regressions found in this try perf run, please do so in sufficient writing along with @bors rollup=never Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (primary 1.9%, secondary 3.5%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (secondary -0.7%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 462.481s -> 464.365s (0.41%) |
Via making the query DefId dependant instead of running on the whole crate, we can reuse the shallow lint map of previously-visited items in other runs.
Similar to the approach that would maybe help with #144927