Thread names in Visual Studio and Mago
Random D user
no at email.com
Sun Sep 15 18:11:30 UTC 2019
I've been trying to set thread names for debugging, but it seems
Mago just ignores all names.
Using WinAPI function SetThreadDescription() I can get thread
name to show up in other programs (such as the very sleepy
profiler), but not in Visual Studio and Mago debugger. I also
tried the exception method as described here:
https://docs.microsoft.com/en-us/visualstudio/debugger/how-to-set-a-thread-name-in-native-code?view=vs-2019
core.thread.Thread also seems broken in terms of thread name. It
seems to just set a local name for the thread, but not
communicate that to the os. I suppose threads in Windows are
nameless outside of debugging, so perhaps that was just a poor
d-runtime design choice.
Anyway, Mago doesn't seem to look up the d-runtime name either.
Is there a way to show thread names in Visual Studio Mago? or is
it just unsupported.
Also it would be cool if the d runtime would name it's threads,
so that it would be easier and faster to pick the correct one.
More information about the Digitalmars-d-debugger
mailing list