Compare _beginhread / _beginhreadex / CreateThread in Windows threading

Asked 1 years ago, Updated 1 years ago, 135 views

I want to know the pros and cons of comparing those three.

All 3 functions create a new thread.

I know that it's easier to know the error when you call CreateThread

Can you compare how the other three are different?

(It's only for Windows, so you don't need to talk about other platforms)

multithreading c++ winapi

2022-09-22 22:18

1 Answers

_beginhread/ex() is doing important things, not just singing CreateThread(), but also storing additional information about the new thread In C++, you must use _beginhreadex() to link to the Cruntime library.

The difference between _beginhread() and _beginhreadex() is Microsoft - Developer Network.


2022-09-22 22:18

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.