Couldn't we improve the performance here by avoiding the map. Assuming the mass traces are sorted by RT (which I think is always the case we could use something like this, which is linear in the number of total peaks in the mass traces).

```cpp
std::list<std::pair<DoubleReal, DoubleReal> > peak_intensities;

for (typename FeatureFinderAlgorithmPickedHelperStructs::MassTraces< PeakType >::iterator t_it = traces.begin(); t_it != traces.end(); ++t_it)
{
    std::list<std::pair<DoubleReal, DoubleReal> >::iterator pi_it = peak_intensities.begin();
    std::vector<std::pair<DoubleReal, const Peak1D*> >::iterator peaks_it = t_it->peaks.begin();
    while(peaks_it != t_it->peaks.end() && (pi_it == peak_intensities.end() || pi_it->first > peaks_it->first))
    {
      // insert leading elements
      peak_intensities.push_back(std::make_pair(peaks_it->first, peaks_it->second->getIntensity()));
      ++peaks_it;
    }

    // insert peaks into the existing series
    while(peaks_it != t_it->peaks.end())
    {
      // find matching peak
      while(pi_it->first < peaks_it->first && !(pi_it == peak_intensities.end())) ++pi_it;
 
      // sum up if current peak == to list peak
      if(pi_it->first == peaks_it->first) pi_it->second += peaks_it->second->getIntensity();
      // .. or add new peak
      else pi_it = peak_intensities.insert(--pi_it, std::make_pair(peaks_it->first, peaks_it->second->getIntensity()));

      ++peaks_it;
    }
}
```

I assume you could even directly use the `peak_intensities` directly instead of copying the contents of the list. Or am I missing something here?