repositories
/
poolifier.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
build(deps): bump poolifier
[poolifier.git]
/
benchmarks
/
worker-selection
/
round-robin.mjs
diff --git
a/benchmarks/worker-selection/round-robin.mjs
b/benchmarks/worker-selection/round-robin.mjs
index d39fd699f58016e69052f52dbcf87e6945c5f07b..64ea78da719cf0ef0607bfa4f8e27cb0e4977388 100644
(file)
--- a/
benchmarks/worker-selection/round-robin.mjs
+++ b/
benchmarks/worker-selection/round-robin.mjs
@@
-3,6
+3,7
@@
import { bench, group, run } from 'tatami-ng'
/**
*
* @param numberOfWorkers
/**
*
* @param numberOfWorkers
+ * @returns
*/
function generateWorkersArray (numberOfWorkers) {
return [...Array(numberOfWorkers).keys()]
*/
function generateWorkersArray (numberOfWorkers) {
return [...Array(numberOfWorkers).keys()]
@@
-13,7
+14,7
@@
const workers = generateWorkersArray(60)
let nextWorkerIndex
/**
let nextWorkerIndex
/**
- *
+ *
@returns
*/
function roundRobinTernaryOffByOne () {
nextWorkerIndex =
*/
function roundRobinTernaryOffByOne () {
nextWorkerIndex =
@@
-22,7
+23,7
@@
function roundRobinTernaryOffByOne () {
}
/**
}
/**
- *
+ *
@returns
*/
function roundRobinTernaryWithNegation () {
nextWorkerIndex =
*/
function roundRobinTernaryWithNegation () {
nextWorkerIndex =
@@
-33,7
+34,7
@@
function roundRobinTernaryWithNegation () {
}
/**
}
/**
- *
+ *
@returns
*/
function roundRobinTernaryWithPreChoosing () {
const chosenWorker = workers[nextWorkerIndex]
*/
function roundRobinTernaryWithPreChoosing () {
const chosenWorker = workers[nextWorkerIndex]
@@
-43,7
+44,7
@@
function roundRobinTernaryWithPreChoosing () {
}
/**
}
/**
- *
+ *
@returns
*/
function roundRobinIncrementModulo () {
const chosenWorker = workers[nextWorkerIndex]
*/
function roundRobinIncrementModulo () {
const chosenWorker = workers[nextWorkerIndex]