News:

As usual while waiting for the next release - don't forget to check the nightly builds in the forum.

Main Menu

Is Multithreading possible in CodeBlocks?

Started by ScriptKiddy, October 23, 2009, 05:20:09 AM

Previous topic - Next topic

ScriptKiddy

Hi, I have been programming for about 2 years now, and my absolute favorite compiler to use is, and always will be Code::Blocks.

However, one problem I have had is not being able to run two threads at once.  I can run one thread using _beginthread, but I cannot run two at the same time.  I know it has to be possible to run two threads at the same time in codeblocks, (for example, one using SOCKETS, the other using directx)  Is this possible?  If it is, how would I run two threads at the same time in codeblocks?  (PS: I know how to do it in VC++ 06, but I had a linking problem, and don't want to use VC++ 08)

ollydbg

If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.

Jenna

Quote from: ollydbg on October 23, 2009, 06:45:39 AM
This topic is not related to C::B.

So the topic gets locked !!

Quote from: ScriptKiddy on October 23, 2009, 05:20:09 AM
Hi, I have been programming for about 2 years now, and my absolute favorite compiler to use is, and always will be Code::Blocks.

However, one problem I have had is not being able to run two threads at once.  I can run one thread using _beginthread, but I cannot run two at the same time.  I know it has to be possible to run two threads at the same time in codeblocks, (for example, one using SOCKETS, the other using directx)  Is this possible?  If it is, how would I run two threads at the same time in codeblocks?  (PS: I know how to do it in VC++ 06, but I had a linking problem, and don't want to use VC++ 08)

Be aware that C::B is not a compiler, "just" an IDE.
Read the documentation of the compiler you use and/or ask this question in a forum dedicated to this compiler.