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

Cache disassembled version of program #142

Merged
merged 3 commits into from
Oct 16, 2021
Merged

Cache disassembled version of program #142

merged 3 commits into from
Oct 16, 2021

Conversation

mortbopet
Copy link
Owner

This commit adds caching of the disassembling of the current program to the Program class. This can then be used in models which rely on some form of mapping between the notions of "disassembled program line #", "disassembled instruction address" and "diassembled instruction string".

@mortbopet
Copy link
Owner Author

@lcgamboa this moves the m_indexToAddress calculation to the disassembled result, which can then be used, as shown, in the instruction model, but should equally be useful to rewrite the objdump method, so that that method doesn't do disassembly, but simply "adds more text" onto the already disassembled program.

@lcgamboa
Copy link
Collaborator

With these modifications the instruction viewer is no longer updating correctly. I couldn't find the cause of the problem.

instructionviewer

@mortbopet
Copy link
Owner Author

thank you for that; i was using the instruction PC for the row; should have done as in 03a31f6

@mortbopet mortbopet merged commit 7202a4e into c_ext Oct 16, 2021
@mortbopet mortbopet deleted the disassembly_caching branch October 25, 2021 10:18
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.

2 participants