-
Notifications
You must be signed in to change notification settings - Fork 341
[lldb] Prefer triple from module in precise invocations #8941
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
[lldb] Prefer triple from module in precise invocations #8941
Conversation
@swift-ci test |
@@ -2909,20 +2909,32 @@ lldb::TypeSystemSP SwiftASTContext::CreateInstance( | |||
return exe_module_sp->GetArchitecture().GetTriple(); | |||
}; | |||
|
|||
ArchSpec active_arch; |
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.
I think it would be less confusing if we called this module_arch
or maybe image_arch
(even though module is a very overloaded term).
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.
This is a variable that holds either the module/image arch, and if that's not available, holds the target arch. "Active" meaning, the one we found, in order of preference (module first, target second).
So it's not module_arch
, but maybe active_arch
is also not right.
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.
I'm going to rename it to preferred_
… hopefully you'll agree that's ok.
@swift-ci test |
Should playgrounds just turn off precise compiler invocations rather than threading this as a different dimension in the API? |
@fredriss here's the new commit, which disables precise compiler invocation for playgrounds 9ec444b The tests in |
@fredriss let me look into that. |
This reverts commit 2deec4fb327f42310c257c731cbfc1724b688ccc.
@fredriss it turns out that the existing Thoughts? |
@swift-ci test |
LGTM |
@swift-ci test linux |
The linux test failures need investigation. |
@swift-ci test linux |
1 similar comment
@swift-ci test linux |
@swift-ci test linux |
@swift-ci test linux |
@swift-ci test linux |
1 similar comment
@swift-ci test linux |
@swift-ci test |
@swift-ci test linux |
@swift-ci test |
@swift-ci test windows |
@fredriss the issues with playgrounds and linux have been resolved, this is ready to be squashed & merged. |
(cherry-picked from PR #8941) (cherry-picked from commit eed7d856bfb88baaa07addfe1664e4c7934ed4d6)
(cherry-picked from PR #8941) (cherry-picked from commit eed7d856bfb88baaa07addfe1664e4c7934ed4d6)
When using precise compiler invocations, prefer the triple of the dylib/framework (aka image/module), and not the target binary. This is particularly vital for explicitly built modules, where the pcms for the dylib target can differ from the main target. The difference in pcms can cause expression evaluation to fail.
rdar://130284825