X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=benchmarks%2Fworker-selection%2Fround-robin.mjs;fp=benchmarks%2Fworker-selection%2Fround-robin.mjs;h=64ea78da719cf0ef0607bfa4f8e27cb0e4977388;hb=ed20267eeb81ac0fb4a3abb5d1bde586080c2671;hp=d39fd699f58016e69052f52dbcf87e6945c5f07b;hpb=b120cd46f439c18157b42adf0ef9faeafe971b4d;p=poolifier.git diff --git a/benchmarks/worker-selection/round-robin.mjs b/benchmarks/worker-selection/round-robin.mjs index d39fd699..64ea78da 100644 --- 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 + * @returns */ function generateWorkersArray (numberOfWorkers) { return [...Array(numberOfWorkers).keys()] @@ -13,7 +14,7 @@ const workers = generateWorkersArray(60) let nextWorkerIndex /** - * + * @returns */ function roundRobinTernaryOffByOne () { nextWorkerIndex = @@ -22,7 +23,7 @@ function roundRobinTernaryOffByOne () { } /** - * + * @returns */ function roundRobinTernaryWithNegation () { nextWorkerIndex = @@ -33,7 +34,7 @@ function roundRobinTernaryWithNegation () { } /** - * + * @returns */ function roundRobinTernaryWithPreChoosing () { const chosenWorker = workers[nextWorkerIndex] @@ -43,7 +44,7 @@ function roundRobinTernaryWithPreChoosing () { } /** - * + * @returns */ function roundRobinIncrementModulo () { const chosenWorker = workers[nextWorkerIndex]