Run details:
Mozilla/5.0 (X11; Linux x86_64; rv:75.0) Gecko/20100101 Firefox/75.0
Firefox 75
Linux
Desktop
4 years ago
Test name Executions per second
getElementById 4639777.0 Ops/sec
getElementsByTagName 2647290.2 Ops/sec
querySelector 2860719.0 Ops/sec
getElementsByClassName 2476658.0 Ops/sec
getElementsByName 3234145.8 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • getElementById

  • getElementsByTagName

  • querySelector

  • getElementsByClassName

  • getElementsByName