diff --git a/patching/patches/criterion-1.0.0.2.patch b/patching/patches/criterion-1.0.0.2.patch index 86f07229..537611a3 100644 --- a/patching/patches/criterion-1.0.0.2.patch +++ b/patching/patches/criterion-1.0.0.2.patch @@ -1,6 +1,6 @@ diff -ruN orig/criterion.cabal new/criterion.cabal ---- orig/criterion.cabal 2014-08-10 16:13:33.958136765 +0300 -+++ new/criterion.cabal 2014-08-10 16:13:33.000000000 +0300 +--- orig/criterion.cabal 2014-08-10 20:30:05.797809138 +0300 ++++ new/criterion.cabal 2014-08-10 20:30:05.000000000 +0300 @@ -131,6 +131,7 @@ type: exitcode-stdio-1.0 hs-source-dirs: tests @@ -9,3 +9,1635 @@ diff -ruN orig/criterion.cabal new/criterion.cabal ghc-options: -Wall -threaded -O0 -rtsopts +diff -ruN orig/examples/fibber.html new/examples/fibber.html +--- orig/examples/fibber.html 2014-08-10 20:30:05.789809138 +0300 ++++ new/examples/fibber.html 1970-01-01 02:00:00.000000000 +0200 +@@ -1,726 +0,0 @@ +- +- +- +- +- criterion report +- +- +- +- +- +- +- +-
+-
+-

criterion performance measurements

+- +-

overview

+- +-

want to understand this report?

+- +-
+- +-

fib/1

+- +- +- +- +- +- +- +- +-
+- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +-
lower boundestimateupper bound
OLS regressionxxxxxxxxx
R² goodness-of-fitxxxxxxxxx
Mean execution time2.31459993168433e-82.374225969306158e-82.4336041431094957e-8
Standard deviation1.7147402747620926e-91.984234308811127e-92.3435359738948246e-9
+- +- +-

Outlying measurements have severe +- (0.8827515417826841%) +- effect on estimated standard deviation.

+-
+-

fib/5

+- +- +- +- +- +- +- +- +-
+- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +-
lower boundestimateupper bound
OLS regressionxxxxxxxxx
R² goodness-of-fitxxxxxxxxx
Mean execution time3.640686812141915e-73.7647973827317373e-73.8862828356384757e-7
Standard deviation3.5904833037515274e-84.150785932735141e-84.81505001531474e-8
+- +- +-

Outlying measurements have severe +- (0.917699613099007%) +- effect on estimated standard deviation.

+-
+-

fib/9

+- +- +- +- +- +- +- +- +-
+- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +-
lower boundestimateupper bound
OLS regressionxxxxxxxxx
R² goodness-of-fitxxxxxxxxx
Mean execution time2.5489390737084626e-62.614524699113428e-62.700766045605913e-6
Standard deviation2.0893167057513842e-72.4922772413717383e-73.0480780278156827e-7
+- +- +-

Outlying measurements have severe +- (0.86814310186276%) +- effect on estimated standard deviation.

+-
+-

fib/11

+- +- +- +- +- +- +- +- +-
+- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +-
lower boundestimateupper bound
OLS regressionxxxxxxxxx
R² goodness-of-fitxxxxxxxxx
Mean execution time6.347714383730146e-66.496202868182492e-66.668634037917654e-6
Standard deviation4.0420784296930194e-74.919233380857326e-76.202125623223447e-7
+- +- +-

Outlying measurements have severe +- (0.7876656352417168%) +- effect on estimated standard deviation.

+-
+- +-

understanding this report

+- +-

In this report, each function benchmarked by criterion is assigned +- a section of its own. The charts in each section are active; if +- you hover your mouse over data points and annotations, you will see +- more details.

+- +- +- +-

Under the charts is a small table. +- The first two rows are the results of a linear regression run +- on the measurements displayed in the right-hand chart.

+- +- +- +-

We use a statistical technique called +- the bootstrap +- to provide confidence intervals on our estimates. The +- bootstrap-derived upper and lower bounds on estimates let you see +- how accurate we believe those estimates to be. (Hover the mouse +- over the table headers to see the confidence levels.)

+- +-

A noisy benchmarking environment can cause some or many +- measurements to fall far from the mean. These outlying +- measurements can have a significant inflationary effect on the +- estimate of the standard deviation. We calculate and display an +- estimate of the extent to which the standard deviation has been +- inflated by outliers.

+- +- +- +-
+-
+- +- +- +diff -ruN orig/examples/maps.html new/examples/maps.html +--- orig/examples/maps.html 2014-08-10 20:30:05.789809138 +0300 ++++ new/examples/maps.html 1970-01-01 02:00:00.000000000 +0200 +@@ -1,552 +0,0 @@ +- +- +- +- +- criterion report +- +- +- +- +- +- +- +-
+-
+-

criterion performance measurements

+- +-

overview

+- +-

want to understand this report?

+- +-
+- +-

ByteString/HashMap/random

+- +- +- +- +- +- +- +- +-
+- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +-
lower boundestimateupper bound
OLS regressionxxxxxxxxx
R² goodness-of-fitxxxxxxxxx
Mean execution time5.54613319607341e-35.621667703915931e-35.713526073454561e-3
Standard deviation1.972562820146363e-42.494938876886024e-43.1487131555210624e-4
+- +- +-

Outlying measurements have moderate +- (0.21993690418913867%) +- effect on estimated standard deviation.

+-
+- +-

understanding this report

+- +-

In this report, each function benchmarked by criterion is assigned +- a section of its own. The charts in each section are active; if +- you hover your mouse over data points and annotations, you will see +- more details.

+- +- +- +-

Under the charts is a small table. +- The first two rows are the results of a linear regression run +- on the measurements displayed in the right-hand chart.

+- +- +- +-

We use a statistical technique called +- the bootstrap +- to provide confidence intervals on our estimates. The +- bootstrap-derived upper and lower bounds on estimates let you see +- how accurate we believe those estimates to be. (Hover the mouse +- over the table headers to see the confidence levels.)

+- +-

A noisy benchmarking environment can cause some or many +- measurements to fall far from the mean. These outlying +- measurements can have a significant inflationary effect on the +- estimate of the standard deviation. We calculate and display an +- estimate of the extent to which the standard deviation has been +- inflated by outliers.

+- +- +- +-
+-
+- +- +- +diff -ruN orig/templates/default2.tpl new/templates/default2.tpl +--- orig/templates/default2.tpl 2014-08-10 20:30:05.793809138 +0300 ++++ new/templates/default2.tpl 1970-01-01 02:00:00.000000000 +0200 +@@ -1,296 +0,0 @@ +- +- +- +- +- criterion report +- +- +- +- +- +- +- +- +-
+-
+-

criterion performance measurements

+- +-

overview

+- +-

want to understand this report?

+- +-
+- +-{{#report}} +-

{{name}}

+- +- +- +- +- +- +- +- +-
+- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +-
lower boundestimateupper bound
Mean execution time{{anMean.estLowerBound}}{{anMean.estPoint}}{{anMean.estUpperBound}}
Standard deviation{{anStdDev.estLowerBound}}{{anStdDev.estPoint}}{{anStdDev.estUpperBound}}
+- +- +-

Outlying measurements have {{anOutlierVar.ovDesc}} +- ({{anOutlierVar.ovFraction}}%) +- effect on estimated standard deviation.

+-
+-{{/report}} +- +-

understanding this report

+- +-

In this report, each function benchmarked by criterion is assigned +- a section of its own. In each section, we display two charts, each +- with an x axis that represents measured execution time. +- These charts are active; if you hover your mouse over data points +- and annotations, you will see more details.

+- +- +- +-

Under the charts is a small table displaying the mean and standard +- deviation of the measurements. We use a statistical technique +- called +- the bootstrap +- to provide confidence intervals on our estimates of these values. +- The bootstrap-derived upper and lower bounds on the mean and +- standard deviation let you see how accurate we believe those +- estimates to be. (Hover the mouse over the table headers to see +- the confidence levels.)

+- +-

A noisy benchmarking environment can cause some or many +- measurements to fall far from the mean. These outlying +- measurements can have a significant inflationary effect on the +- estimate of the standard deviation. We calculate and display an +- estimate of the extent to which the standard deviation has been +- inflated by outliers.

+- +- +- +-
+-
+- +- +- +diff -ruN orig/tests/Properties.hs new/tests/Properties.hs +--- orig/tests/Properties.hs 1970-01-01 02:00:00.000000000 +0200 ++++ new/tests/Properties.hs 2014-08-10 20:30:05.000000000 +0300 +@@ -0,0 +1,42 @@ ++{-# LANGUAGE CPP #-} ++{-# OPTIONS_GHC -fno-warn-orphans #-} ++ ++module Properties (tests) where ++ ++import Control.Applicative ((<$>)) ++import Criterion.Analysis ++import Statistics.Types (Sample) ++import Test.Framework (Test, testGroup) ++import Test.Framework.Providers.QuickCheck2 (testProperty) ++import Test.QuickCheck ++import qualified Data.Vector.Generic as G ++import qualified Data.Vector.Unboxed as U ++ ++#if __GLASGOW_HASKELL__ >= 704 ++import Data.Monoid ((<>)) ++#else ++import Data.Monoid ++ ++(<>) :: Monoid m => m -> m -> m ++(<>) = mappend ++infixr 6 <> ++#endif ++ ++instance (Arbitrary a, U.Unbox a) => Arbitrary (U.Vector a) where ++ arbitrary = U.fromList <$> arbitrary ++ shrink = map U.fromList . shrink . U.toList ++ ++outlier_bucketing :: Double -> Sample -> Bool ++outlier_bucketing y ys = ++ countOutliers (classifyOutliers xs) <= fromIntegral (G.length xs) ++ where xs = U.cons y ys ++ ++outlier_bucketing_weighted :: Double -> Sample -> Bool ++outlier_bucketing_weighted x xs = ++ outlier_bucketing x (xs <> G.replicate (G.length xs * 10) 0) ++ ++tests :: Test ++tests = testGroup "Properties" [ ++ testProperty "outlier_bucketing" outlier_bucketing ++ , testProperty "outlier_bucketing_weighted" outlier_bucketing_weighted ++ ]