Path: csiph.com!x330-a1.tempe.blueboxinc.net!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!border3.nntp.dca.giganews.com!Xl.tags.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!local2.nntp.dca.giganews.com!news.giganews.com.POSTED!not-for-mail NNTP-Posting-Date: Fri, 24 Jun 2011 06:34:35 -0500 From: Pete Becker Organization: Roundhouse Consulting, Ltd. Newsgroups: comp.lang.c++ Date: Fri, 24 Jun 2011 07:34:35 -0400 Message-ID: <2011062407343596122-pete@versatilecodingcom> References: <2879c8f0-969f-4ecb-8da8-86874b949168@t38g2000prj.googlegroups.com> <67239772-4eef-4db5-be19-01a792194bb2@c41g2000yqm.googlegroups.com> <96j3l5Fb9tU1@mid.individual.net> <64e7c240-e321-4550-b65b-265f6950e2d3@x38g2000pri.googlegroups.com> <96j62qFb9tU3@mid.individual.net> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1; format=flowed Content-Transfer-Encoding: 8bit Subject: Re: Fast swapping of STL containers User-Agent: Unison/2.1.4 Lines: 30 X-Usenet-Provider: http://www.giganews.com X-Trace: sv3-iwKqW/3j5THry7y/PsjMefWfKrAmlMieh+dMaaA698+QtyWqD+exuu2jzknXaJxN8rbme0axVVERm8O!jSxqll+LwaEjeir4jTTchKxuXom7mCfoMxIGLUWJXPBcoAgABX4/Xv5Q5B+z+sYONx+YySCk X-Complaints-To: abuse@giganews.com X-DMCA-Notifications: http://www.giganews.com/info/dmca.html X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.3.40 X-Original-Bytes: 2408 Xref: x330-a1.tempe.blueboxinc.net comp.lang.c++:7115 On 2011-06-24 06:09:10 -0400, Ian Collins said: > On 06/24/11 09:58 PM, ittium wrote: > > Please don't snip attributions! > > > On 06/24/11 09:27 PM, Ian Collins wrote: >> >>> Well come on, it's the library author's job to write efficient code. If >>> they didn't, users would soon complain. They have implementation >>> specific short cuts available to them that we users do not. >>> >> >> For most of the cases, You are right. When a operation is likely to >> take place large number of times per second than exact processing >> complexity becomes very important. > > What difference does the number of calls make? The operation is either > efficient, or it isn't. The more it's called, the more likely it is to be a bottleneck. If I only call a function once, it doesn't matter whether it takes 1 ms or 2 ms. -- Pete Roundhouse Consulting, Ltd. (www.versatilecoding.com) Author of "The Standard C++ Library Extensions: a Tutorial and Reference (www.petebecker.com/tr1book)