-
Notifications
You must be signed in to change notification settings - Fork 344
[NFC][lldb] Adapt LLDB to RemoteInspection's RemoteAddress changes #10981
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
[NFC][lldb] Adapt LLDB to RemoteInspection's RemoteAddress changes #10981
Conversation
(cherry picked from commit 4dc8b19)
Adapts LLDB to the new field in RemoteAddress. This is an NFC that maintains the current behavior. A follow up patch will be introduced later that takes advantage of the new behavior to fix a bug in reading metadata from files instead of the process. rdar://148361743 (cherry picked from commit 12f429a)
Now that RemoteAddress carries its address space, instead of using a high bit to turn on the filecache optimization, use that instead. This way we are guaranteed to not clash with any pointer authentication masks. rdar://148361743 (cherry picked from commit b283038e2aad625ff455a10f2590ed2501c987eb)
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.
LGTM. The majority of these changes are mechanical. The few that aren't are matching the existing behavior.
@@ -51,7 +51,7 @@ class MemoryReaderLocalBufferHolder { | |||
|
|||
class LLDBMemoryReader : public swift::remote::MemoryReader { | |||
public: | |||
|
|||
static constexpr uint8_t LLDBAddressSpace = 1; |
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.
Maybe add a comment here saying that anything but address space 0 is fair play and that each tool/client can define their own, so there's no risk trampling over someone else's address space.
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'll add a comment on the stable branch
Now that RemoteAddress carries its address space, instead of using a
high bit to turn on the filecache optimization, use that instead. This
way we are guaranteed to not clash with any pointer authentication
masks.