-
Notifications
You must be signed in to change notification settings - Fork 125
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
GdbServer: Minor work #4170
Merged
Merged
GdbServer: Minor work #4170
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sonicadvance1
force-pushed
the
gdbserver_work
branch
2 times, most recently
from
November 25, 2024 01:50
5ead116
to
26904ef
Compare
Closed
Could you apply Draft status to this PR if you're still planning to add further patches? |
I'm moving on to a different branch now |
lioncash
reviewed
Nov 28, 2024
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.
few minor nits for a first pass
Sonicadvance1
force-pushed
the
gdbserver_work
branch
from
November 28, 2024 23:30
123e0d7
to
3fa9350
Compare
We have supported this for a while, just wasn't passed through gdbserver since it usually doesn't matter.
Previously this would have corrupted data in the upper 128-bits of the YMM register.
Makes these consistent in the handling and documents the commands in a way that is easier to parse while working on this. NFC
This doesn't behave properly anymore now that thread management was moved to the frontend.
When parsing `comm`, by default it will have a newline which breaks gdb in some cases. Strip out the whitespace to fix that issue.
NFC, just making this easier to track for me.
Previous `S AA` logic is legacy for non-multithreaded applications. This newer command gives more information about what occured and in what thread id.
This currently happens in two locations, so split it out. There's some behaviour here where if the TID isn't found, then it returns the ParentThread of the process. This is working around a bug in either FEX's gdbserver or binaryninja. Leave it currently before we figure out what's wrong. NFC
…ction GDB has two ways to read the registers. One way is reading the full GDBContextDefinition, which matches the layout in `BuildTargetXML`. The other way is to read the individual elements out of GDBContextDefinition. These two code paths were independently implemented. Instead generate in one location and use in either location. NFC
Just breaks out the two commands we support and leaves TODOs for implementing the remaining commands. NFC
Sonicadvance1
force-pushed
the
gdbserver_work
branch
from
November 28, 2024 23:32
3fa9350
to
357cc04
Compare
Sonicadvance1
added a commit
to Sonicadvance1/FEX
that referenced
this pull request
Nov 29, 2024
We were using this variable for two things, letting the frontend signal to the backend that it wants to start executing once the thread is created, and also for handling thread pausing. These two features are conflated with one another and actually makes things more confusing. - Move StartRunning/StartPaused to the frontend, because its a construct that only needs to exist in the frontend - Adds a FEX::HLE::ThreadStateObject CV for handling pausing, which only needs to exist for gdbserver Relies on FEX-Emu#4170 and FEX-Emu#4179 being merged first. Which is what the first two commits are from.
Sonicadvance1
added a commit
to Sonicadvance1/FEX
that referenced
this pull request
Nov 29, 2024
We were using this variable for two things, letting the frontend signal to the backend that it wants to start executing once the thread is created, and also for handling thread pausing. These two features are conflated with one another and actually makes things more confusing. - Move StartRunning/StartPaused to the frontend, because its a construct that only needs to exist in the frontend - Adds a FEX::HLE::ThreadStateObject CV for handling pausing, which only needs to exist for gdbserver Relies on FEX-Emu#4170 and FEX-Emu#4179 being merged first. Which is what the first two commits are from.
Sonicadvance1
added a commit
to Sonicadvance1/FEX
that referenced
this pull request
Nov 29, 2024
We were using this variable for two things, letting the frontend signal to the backend that it wants to start executing once the thread is created, and also for handling thread pausing. These two features are conflated with one another and actually makes things more confusing. - Move StartRunning/StartPaused to the frontend, because its a construct that only needs to exist in the frontend - Adds a FEX::HLE::ThreadStateObject CV for handling pausing, which only needs to exist for gdbserver Relies on FEX-Emu#4170 and FEX-Emu#4179 being merged first. Which is what the first two commits are from.
Sonicadvance1
added a commit
to Sonicadvance1/FEX
that referenced
this pull request
Nov 29, 2024
We were using this variable for two things, letting the frontend signal to the backend that it wants to start executing once the thread is created, and also for handling thread pausing. These two features are conflated with one another and actually makes things more confusing. - Move StartRunning/StartPaused to the frontend, because its a construct that only needs to exist in the frontend - Adds a FEX::HLE::ThreadStateObject CV for handling pausing, which only needs to exist for gdbserver Relies on FEX-Emu#4170 and FEX-Emu#4179 being merged first. Which is what the first two commits are from.
lioncash
approved these changes
Nov 29, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Unlike in #3592, this does some initial work towards making my life easier for improving the gdbserver.
Some very minor behaviour changes but pretty much just moving some code around and documenting the command packets so I can quickly search around in vim.