Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
new TypedArray() vs TypedArray.of()hgcvyuhj
(version: 1)
Comparing performance of:
new TypedArray vs TypedArray.of vs new TypedArray cached
Created:
6 months ago
by:
Guest
Jump to the latest result
HTML Preparation code:
<!--your preparation HTML code goes here-->
Script Preparation code:
let cache = [1,2,3,4,5]
Tests:
new TypedArray
new Uint16Array([1,2,3,4,5]) new Uint32Array([1,2,3,4,5]) new Float32Array([1,2,3,4,5])
TypedArray.of
Uint16Array.of(1,2,3,4,5) Uint32Array.of(1,2,3,4,5) Float32Array.of(1,2,3,4,5)
new TypedArray cached
new Uint16Array(cache) new Uint32Array(cache) new Float32Array(cache)
Rendered benchmark preparation results:
Suite status:
<idle, ready to run>
Run tests (3)
Previous results
Fork
Test case name
Result
new TypedArray
TypedArray.of
new TypedArray cached
Fastest:
N/A
Slowest:
N/A
Latest run results:
Run details:
(Test run date:
6 months ago
)
User agent:
Mozilla/5.0 (Linux; Android 10; K) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/141.0.0.0 Mobile Safari/537.36
Browser/OS:
Chrome Mobile 141 on Android
View result in a separate tab
Embed
Embed Benchmark Result
Test name
Executions per second
new TypedArray
1545613.8 Ops/sec
TypedArray.of
2108688.5 Ops/sec
new TypedArray cached
1556481.1 Ops/sec
Related benchmarks:
Array vs TypedArray write performance
TypedArray performance
number vs float32array vs Uint32Array test 2
Array vs TypedArray write performance %%%%%%%%%%%%
Array vs TypedArray write performance ttttttt
Array vs TypedArray vs f32 write performance
Create Float32Array via unpacking or concat?
Array vs TypedArray write performance (Int32Array)
Array vs TypedArray write performance (Float64Array)
Comments
Confirm delete:
Do you really want to delete benchmark?