Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:132.0) Gecko/20100101 Firefox/132.0
Firefox 132
Mac OS X 10.15
Desktop
one year ago
Benchmark.js
byteArrayToString
8K/s
String.fromCharCode.apply
6K/s
arr join
3K/s
String.fromCharCode
2K/s
bytesToBase64
498/s
View exact numbers
Test name Executions per second
byteArrayToString 8,185 Ops/sec
String.fromCharCode.apply 6,416 Ops/sec
arr join 2,879 Ops/sec
String.fromCharCode 1,806 Ops/sec
bytesToBase64 498 Ops/sec
Script Preparation code:
Tests: