r/C_Programming • u/Read-Documentation-7 • Jun 07 '26
Why Processes?
Hello. I was wondering what are the benefits of using processes over threads. I understand the differences between the two, but I am having trouble trying to understand when would be the best use case to implement them. Can someone give me some advice for when processes should be used? Thanks.
38
Upvotes
View all comments
Show parent comment
3
u/johnwcowan Jun 07 '26
Changing the wd in one process does not affect the wd in any other process. The contents of mmaped memory twithout MM_PRIVATE is indeed shared, which is a special case if sharing files.