eclipse-cdt-cloud / cdt-gdb-vscode

CDT GDB Visual Studio Code Extension
Eclipse Public License 2.0
21 stars 24 forks source link

With multiple real target launches, debug operation changes call stack selection #118

Open vinodappuvmw opened 11 months ago

vinodappuvmw commented 11 months ago

I'm testing using two debug launches (Real hardware debugging) in windows, cdt-gdb-vscode v0.0.108 is used. When continuously stepping on one launch, with other launch suspended, the call stack suddenly switches to suspended launch. If I continue stepping, the second launch is being stepped.

This is a wired behavior. Please let me guide on where to be focused to fix the issue.

Note : Issue is not reproducible with local debugging (Tried using amalgamator workspace https://github.com/eclipse-cdt-cloud/cdt-amalgamator )

@jonahgraham @MatthewKhouzam @thegecko @marco-miller

image

jonahgraham commented 9 months ago

You can provide a trace of the debug session, e.g. verbose = true, optionally putting it in a file:

https://github.com/eclipse-cdt-cloud/cdt-gdb-vscode/blob/36449f8ba2ce2a2fe47fa5b57adb3e25c3940269/package.json#L110-L118

Are you stepping on the step button next to the process you want to step, but the other one is stepping? I would look in the adapter log to see if the adapter is interpretting the input wrong, or if VSCode is sending an unexpected thread id. If the former, the bug is in the adapter and if the latter it is a vscode issue.

vinodappu commented 9 months ago

How can I see gdb trace? Any option in settings? I don't see any option when I checked. If I need to rebuild extension again, then it'll not help if I deployed it. Please guide.

colin-grant-work commented 7 months ago

When you set "verbose": true as @jonahgraham suggested, then you can see the data in the Debug Console:

launch.json:

image

Open Debug Console:

image

See all traffic between CDT-GDB Adapter and GDB:

image

When you initially encountered the problem, were you using the CDT GDB Amalgamator for debugging, or were the two sessions represented as separate debug sessions to VSCode?