From: Le Chaud Lapin on 9 Dec 2009 03:49 On Dec 8, 6:40 pm, George Neuner <gneun...(a)comcast.net> wrote: > On Mon, 7 Dec 2009 13:51:13 CST, Le Chaud Lapin > IMO, always calling the function is a cop out ... generating correct > inline code really isn't that hard and you can always limit the > inlined cases to those that are aligned and simple to count and fall > back on the general function for everything else. This is one case > where I think M$ really screwed up. > > George That is essentially my sentiment. What suprises me is that there are so often the compiler designer is unable to employ an optimization because there exist the potential of a rare-but-treacherous code sequence that would negate its validity. In this case, not only is the optimization always employable, but the _memcpy alternative actually results in less contextual information than existed before the call to it. But I really like M$ compilers, so I have to tell myself that they have a good reason for doing this other than laziness. :D -Le Chaud Lapin- -- [ See http://www.gotw.ca/resources/clcm.htm for info about ] [ comp.lang.c++.moderated. First time posters: Do this! ]
|
Pages: 1 Prev: concurrent linked queue class for C++? Next: Sequence Point |