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

fix: Use plain integer addresses for opcodes in DAP disassembly view #4941

Merged
merged 4 commits into from May 22, 2024

Conversation

ggiraldez
Copy link
Contributor

Description

Problem*

Resolves #4904

The disassembly view from VS.Code didn't work properly. Sometimes it would only show the first opcode only and once open it wouldn't update the current opcode pointer when stepping through the code. This was because we were using opcode locations (eg. 3.17) as instruction references (typed as string in the API), but VS.Code expects integers either in decimal or hexadecimal format.

Summary*

This PR updates the disassembly request DAP command handler to return integer addresses only, and changes the instruction set breakpoint command to parse and map the given address to the appropriate opcode location.

Additional Context

Documentation*

Check one:

  • No documentation needed.
  • Documentation included in this PR.
  • [For Experimental Features] Documentation to be submitted in a separate PR.

PR Checklist*

  • I have tested the changes locally.
  • I have formatted the changes with Prettier and/or cargo fmt on default settings.

Copy link
Contributor

Thank you for your contribution to the Noir language.

Please do not force push to this branch after the Noir team have started review of this PR. Doing so will only delay us merging your PR as we will need to start the review process from scratch.

Thanks for your understanding.

Copy link
Member

@TomAFrench TomAFrench left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for this. :)

@TomAFrench TomAFrench added this pull request to the merge queue May 22, 2024
Merged via the queue into noir-lang:master with commit d43ba1b May 22, 2024
39 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.

Debugger: disassembly view in VS.Code not updating properly
2 participants