Skip to content

[silmem2reg] Compute DomTreeLevels lazily. #36956

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

Merged

Conversation

gottesmm
Copy link
Contributor

We previously were computing this eagerly meaning that if we did not actually
need the DomTreeLevel map, we would calculate it and additionally incur a
relatively large malloc for the DenseMap (which stores by default IIRC 64 key
value pairs).

Now, we do it lazily ensuring that we only compute this if we actually need it
(when promoting non-single block stack allocations).

We previously were computing this eagerly meaning that if we did not actually
need the DomTreeLevel map, we would calculate it and additionally incur a
relatively large malloc for the DenseMap (which stores by default IIRC 64 key
value pairs).

Now, we do it lazily ensuring that we only compute this if we actually need it
(when promoting non-single block stack allocations).
@gottesmm
Copy link
Contributor Author

@swift-ci smoke test

@gottesmm
Copy link
Contributor Author

@swift-ci smoke test Mac OS platform

@gottesmm
Copy link
Contributor Author

@swift-ci smoke test osx platform

@gottesmm
Copy link
Contributor Author

@swift-ci please smoke test osx platform

@gottesmm
Copy link
Contributor Author

@swift-ci Please smoke test macOS platform

1 similar comment
@gottesmm
Copy link
Contributor Author

@swift-ci Please smoke test macOS platform

@gottesmm gottesmm merged commit 8b9d7ae into swiftlang:main Apr 19, 2021
@gottesmm gottesmm deleted the pr-970ffad9db66fdff542712db9c300fa9fbe3d98f branch April 19, 2021 19:21
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