Run details:
Mozilla/5.0 (Android 14; Mobile; rv:133.0) Gecko/133.0 Firefox/133.0
Firefox Mobile 133
Android
Mobile
7 days ago
Test name Executions per second
Traverse function 227953.5 Ops/sec
NodeIterator with filter function 40420.1 Ops/sec
NodeIterator with filter param 606924.9 Ops/sec
TreeWalker with filter function 93855.1 Ops/sec
TreeWalker with filter param 521887.2 Ops/sec
Script Preparation code:
Tests:
  • Traverse function

  • NodeIterator with filter function

  • NodeIterator with filter param

  • TreeWalker with filter function

  • TreeWalker with filter param