HTML Preparation code:
Tests:
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    getElementById
    querySelector(ID)
    querySelectorAll(ID)
    exposed global object
    exposed under the window object

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 5 months ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:147.0) Gecko/20100101 Firefox/147.0
Firefox 147 on Windows
View result in a separate tab
getElementById
5.2M/s
querySelector(ID)
3.6M/s
exposed under the window object
2.1M/s
querySelectorAll(ID)
1.7M/s
exposed global object
1.7M/s
View exact numbers
Test name Executions per second
getElementById 5,162,162 Ops/sec
querySelector(ID) 3,586,183 Ops/sec
exposed under the window object 2,126,108 Ops/sec
querySelectorAll(ID) 1,740,024 Ops/sec
exposed global object 1,669,356 Ops/sec