Just FYI, Windows' way to have the program affect thread names in the debugger is with SetThreadName, which throws a magic exception which the debugger can catch. GDB doesn't know about this though.
http://msdn.microsoft.com/en-us/library/xcb2z8hs.aspx Just for completeness... I don't know if there's a native method that's closer to pthread_setname_np's semantics. -- Pedro Alves