Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/112.0.0.0 Safari/537.36
Chrome 112
Windows
Desktop
one year ago
Test name Executions per second
class 485011.2 Ops/sec
function constructor 486069.1 Ops/sec
object literal 432394.5 Ops/sec
object literal & sum.call 67230.1 Ops/sec
__proto__ 13246.2 Ops/sec
Object.create 5250.0 Ops/sec
Object.setPrototypeOf 2850.3 Ops/sec
Script Preparation code:
Tests:
  • class

  • function constructor

  • object literal

  • object literal & sum.call

  • __proto__

  • Object.create

  • Object.setPrototypeOf


;