Avatar of Frosty555
Frosty555
Flag for Canada asked on

What is joining and forking threads?

I have a high level understanding of threads, mutexes, etc. and about avoiding race conditions, sharing memory etc between threads, and making threads sleep / how timesharing works between threads and processes.

But my knowledge is very high-level, I'm used to using thread libraries like what is provided by .NET, Java or the QT library.

What does it mean to "fork" a thread, or "join" a thread, when you're dealing with POSIX threads in C? Also what is thread "signalling", if such a thing exists?
CC++Linux

Avatar of undefined
Last Comment
Narendra Kumar S S

8/22/2022 - Mon
SOLUTION
jkr

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
ASKER CERTIFIED SOLUTION
trinitrotoluene

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
trinitrotoluene

so with Windows you call CreateProcess() if you want to create a new process but though similar this is not identical to forking a process on Unix
Narendra Kumar S S

By the word "fork a thread", are you asking how to start a thread?
If that is so, then you should use pthread_create() call to create a new thread.
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck