Run details:
Mozilla/5.0 (X11; CrOS x86_64 12607.58.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.86 Safari/537.36
Chrome 79
Chrome OS 12607.58.0
Desktop
4 years ago
Test name Executions per second
getElementById 4599226.5 Ops/sec
getElementsByTagName 2212646.0 Ops/sec
querySelector 1927669.4 Ops/sec
getElementsByClassName 1636963.4 Ops/sec
getElementsByName 2372111.5 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • getElementById

  • getElementsByTagName

  • querySelector

  • getElementsByClassName

  • getElementsByName