Skip to content
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

Fix recently added n^2 edge collection #10392

Merged
merged 1 commit into from Jul 17, 2020

Conversation

stuhood
Copy link
Sponsor Member

@stuhood stuhood commented Jul 17, 2020

Problem

retain_edges is crazy slow, but the simplicity of the API allured me late in the implementation of #10230, after I had finished testing the performance of the change.

Solution

Switch to filter_map, which we use elsewhere to good effect, and which a previous version of #10230 had used.

Result

When repeatedly re-running tests with light edits, edge garbage collection goes from multiple seconds to single digit milliseconds.

@stuhood stuhood merged commit a978581 into pantsbuild:master Jul 17, 2020
@stuhood stuhood deleted the stuhood/edge-gc-perf branch July 17, 2020 21:01
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.

None yet

2 participants