Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.146 Whale/2.6.90.18 Safari/537.36
Chrome 76
Windows
Desktop
4 years ago
Test name Executions per second
getElementById 4319961.5 Ops/sec
getElementsByTagName 1561156.1 Ops/sec
querySelector 1712518.4 Ops/sec
getElementsByClassName 1606054.4 Ops/sec
getElementsByName 1809950.2 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • getElementById

  • getElementsByTagName

  • querySelector

  • getElementsByClassName

  • getElementsByName


;