jsPerf.app is an online JavaScript performance benchmark test runner & jsperf.com mirror. It is a complete rewrite in homage to the once excellent jsperf.com now with hopefully a more modern & maintainable codebase.
jsperf.com URLs are mirrored at the same path, e.g:
https://jsperf.com/negative-modulo/2
Can be accessed at:
https://jsperf.app/negative-modulo/2
const baseArray = [[0, 30], [1, 46], [2, 61], [3, 23], [4, 49], [5, 23], [6, 35], [7, 57], [8, 98], [9, 77], [10, 36], [11, 88], [12, 16], [13, 86], [14, 62], [15, 74], [16, 52], [17, 66], [18, 82], [19, 55], [20, 39], [21, 5], [22, 49], [23, 49], [24, 27], [25, 17], [26, 33], [27, 34], [28, 94], [29, 91], [30, 71], [31, 68], [32, 96], [33, 34], [34, 24], [35, 81], [36, 87], [37, 100], [38, 23], [39, 55], [40, 69], [41, 13], [42, 52], [43, 66], [44, 80], [45, 18], [46, 19], [47, 28], [48, 54], [49, 21], [50, 77], [51, 61], [52, 23], [53, 34], [54, 29], [55, 9], [56, 93], [57, 71], [58, 61], [59, 38], [60, 65], [61, 81], [62, 31], [63, 45], [64, 38], [65, 27], [66, 45], [67, 97], [68, 60], [69, 78], [70, 15], [71, 1], [72, 41], [73, 69], [74, 30], [75, 25], [76, 41], [77, 43], [78, 39], [79, 35], [80, 7], [81, 75], [82, 77], [83, 90], [84, 15], [85, 84], [86, 91], [87, 61], [88, 58], [89, 77], [90, 26], [91, 55], [92, 59], [93, 1], [94, 37], [95, 31], [96, 7], [97, 80], [98, 47], [99, 39]];
const testArray = baseArray.map(a => a[1]);
const testMap = new Map(baseArray);
const testObject = Object.fromEntries(baseArray);
Ready to run.
Test | Ops/sec | |
---|---|---|
Array |
| ready |
Map |
| ready |
Object |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.