<div dir="ltr">Hey,<br><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Sep 28, 2015 at 3:29 PM, Noel Grandin <span dir="ltr"><<a href="mailto:noelgrandin@gmail.com" target="_blank">noelgrandin@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><br>
<br>
On 2015-09-28 03:11 PM, Markus Mohrhard wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
<br>
I'm not sure if I understand your comment. Can you please clarify what you mean with that? Maybe my understanding of our<br>
memory allocators is bad but I see not how this comment applies to the discussion.<br>
<br>
</blockquote>
<br></span>
I'm saying that in general I regard changing allocators as doing optimisation in the wrong place - if your allocator is a real bottle-neck, you would probably be better off looking at optimising the code that __calls__ the allocator, rather than messing with the allocator itself.<br>
<br>
For example, if you had code that did:<br>
   vector<int> buffer;<br>
   for (int i=0; i<1000000000; i++)<br>
        buffer.push_back(i);<br>
you'd be better off inserting a<br>
   buffer.reserve(1000000000)<br>
just before the loop, to avoid the std::vector's resize-and-copy operation.<br>
<br>
But that's just my opinion, feel free to experiment away if allocators are your thing :-)<br></blockquote><div><br></div><div>I think there is a misunderstanding. We are using a custom allocator currently (well disabled by default since this morning) for all memory allocations. So I don't see how working on the algorithms helps here. The custom allocator there is used to work around some problems with the system allocator (apparently mostly on windows). I was only experimenting to see if our custom memory allocator is responsible for some of the performance problems that we see on the <a href="http://perf.libreoffice.org">perf.libreoffice.org</a> site. However after disabling the custom memory allocator we have up to 20% performance regressions in some test cases so I will switch back to the custom allocator at some point.<br><br></div><div>I still can't explain the 200x performance regression that we see with the in-tree tests since adding one additional performance test.<br><br></div><div>Regards,<br></div><div>Markus<br></div><div><br> <br></div></div><br></div></div>