<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div>Is it the case that you converge on the min faster than the mean?  </div><div><br></div><div>Right now there is no way to set a per-tester aggregation function.</div><div><br></div><div>I had spent a little time trying to detect regressions using k-means clustering.  It looked promising.  That was outside LNT though.</div><div><br></div><div><br></div><div><div><div>On Jan 16, 2014, at 11:28 PM, Tobias Grosser <<a href="mailto:tobias@grosser.es">tobias@grosser.es</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;">On 01/17/2014 03:09 AM, David Blaikie wrote:<br><blockquote type="cite">On Thu, Jan 16, 2014 at 5:32 PM, Tobias Grosser <<a href="mailto:tobias@grosser.es">tobias@grosser.es</a>> wrote:<br><br><blockquote type="cite">On 01/17/2014 02:17 AM, David Blaikie wrote:<br><br><blockquote type="cite">Right - you usually won't see a normal distribution in the noise of test<br>results. You'll see results clustered around the lower bound with a long<br>tail of slower and slower results. Depending on how many samples you do it<br>might be appropriate to take the mean of the best 3, for example - but the<br>general approach of taking the fastest N does have some basis in any case.<br><br>Not necessarily the right answer, the only right answer, etc.<br><br></blockquote><br>Interesting. In fact I had the very same thoughts at the beginning.<br><br>However, when looking at my test results the common pattern looks like<br>this example:<br><br><a href="http://llvm.org/perf/db_default/v4/nts/graph?show_all_">http://llvm.org/perf/db_default/v4/nts/graph?show_all_</a><br>points=yes&moving_window_size=10&plot.0=34.95.3&submit=Update<br><br>The run-time of a test case is very consistently one of several fixed<br>values. The distribution of the different times is very consistent and<br>seems to form, in fact, something like a normal distribution (more in the<br>center, less at the border).<br><br>The explanation I have here is that the machine is by itself in fact not<br>very noisy. Instead, changes of the execution context (e.g. due to<br>allocation of memory at a different location) influences the performance.<br>If we, by luck, have a run where all 'choices' have been optimal we get<br>minimal performance. However, in case of several independent factors, it is<br>more likely that we get a non-optimal configuration that yields a value in<br>the middle. Consequently, the minimal seems to be a non-optimal choice here.<br><br>I understand that there may be some 'real' noise values, but as the median<br>does not seem to be affected very much by 'extremal' values, I have the<br>feeling it should be reasonable robust to such noise.<br><br>Have you seen examples where the median value gives a wrong impression<br>regarding performance?<br><br></blockquote><br>I have - and I've also seen the kind of results you're seeing too. One of<br>the issues here is the quantization of results due to very short tests and<br>not very granular timing. This is perhaps the only reason the results even<br>/have/ a median (with finer grained timing and longer tests I expect you'd<br>see fewer results with exactly the same time - yes, you might be in a<br>situation where the exact runtimes repeat due to very short tests being<br>wholely scheduled in one way or another - but in that case you'll get wide,<br>solid swings depending on that scheduling behavior which is also unhelpful)<br>in your results.<br><br>It's one of the reasons I gave up on trying to do timing on Linux - I<br>couldn't get a machine quiet enough to look real. Though in the long run I<br>still did tend to get results for many tests that were clustered around a<br>minima with outliers going upwards...<br></blockquote><br>Interesting. How many tests did you run in general?<br><br><blockquote type="cite">I'm perhaps rambling a bit here, and I'm by no means an authority on this<br>subject (I tried and failed - gave up & worked on other things instead) but<br>I think so long as the data is that noisy and quantized like that, I'm not<br>sure how useful it'll be & not sure if it's the best data to be trying to<br>figure out data processing on. Maybe I'm wrong, perhaps this is as good as<br>that data can get and we do need an answer to how to handle it.<br></blockquote><br>As a first step, my current goal is to ensure that we do not report performance changes for test cases that have slightly noisy run-time behavior. Similar to Chandler, I have doubts we can use such changes to measure performance changes reliably.<br><br>I am also no authority in general here. In fact, I just look at my performance testers and try to take conclusions from this very limited picture. For the latest run using the 'median' again reduces the 'noise'<br>nicely. I get 13 noise results with the 'min' and only a single one with the median.<br><br><a href="http://llvm.org/perf/db_default/v4/nts/20686">http://llvm.org/perf/db_default/v4/nts/20686</a><br><br>It seems at least for my tester, this really helps to get the noise down. Is there a way I can switch the default displaying and reporting for my tester? Or, as you have kind of seen mixed results in both configurations, might we even be able to switch the default for now?<br><br>Cheers,<br>Tobias</div></blockquote></div><br></div></body></html>