Toggle navigation
MeasureThat
.net
Create a benchmark
Tools
Feedback
Feature Requests
FAQ
Register
Log In
Run results for:
Array vs Typed Array vs Buffer Typed Array
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/148.0.0.0 Safari/537.36
Browser:
Chrome 148
Operating system:
Windows
Device Platform:
Desktop
Date tested:
3 months ago
Benchmark engine:
Benchmark.js
Array
70/s
typed array from Buffer
69/s
typed Array no buffer
68/s
View exact numbers
Test name
Executions per second
✓
Array
70 Ops/sec
typed array from Buffer
69 Ops/sec
typed Array no buffer
68 Ops/sec
Script Preparation code:
var size = 450000; var buf = new ArrayBuffer(size); var normalArray = new Array(size); var arrayFromBuffer = new Uint8Array(buf); var arrayWithoutBuffer = new Uint8Array(size);
Tests:
Array
for (i =0; i< size; i++){ normalArray[i] = 0; }
typed array from Buffer
for (i =0; i< size; i++){ arrayFromBuffer[i] = 0; }
typed Array no buffer
for (i =0; i< size; i++){ arrayWithoutBuffer[i] = 0; }