Run details:
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/97.0.4692.99 Safari/537.36
Chrome 97
Linux
Desktop
2 years ago
Test name Executions per second
Split on space 3888574.8 Ops/sec
Regex replace and trim 3631729.8 Ops/sec
Regex replace without global 5752790.0 Ops/sec
Script Preparation code:
Tests:
  • Split on space

  • Regex replace and trim

  • Regex replace without global