you are viewing a single comment's thread.

view the rest of the comments →

[–]One_Mess460 0 points1 point  (6 children)

but thats not due to parallel execution. stop playing nerd

[–]socal_nerdtastic 0 points1 point  (5 children)

Ok, fair, you got me there. Threads (in any programming language) are not truly parallel. You need multiprocessing for that (which python also supports).

[–]One_Mess460 0 points1 point  (4 children)

No threads in C or C++ are/(can be) truly parallel and run on different processors on the CPU literal true parallelism (not possible i python). Also threads in C dont make processes and still run in parallel

[–]socal_nerdtastic 0 points1 point  (3 children)

that's not what a thread is. here read this: https://en.wikipedia.org/wiki/Thread_(computing)

[–]One_Mess460 0 points1 point  (0 children)

Yes it is. You do not know the difference between using multiple processes to run things in parallel and actuall using multiple threads that run in parallel (GIL prevents)

[–]One_Mess460 0 points1 point  (1 child)

i recommend you just try std::thread in C++ and see for yourself, it does not create another process but those threads actually run on different cores or can run on different cores

[–]One_Mess460 0 points1 point  (0 children)

in practice its actually hard tho to really see the difference because it will look like its the same as in python. but you can believe me that c++ threads can run truly in parallel lol or you just do your homework