Run details:
Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.133 Safari/537.36 OPR/44.0.2510.1457
Opera 44
Windows 8.1
Desktop
6 years ago
Test name Executions per second
getElementById 2250204.0 Ops/sec
getElementsByTagName 732422.6 Ops/sec
querySelector 678170.2 Ops/sec
getElementsByClassName 728372.6 Ops/sec
getElementsByName 916734.2 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • getElementById

  • getElementsByTagName

  • querySelector

  • getElementsByClassName

  • getElementsByName


;