There absolutely are times when performance can be a "make or break" metric. You state that you have been "scripting" for 10 years. This is a generalization, I know, but scripting usually means throwing together some tools to make life easier when it comes to repetitive tasks, maybe automating some daily procedures, etc. In these cases, the difference between the job finishing in 0.025 seconds and 0.5 seconds won't make a difference. Here, performance doesn't matter.

On the other hand, in application programming, performance can be the difference between a snappy, responsive system and one that is laggy and sluggish. Imagine a fighting game that took 1 second to translate your inputs into motions on the screen. You would have to predict what the enemy was about to do in order to react before they act.

For a non-game application example of when performance matters (to some), I just finished working on a complete re-write of our data access layer. It has to handle a total volume of 240 requests per second. It was built with the ability to scale with more hardware, but the hardware order was based on very early performance numbers. Later performance tests showed that we would not have enough hardware to support the volume of traffic and we did not have enough time to order more hardware.

After profiling the system, we were able to squeeze out more than 30% speed improvement by tweaking three subroutines. We swapped out Storable::dclone in favor of Clone::clone (which then proved to leak memory like a sieve) and got an easy 10%. Next, we optimized our sort algorithm and picked up about another 10%. Finally, we minutely tweaked a data accessor, speeding it up by about 0.01%. However, since we used strong data encapsulation throughout the system and this data accessor was used for every attribute of every class, this 0.01% in a single method resulted in an overall 10% gain in the system performance.

When all was said and done, we had brought the system well within the range of performance that we needed in order to launch and service the level of traffic we expected.

So, in short, there are times when performance can matter a lot. And trying to eek out that last little drop of performance can result in a massive win for you application. Without that little tweak, you cannot launch because your site could crash under the load; with it, you can launch and continue to grow.

Ivan Heffner
Sr. Software Engineer, DAS Lead
WhitePages.com, Inc.

In reply to Re: Is Performance Overrated? by Codon
in thread Is Performance Overrated? by pileofrogs

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.