Search Results
Search type | Search syntax |
---|---|
Tags | [tag] |
Exact | "words here" |
Author |
user:1234 user:me (yours) |
Score |
score:3 (3+) score:0 (none) |
Answers |
answers:3 (3+) answers:0 (none) isaccepted:yes hasaccepted:no inquestion:1234 |
Views | views:250 |
Code | code:"if (foo != bar)" |
Sections |
title:apples body:"apples oranges" |
URL | url:"*.example.com" |
Saves | in:saves |
Status |
closed:yes duplicate:no migrated:no wiki:no |
Types |
is:question is:answer |
Exclude |
-[tag] -apples |
For more details on advanced search visit our help page |
Multi-threading related questions including technique, structure, and safety issues.
59
votes
Accepted
Why should your code not use 100% CPU?
If cooling is insufficient, the CPU might overheat. But they all (well, at least all modern PC CPUs) feature various thermal protection mechanisms which will throttle the clock speed or, as a final re …
16
votes
Accepted
Parallelism implies concurrency but not the other way round right?
According to Wikipedia:
Parallel computing is a form of computation in which many calculations are carried out simultaneously, operating on the principle that large problems can often be divided i …
0
votes
What constitutes proper use of threads in programming?
The apps you mention are rarely running all those tens of threads simultaneously. Most of them just sit there because they're in a thread pool. The app send various tasks to a queue, which is purged b …
2
votes
What is the point where multitreaded programming becomes slower than the problem?
Basically, when parallelizing, the optimum number of threads == number of cores. This is because then each core runs exactly one thread; all cores are doing work, but there's no need to switch the thr …
0
votes
How do I unit test multi-threaded code?
It's not easy, but basically the only way is to call the multi-threaded code concurrently from multiple threads and change timing and ordering randomly by playing with random Thread.sleep() and Thread …