Click here to Skip to main content
15,899,026 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionOptimization techniques Pin
himuskanhere5-Jul-07 1:39
himuskanhere5-Jul-07 1:39 
AnswerRe: Optimization techniques Pin
CPallini5-Jul-07 1:57
mveCPallini5-Jul-07 1:57 
AnswerRe: Optimization techniques Pin
KarstenK5-Jul-07 2:54
mveKarstenK5-Jul-07 2:54 
AnswerRe: Optimization techniques Pin
led mike5-Jul-07 4:44
led mike5-Jul-07 4:44 
GeneralRe: Optimization techniques Pin
Joan M5-Jul-07 7:14
professionalJoan M5-Jul-07 7:14 
GeneralRe: Optimization techniques Pin
led mike5-Jul-07 7:28
led mike5-Jul-07 7:28 
AnswerRe: Optimization techniques Pin
#realJSOP5-Jul-07 7:12
professional#realJSOP5-Jul-07 7:12 
AnswerRe: Optimization techniques Pin
Joe Woodbury5-Jul-07 10:02
professionalJoe Woodbury5-Jul-07 10:02 
Remember that 90% of bottlenecks are in 10% of the code. Using straight forward C/C++ is actually the best common place optimization since it allows the compiler to do the work. Aside from that, you should get a profile and identify where the bottlenecks are. In some cases, like with hardware access, you can do nothing about performance except upgrade the hardware. In places where you can optimize, I've found that parsing code is a common place to look. Code that uses many small allocations is also a big killer (and problematic in other ways.)

My favorite profile is DevPartner (http://www.compuware.com/products/devpartner/visualc.htm[^]) though it gotten rather expensive as of late.

Added: Building on what John Simmons says--do not optimize code, optimize algorithms. (In other words, no matter how much you try to optimize a bad algorithm, it's still a bad algorithm.)



Anyone who thinks he has a better idea of what's good for people than people do is a swine.
- P.J. O'Rourke

AnswerRe: Optimization techniques Pin
kakan5-Jul-07 19:43
professionalkakan5-Jul-07 19:43 
GeneralRe: Optimization techniques Pin
DevMentor.org8-Jul-07 23:51
DevMentor.org8-Jul-07 23:51 
GeneralRe: Optimization techniques Pin
himuskanhere19-Jul-07 20:32
himuskanhere19-Jul-07 20:32 
GeneralRe: Optimization techniques Pin
DevMentor.org19-Jul-07 21:28
DevMentor.org19-Jul-07 21:28 
QuestionWhat is Data Execution Prevention? Pin
Amar Sutar5-Jul-07 1:13
Amar Sutar5-Jul-07 1:13 
AnswerRe: What is Data Execution Prevention? Pin
Chris Losinger5-Jul-07 1:22
professionalChris Losinger5-Jul-07 1:22 
QuestionHow to set CDialog's minimum size? Pin
Peter, Chan5-Jul-07 0:37
Peter, Chan5-Jul-07 0:37 
AnswerRe: How to set CDialog's minimum size? Pin
Nibu babu thomas5-Jul-07 0:42
Nibu babu thomas5-Jul-07 0:42 
AnswerRe: How to set CDialog's minimum size? Pin
Iain Clarke, Warrior Programmer5-Jul-07 0:45
Iain Clarke, Warrior Programmer5-Jul-07 0:45 
QuestionThrow Pin
sanjutvm4-Jul-07 23:58
sanjutvm4-Jul-07 23:58 
AnswerRe: Throw Pin
toxcct5-Jul-07 0:10
toxcct5-Jul-07 0:10 
GeneralRe: Throw Pin
tom groezer5-Jul-07 5:25
tom groezer5-Jul-07 5:25 
GeneralRe: Throw Pin
toxcct5-Jul-07 5:35
toxcct5-Jul-07 5:35 
QuestionRe: Throw Pin
Mark Salsbery5-Jul-07 8:13
Mark Salsbery5-Jul-07 8:13 
AnswerRe: Throw Pin
toxcct5-Jul-07 21:20
toxcct5-Jul-07 21:20 
AnswerRe: Throw Pin
Mark Salsbery5-Jul-07 8:11
Mark Salsbery5-Jul-07 8:11 
GeneralRe: Throw Pin
DevMentor.org9-Jul-07 0:02
DevMentor.org9-Jul-07 0:02 

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.