title: Implicit new and delete operator killing perfomance
body: <p>I am running very sleepy to profile my application and its showing me that 25% and 23% of the time spent by my function is doing new and delete respectively. I don't understand where this is occurring. So can someone tell me where this is occurring in my code. </p>
  
  <pre><code>inline FixParser(fixmessage&amp; tokenMap, const std::string&amp; str) {
    static seperator sep_delim("\x01");
    static seperator sep_equal("=");
    static std::string error("ERROR: ");
    static FixKey fix_Key;
    static tokenizer token_equal(error);
    static tokenizer token_delim(error);
    static tokenizer::iterator itr;
    token_delim.assign(str, sep_delim);
    int key;
    try {
      for(tokenizer::iterator it = token_delim.begin(); 
          it != token_delim.end(); ++it) {
        token_equal.assign(*it, sep_equal);
        itr = token_equal.begin();
        key = boost::lexical_cast&lt;int&gt;(*itr);
        if(fix_Key.keys.find(key) == fix_Key.keys.end()) continue;
        ++itr;
        const std::string&amp; value(*itr);
        tokenMap.insert(std::pair&lt;int, std::string&gt;(key, value));
      }
    } catch(boost::bad_lexical_cast &amp;) {
      std::cerr &lt;&lt; error &lt;&lt; str &lt;&lt; std::endl;
      return;
    }
  }
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/lkn0A.jpg" alt="very sleepy results"></p>
  
  <p>I beg forgiveness for the use of <code>static</code> they will be removed later and placed in a <code>struct</code>.</p>