Click here to Skip to main content
15,916,188 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
JokeRe: Handling the maximize option for the MFC application in the taskmanager. Pin
Jijo.Raj19-Aug-08 7:56
Jijo.Raj19-Aug-08 7:56 
GeneralRe: Handling the maximize option for the MFC application in the taskmanager. [modified] Pin
hariakuthota19-Aug-08 8:08
hariakuthota19-Aug-08 8:08 
AnswerRe: Handling the maximize option for the MFC application in the taskmanager. Pin
Jijo.Raj19-Aug-08 7:51
Jijo.Raj19-Aug-08 7:51 
QuestionQuestion Regarding ScrollView Pin
godspeed12319-Aug-08 5:50
godspeed12319-Aug-08 5:50 
AnswerRe: Question Regarding ScrollView Pin
led mike19-Aug-08 6:00
led mike19-Aug-08 6:00 
GeneralRe: Question Regarding ScrollView Pin
godspeed12319-Aug-08 6:06
godspeed12319-Aug-08 6:06 
GeneralRe: Question Regarding ScrollView Pin
led mike19-Aug-08 6:44
led mike19-Aug-08 6:44 
QuestionImpact of synchronization on application performances Pin
Ahmed Charfeddine19-Aug-08 5:30
Ahmed Charfeddine19-Aug-08 5:30 
I have a multithreaded application with common data to be protected among threads.
For example I have lots of calls to the following functions from many threads :
CString getName()
{
return myName;
}

and :

void setName(CString myName)
{
this->myName=myName;
}


In deed the call to setName is very rare, and also when there is a conflit (the two functions execute at the same time, or two copies of setName are executed by two threads) even if it results in data corruption, then it is Ok, ie it is not very dangerous.


The problem is that I noted that the application crashes at that point (release and debug).


Now what is the solution ?
From the one hand I am furious that the application crash, I can't play with probabilty becuase it is a server application supposed to running 24/24.
But from the other, if I add data protection, ie like CriticalSections, then I fear for the degradation of performance.


If the addition of data protection or thread synchronization is to cause the necessary blocking of threads untill other exit the protected code blocks or data, then it is OK for me, but I want tolerate any unnecessary delay,etc. For I have at least 700 call to getName for example per thread per 3 seconds.

Our Philosophy, Mohammed Baqir Al Sadr

AnswerRe: Impact of synchronization on application performances Pin
Roger Stoltz19-Aug-08 5:51
Roger Stoltz19-Aug-08 5:51 
GeneralRe: Impact of synchronization on application performances Pin
Ahmed Charfeddine19-Aug-08 6:16
Ahmed Charfeddine19-Aug-08 6:16 
GeneralRe: Impact of synchronization on application performances Pin
Ahmed Charfeddine19-Aug-08 22:12
Ahmed Charfeddine19-Aug-08 22:12 
AnswerRe: Impact of synchronization on application performances Pin
Roger Stoltz19-Aug-08 22:46
Roger Stoltz19-Aug-08 22:46 
GeneralRe: Impact of synchronization on application performances Pin
Ahmed Charfeddine19-Aug-08 22:53
Ahmed Charfeddine19-Aug-08 22:53 
AnswerRe: Impact of synchronization on application performances Pin
Roger Stoltz19-Aug-08 23:39
Roger Stoltz19-Aug-08 23:39 
GeneralRe: Impact of synchronization on application performances Pin
Ahmed Charfeddine20-Aug-08 0:16
Ahmed Charfeddine20-Aug-08 0:16 
GeneralRe: Impact of synchronization on application performances Pin
Roger Stoltz20-Aug-08 4:33
Roger Stoltz20-Aug-08 4:33 
GeneralRe: Impact of synchronization on application performances Pin
Ahmed Charfeddine20-Aug-08 5:54
Ahmed Charfeddine20-Aug-08 5:54 
AnswerRe: Impact of synchronization on application performances Pin
Jijo.Raj19-Aug-08 6:40
Jijo.Raj19-Aug-08 6:40 
GeneralRe: Impact of synchronization on application performances Pin
Ahmed Charfeddine19-Aug-08 6:53
Ahmed Charfeddine19-Aug-08 6:53 
GeneralRe: Impact of synchronization on application performances Pin
Jijo.Raj19-Aug-08 7:19
Jijo.Raj19-Aug-08 7:19 
GeneralRe: Impact of synchronization on application performances Pin
Ahmed Charfeddine19-Aug-08 21:50
Ahmed Charfeddine19-Aug-08 21:50 
GeneralRe: Impact of synchronization on application performances Pin
Cedric Moonen19-Aug-08 7:22
Cedric Moonen19-Aug-08 7:22 
GeneralRe: Impact of synchronization on application performances Pin
Ahmed Charfeddine20-Aug-08 0:39
Ahmed Charfeddine20-Aug-08 0:39 
GeneralRe: Impact of synchronization on application performances Pin
Cedric Moonen20-Aug-08 1:08
Cedric Moonen20-Aug-08 1:08 
GeneralRe: Impact of synchronization on application performances Pin
Ahmed Charfeddine20-Aug-08 1:37
Ahmed Charfeddine20-Aug-08 1:37 

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.