Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.116 Safari/537.36
Chrome 83
Windows
Desktop
3 years ago
Test name Executions per second
isWhitespaceRgx 51545.2 Ops/sec
isWhitespaceTrim 187654.0 Ops/sec
isWhitespaceRgxWEarlyExit 73803.1 Ops/sec
isWhitespaceTrimWEarlyExit 195245.1 Ops/sec
Verify Correctness 85952.6 Ops/sec
2:isWhitespaceTrimWEarlyExit 192652.3 Ops/sec
2:isWhitespaceRgxWEarlyExit 75453.7 Ops/sec
2:isWhitespaceTrim 188772.1 Ops/sec
2:isWhitespaceRgx 58610.3 Ops/sec
Script Preparation code:
Tests:
  • isWhitespaceRgx

  • isWhitespaceTrim

  • isWhitespaceRgxWEarlyExit

  • isWhitespaceTrimWEarlyExit

  • Verify Correctness

  • 2:isWhitespaceTrimWEarlyExit

  • 2:isWhitespaceRgxWEarlyExit

  • 2:isWhitespaceTrim

  • 2:isWhitespaceRgx