Skip to content

Commit fe97ac7

Browse files
committed
Update benchmarks.
1 parent 5ee6e1c commit fe97ac7

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

benchmarks/AbstractBench.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,6 @@ abstract class AbstractBench
1111
*/
1212
public function getData()
1313
{
14-
return \range(1, 1000);
14+
return \range(1, 100);
1515
}
1616
}

benchmarks/DrupolPhpTreeBench.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,12 @@ public function initObject()
3030
* @Iterations(5)
3131
* @Warmup(10)
3232
*/
33-
public function benchHash()
33+
public function benchTreeAdd()
3434
{
35-
$this->tree = new ValueNode();
35+
$this->tree = new ValueNode('root', 2);
3636

3737
foreach ($this->getData() as $value) {
38-
$this->tree->add(new ValueNode($value));
38+
$this->tree->add(new ValueNode($value, 2));
3939
}
4040
}
4141
}

0 commit comments

Comments
 (0)