I've recently been looking through the changes brought about by c++11, and honestly if DF was made in c++ it really shouldn't be too hard to implement multithreading support, now that it is supported by the standard library, and appears to be much much easier that the old way of doing it.
Basically
step 1: include <thread> header
step 2: change how functions are called so they are assigned to a thread
step 3: join thread with main
anything that is written as a series of functions should be easily converted to multi threaded support.
example of a program that prints hello world from 4 different threads.
#include <iostream>
#include <thread>
void helloworld() {
std::cout << "Hello, World!" << std::endl;
}
int main() {
std::thread t1(helloworld);
t1.join();
std::thread t2(helloworld);
t2.join();
std::thread t3(helloworld);
t3.join();
std::thread t4(helloworld);
t4.join();
return 0;
}
can someone with experience with c++11 tell me I'm wrong or agree with me?
Dont just say multithreading is harder than that if you don't know what your talking about.
most compilers aren't able to work with c++11 yet, which is kind of lame.
including the one I'm working with, and I really don't want to change my ide,
perhaps when I get around to actually using some of the new c++11 features either the compiler I'm using will be upgraded, or I can swap out the compiler but still use my ide.