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

Use DAP protocol's "memory" event to refresh affected Memory Inspector views #105

Closed
jreineckearm opened this issue Mar 12, 2024 · 2 comments

Comments

@jreineckearm
Copy link
Contributor

Description

The Microsoft DAP protocol comes with a "memory" event which can be sent by a debug adapter to indicate an update in memory ranges: https://microsoft.github.io/debug-adapter-protocol/specification#Events_Memory

This can be issued for example if

  • the Memory Inspector modifies memory. Like with the new apply/store from/to file functionality.

  • other debugger operations happen that explicitly or implicitly modify memory contents.

  • The Memory Inspector's debug tracker should look out for such event.

  • Memory Inspector window instances should be checked if they are affected. If they are, the windows should be refreshed. "Actual" window configurations, e.g. actual offset and length after navigation, and scrollbar position should not be altered by this refresh.

Additional information

Support for "memory" events in a debug adapter should only be enabled if a DAP client announces support. See supportsMemoryEvent in InitializeRequestArguments ( https://microsoft.github.io/debug-adapter-protocol/specification#Requests_Initialize ). Hence, we need to also capture the initialize request to find out if we can expect the events to show. We may need a fallback refresh initiated by Memory Inspector operations if that is not the case to preserve a baseline refresh functionality.

@martin-fleck-at
Copy link
Contributor

@jreineckearm An initial version of this was handled as part of #96, do you think that fulfills all the requirements for this ticket?

@jreineckearm
Copy link
Contributor Author

Thanks, @martin-fleck-at ! Yes it does, thanks a lot for adding the support! We need to gather feedback with this now. But I can't think of further enhancements for the time being. Closing this issue.

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

No branches or pull requests

2 participants