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
var item = {"_id":"5850461c4ed903736e5b6ab0","active":true,"account_id":"58dasdasdsadsa5355fea99aa8","name":"Fake product name fake product title","sku":"3412312322232","upc":"3341234123123233","tags":[],"serial_numbers":[],"barcodes":[],"custom_fields":[],"supplies":[],"listings":[{"_id":"5850502e4ed903736e5d1138","variant_id":null,"item_id":"d6012b627c66d592c8121dde7ee3b5c7","store_id":"585030a114d72001d0e5b8d7"},{"_id":"58505bc24ed903736e5d4798","variant_id":null,"item_id":"d6012b627c66d592c8121dde7ee3b5c7","store_id":"5850471373ddda6a344c8b2c"},{"_id":"58b7d39f297b9e569bc7af5b","variant_id":null,"item_id":"d6012b627c66d592c8121dde7ee3b5c7","store_id":"58b590aeea11b611fa7619e8"}],"images":[],"last_updated":"2017-03-02T08:11:11.710Z","length":null,"width":null,"height":null,"fulfillment_sku":null,"notes":null,"unit":null,"cost":null,"wholesale":null,"retail":null,"image":null,"weight_unit":null,"weight":null,"dimensions_unit":null,"description":null};
var items = [];
var item_skus = [];
for (i=0;i<50000;i++) {
items.push(JSON.parse(JSON.stringify(item)));
item_skus.push(item.sku);
}
item_skus[25000] = 'validsku';
items[25000].sku = 'validsku';
var search_sku = 'validsku';
var globals = { items: items };
Ready to run.
Test | Ops/sec | |
---|---|---|
Find |
| ready |
Use items length |
| ready |
Search array, fetch by index |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.