Run details:
Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:52.0) Gecko/20100101 Firefox/52.0 Cyberfox/52.9.1
Firefox 52
Windows 8.1
Desktop
4 years ago
Test name Executions per second
getElementById 6955414.0 Ops/sec
getElementsByTagName 2807481.5 Ops/sec
querySelector 2925827.0 Ops/sec
getElementsByClassName 2739535.0 Ops/sec
getElementsByName 3303806.2 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • getElementById

  • getElementsByTagName

  • querySelector

  • getElementsByClassName

  • getElementsByName


;