Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:82.0) Gecko/20100101 Firefox/82.0
Firefox 82
Mac OS X 10.15
Desktop
4 years ago
Test name Executions per second
getElementById 8933825.0 Ops/sec
getElementsByTagName 4841693.0 Ops/sec
querySelector 5226788.0 Ops/sec
getElementsByClassName 4530564.0 Ops/sec
getElementsByName 5696858.5 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • getElementById

  • getElementsByTagName

  • querySelector

  • getElementsByClassName

  • getElementsByName