Click here to Skip to main content
15,880,469 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: C/C++ Optimization Pin
Stephen Hewitt9-Oct-11 4:56
Stephen Hewitt9-Oct-11 4:56 
AnswerRe: C/C++ Optimization Pin
Hans Dietrich9-Oct-11 5:38
mentorHans Dietrich9-Oct-11 5:38 
GeneralRe: C/C++ Optimization Pin
«_Superman_»9-Oct-11 16:50
professional«_Superman_»9-Oct-11 16:50 
AnswerRe: C/C++ Optimization Pin
Erudite_Eric9-Oct-11 5:48
Erudite_Eric9-Oct-11 5:48 
AnswerRe: C/C++ Optimization Pin
cmk9-Oct-11 8:42
cmk9-Oct-11 8:42 
GeneralRe: C/C++ Optimization Pin
Hans Dietrich10-Oct-11 3:03
mentorHans Dietrich10-Oct-11 3:03 
GeneralRe: C/C++ Optimization Pin
Randor 10-Oct-11 13:26
professional Randor 10-Oct-11 13:26 
GeneralRe: C/C++ Optimization Pin
cmk12-Oct-11 7:06
cmk12-Oct-11 7:06 
Good summary.

As you mention, the fast code option can can cause a cache miss. Additionally, earlier versions at least, could result in enough bloat to create extra pages. Related code, that under 'small' sits in the same page, could be split into different pages under 'fast'. This can result in more page faults. The performance impact due to page faults can exceed the speed improvements made from 'fast'.

So, based on past experience, and that these days the difference in optimization strategies is generally minor, I still use 'small'.

I haven't experienced the compiler ignoring my inline settings yet, have to check that, thanks.

The memset issue ... I ran into the same things years ago and found the following:
http://msdn2.microsoft.com/en-us/library/ms972826.aspx[^]
...cmk

The idea that I can be presented with a problem, set out to logically solve it with the tools at hand, and wind up with a program that could not be legally used because someone else followed the same logical steps some years ago and filed for a patent on it is horrifying.
- John Carmack

QuestionExcel automation. How to save as *.xls with Excel 2010? Pin
Falconapollo8-Oct-11 20:09
Falconapollo8-Oct-11 20:09 
GeneralRe: Excel automation. How to save as *.xls with Excel 2010? Pin
David Crow10-Oct-11 3:31
David Crow10-Oct-11 3:31 
Questionhow to specify the compiler search path?(Visual Studio 2005) Pin
Falconapollo8-Oct-11 19:06
Falconapollo8-Oct-11 19:06 
AnswerRe: how to specify the compiler search path?(Visual Studio 2005) Pin
PJ Arends8-Oct-11 20:37
professionalPJ Arends8-Oct-11 20:37 
GeneralRe: how to specify the compiler search path?(Visual Studio 2005) Pin
Falconapollo8-Oct-11 20:40
Falconapollo8-Oct-11 20:40 
AnswerRe: how to specify the compiler search path?(Visual Studio 2005) Pin
Niklas L8-Oct-11 23:14
Niklas L8-Oct-11 23:14 
AnswerRe: how to specify the compiler search path?(Visual Studio 2005) Pin
Richard MacCutchan8-Oct-11 23:21
mveRichard MacCutchan8-Oct-11 23:21 
AnswerRe: how to specify the compiler search path?(Visual Studio 2005) Pin
Luc Pattyn8-Oct-11 23:24
sitebuilderLuc Pattyn8-Oct-11 23:24 
Questionsending SMS in C++ Pin
Hadi Dayvary8-Oct-11 9:00
professionalHadi Dayvary8-Oct-11 9:00 
AnswerRe: sending SMS in C++ Pin
André Kraak8-Oct-11 9:14
André Kraak8-Oct-11 9:14 
GeneralRe: sending SMS in C++ Pin
Hadi Dayvary8-Oct-11 10:20
professionalHadi Dayvary8-Oct-11 10:20 
AnswerRe: sending SMS in C++ Pin
Erudite_Eric9-Oct-11 3:48
Erudite_Eric9-Oct-11 3:48 
GeneralRe: sending SMS in C++ Pin
Hadi Dayvary9-Oct-11 9:35
professionalHadi Dayvary9-Oct-11 9:35 
QuestionBasic Question About LRESULT Pin
AmbiguousName7-Oct-11 20:30
AmbiguousName7-Oct-11 20:30 
AnswerRe: Basic Question About LRESULT Pin
Richard MacCutchan7-Oct-11 21:11
mveRichard MacCutchan7-Oct-11 21:11 
Questionpriview of files Pin
VCProgrammer7-Oct-11 19:33
VCProgrammer7-Oct-11 19:33 
AnswerRe: priview of files Pin
Richard MacCutchan7-Oct-11 21:09
mveRichard MacCutchan7-Oct-11 21:09 

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.