By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,925 Members | 1,134 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,925 IT Pros & Developers. It's quick & easy.

Threading?

P: 74
Can someone give me a description of what "threading" is in programing. thank you!!!!!!
Mar 20 '07 #1
Share this Question
Share on Google+
2 Replies


Roonie
P: 99
the way that a computer runs programs is to create different processes for the processor to execute. theres a lot to keeping track of it all, but basically, this is what enables your computer to mulittask. (your computer never runs more than one process at a time - unless you have multiple processors - but by switching back and forth between them fast enough, it fools you into thinking that there are many different things running at once.) user and system programs are both executed in this way.

each process has a code section, a stack, etc. . . . a thread is the executing part of your process. by creating multiple threads, you can have your process pseudo-execute-in-more-than-one-place-at-once. this is useful if, say, you have one thread doing i/o (which is typically slow in computing terms) . . . you can also have a thread running a computational section, so as to not tie up that portion of things while your program has blocked waiting for the hard drive, for instance.
Mar 20 '07 #2

P: 74
Thanks .
Mar 20 '07 #3

Post your reply

Sign in to post your reply or Sign up for a free account.