Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:98.0) Gecko/20100101 Firefox/98.0
Firefox 98
Windows
Desktop
2 years ago
Test name Executions per second
ES6 property (get) 853462976.0 Ops/sec
Getter function 871506240.0 Ops/sec
Directly get 861964160.0 Ops/sec
ES6 property (set) 1170297216.0 Ops/sec
Setter function 1174914560.0 Ops/sec
Directly set 1108911488.0 Ops/sec
Script Preparation code:
Tests:
  • ES6 property (get)

  • Getter function

  • Directly get

  • ES6 property (set)

  • Setter function

  • Directly set