I know there are several ways to multi thread - but i want to know whats the best (efficiency) - even it would be interesting to know whats the easiest..
ps: i know.. my english is bad :D
Printable View
I know there are several ways to multi thread - but i want to know whats the best (efficiency) - even it would be interesting to know whats the easiest..
ps: i know.. my english is bad :D
Depends entirely upon your operating system, and your compilers support for what ever features it offers. You fail to mention either.
independent of os and compiler isn't possible?!
No. There are operating systems which have no concept of threads; C is a very general language and so it doesn't cover system-specific features. Things like graphics, sound, threads, etc. are all system-specific and compiler-specific.
Pthreads for Linux is a fairly common C threading library.
Your question is too vague to answer considering the complexities of different compilers and operating systems.
The generic answer is
there is no best way, only the ways that
1) you understand
2) work correctly
3) do the job asked
i like the generic answer WaltP :D
Well, then, there you go! ;)Quote:
Originally posted by IceBall
i like the generic answer WaltP :D