Skip to content

[lldb] SwiftUserExpression avoid call to ImportType (NFCi) #10376

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
merged 1 commit into from
Mar 30, 2025

Conversation

adrian-prantl
Copy link

Currently SwiftASTContext::ImportType was is returning a TypeSystemSwiftForExpressions TypeRef if the input is a TypeRef type. This makes future type alias resolution very slow because we lose the contextual information. By keeping it in the TypeSystemSwiftTypeRef returned by the Variable these lookups remain local. This can elminiate up to 90% of the time spent evaluating expressions in extreme cases.

rdar://145884579

Currently SwiftASTContext::ImportType was is returning a
TypeSystemSwiftForExpressions TypeRef if the input is a TypeRef
type. This makes future type alias resolution very slow because we
lose the contextual information. By keeping it in the
TypeSystemSwiftTypeRef returned by the Variable these lookups remain
local. This can elminiate up to 90% of the time spent evaluating
expressions in extreme cases.

rdar://145884579
@adrian-prantl adrian-prantl requested a review from a team as a code owner March 29, 2025 00:53
@adrian-prantl adrian-prantl requested review from augusto2112 and kastiglione and removed request for a team March 29, 2025 00:53
@adrian-prantl
Copy link
Author

@swift-ci test

@adrian-prantl adrian-prantl merged commit 4710326 into swiftlang:stable/20240723 Mar 30, 2025
3 checks passed
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