Tests:
  • regex

    AخA
     
    "this is it".replace(/ /g, "+");
  • benchmark

     
    "this is it".replaceAll(" ", "+");
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    regex
    benchmark

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 2 years ago)
Mozilla/5.0 (X11; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/109.0
Firefox 109 on Linux
View result in a separate tab
Test name Executions per second
regex 10435667.0 Ops/sec
benchmark 14746466.0 Ops/sec