Script Preparation code:
Tests:
  • original

  • ES5 replace match map

  • match without replace

  • iteration with replace

  • looping with exec

  • non regex

Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    original
    ES5 replace match map
    match without replace
    iteration with replace
    looping with exec
    non regex

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: one month ago)
Mozilla/5.0 (iPhone; CPU iPhone OS 17_7 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.7 Mobile/15E148 Safari/604.1
Mobile Safari 17 on iOS 17.7
View result in a separate tab
Test name Executions per second
original 2049.3 Ops/sec
ES5 replace match map 1033.9 Ops/sec
match without replace 1881.7 Ops/sec
iteration with replace 983.1 Ops/sec
looping with exec 1110.2 Ops/sec
non regex 6823.9 Ops/sec


;