Skip to content
Permalink
Browse files

Bump the margin of a performance test

According to the original issue one of the variants wasn't simply
slower but rather used to hang. To test for the hang, the margin can
be relatively large. Currently the difference is about 2x, which means
that the test flapped depending on the system's load. Bumping it to 5x
should be good enough in most of the cases.

Resolves GH-3065.
  • Loading branch information...
AlexDaniel committed Jul 25, 2019
1 parent e18b4f3 commit bd29d3f64345ca2f9cf3e37f2331e36b0449ab01
Showing with 1 addition and 1 deletion.
  1. +1 −1 t/08-performance/99-misc.t
@@ -33,6 +33,6 @@ plan 4 - $skip;
unless $skip { # https://github.com/rakudo/rakudo/issues/1740
my $t-plain = { (^∞).grep(*.is-prime)[1000]; now - ENTER now }();
my $t-hyper = { (^∞).hyper.grep(*.is-prime)[1000]; now - ENTER now }();
cmp-ok $t-hyper, '', $t-plain*2,
cmp-ok $t-hyper, '', $t-plain*5,
'hypered .grep .is-prime is not hugely slower than plain grep';
}

0 comments on commit bd29d3f

Please sign in to comment.
You can’t perform that action at this time.