Click here to Skip to main content
15,891,739 members
Home / Discussions / .NET (Core and Framework)
   

.NET (Core and Framework)

 
GeneralRe: Fundamental flaw with using multi-threading Pin
molesworth10-Sep-09 7:23
molesworth10-Sep-09 7:23 
GeneralRe: Fundamental flaw with using multi-threading Pin
Justin Fox10-Sep-09 8:05
Justin Fox10-Sep-09 8:05 
GeneralRe: Fundamental flaw with using multi-threading Pin
Dave Kreskowiak10-Sep-09 13:51
mveDave Kreskowiak10-Sep-09 13:51 
GeneralRe: Fundamental flaw with using multi-threading Pin
Dave Kreskowiak10-Sep-09 13:47
mveDave Kreskowiak10-Sep-09 13:47 
GeneralRe: Fundamental flaw with using multi-threading Pin
Richard MacCutchan10-Sep-09 7:30
mveRichard MacCutchan10-Sep-09 7:30 
GeneralRe: Fundamental flaw with using multi-threading Pin
Justin Fox10-Sep-09 7:52
Justin Fox10-Sep-09 7:52 
AnswerRe: Fundamental flaw with using multi-threading Pin
Justin Fox10-Sep-09 9:21
Justin Fox10-Sep-09 9:21 
GeneralRe: Fundamental flaw with using multi-threading Pin
Luc Pattyn10-Sep-09 10:06
sitebuilderLuc Pattyn10-Sep-09 10:06 
Threading techniques have a purpose; here are the two main reasons AFAIK.

1. Organizational asset.
Threads can be used to keep things clearly separated, by hiding them inside some classes, and making sure the threads, their locks and their shared data is not publicly accessible. Imagine an app needing to communicate with two serial ports; you either have to poll a lot, which is wasteful, or you assign a thread to each serial input, which can be neat and simple.

2. Performance asset.
Threads can be used to improve performance: any time your CPU is not running at 100% chances are your code is waiting on something instead of working on some other part of the same job, and that is where threading can help.

You may feel reluctant to use threads as you aren't sufficiently familiar with them; the same could apply to files, to databases, to regexes. You need to know them to use them properly. Files may seem easy, databases may be more difficult to get good performance, threads may frighten you. It all depends on your needs and your skills. And everything can be abused when you don't really understand the basics. Bugs are always possible, discipline, creating small entities, and performing tests (unit and other) should overcome most of the problems.

Smile | :)

Luc Pattyn

Have a look at my entry for the lean-and-mean competition; please provide comments, feedback, discussion, and don’t forget to vote for it! Thank you.

Local announcement (Antwerp region): Lange Wapper? Neen!


GeneralRe: Fundamental flaw with using multi-threading Pin
Richard MacCutchan11-Sep-09 0:37
mveRichard MacCutchan11-Sep-09 0:37 
AnswerIA64 makes me paranoid Pin
supercat911-Sep-09 7:55
supercat911-Sep-09 7:55 
GeneralRe: IA64 makes me paranoid Pin
harold aptroot11-Sep-09 8:06
harold aptroot11-Sep-09 8:06 
AnswerRe: Fundamental flaw with using multi-threading Pin
Daniel Grunwald14-Sep-09 11:23
Daniel Grunwald14-Sep-09 11:23 
QuestionRegistering .NET DLL without regasm Pin
hasan03050699-Sep-09 19:28
hasan03050699-Sep-09 19:28 
AnswerRe: Registering .NET DLL without regasm Pin
Dave Kreskowiak10-Sep-09 4:47
mveDave Kreskowiak10-Sep-09 4:47 
Questionhelp me. Pin
murktinez9-Sep-09 18:49
murktinez9-Sep-09 18:49 
AnswerRe: help me. Pin
Henry Minute10-Sep-09 2:32
Henry Minute10-Sep-09 2:32 
GeneralRe: help me. Pin
Richard MacCutchan10-Sep-09 7:32
mveRichard MacCutchan10-Sep-09 7:32 
AnswerRe: help me. Pin
Dave Kreskowiak10-Sep-09 4:45
mveDave Kreskowiak10-Sep-09 4:45 
AnswerRe: help me. Pin
Not Active10-Sep-09 8:30
mentorNot Active10-Sep-09 8:30 
QuestionClickOnce/MageUI Deployment Error - Using MageUI to add other assemblies to the install. Pin
Jake Slack9-Sep-09 10:23
Jake Slack9-Sep-09 10:23 
Questionproblem with ling Pin
Ebube9-Sep-09 5:43
Ebube9-Sep-09 5:43 
Questionproblem with ling Pin
Ebube9-Sep-09 5:43
Ebube9-Sep-09 5:43 
QuestionUnderstanding using statement Pin
Vipul Mehta9-Sep-09 0:56
Vipul Mehta9-Sep-09 0:56 
AnswerRe: Understanding using statement Pin
Eddy Vluggen9-Sep-09 1:24
professionalEddy Vluggen9-Sep-09 1:24 
AnswerRe: Understanding using statement Pin
Jaime Olivares9-Sep-09 3:13
Jaime Olivares9-Sep-09 3:13 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.