Add design document for stub target debug data#124035
Draft
Conversation
Co-authored-by: noahfalk <6243776+noahfalk@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add stub target debug data for managed debugging
Add design document for stub target debug data
Feb 5, 2026
jkotas
reviewed
Feb 5, 2026
jkotas
reviewed
Feb 5, 2026
jkotas
reviewed
Feb 5, 2026
Member
|
@jkotas - I iterated a little offline with copilot. The design is still incomplete/rough but I think it points in a better direction than the original one did. Getting to a final design that we'd want to implement still seems like more work is required, especially since doing a nice job on the inlining increases the complexity. What I'd like to do is just bank the progress thus far and put this on the shelf until we have a more urgent need to move it forward. I acknowledge right at the top of the doc that the design isn't done to try and avoid anyone else trying to run with it as-is. |
This file contains hidden or 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
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.
Description
Proposes declarative debug data for stubs to simplify debugger stepping. Current approach requires each StubManager to implement bespoke prediction logic that must understand stub internals and can fail in restricted contexts (locks, GC no-trigger regions).
Changes
Design document at
docs/design/coreclr/stub-target-debug-data-design.mdProposed solution: Store instruction offset of branch/call to target
Stubclass for StubLinker stubs, leverage JIT debug info for ILStubsOpen questions (13 total):
Example of proposed Stub class extension:
Ready for team review and feedback before prototype implementation.
Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.