Run details:
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36
Chrome 121
Linux
Desktop
8 months ago
Test name Executions per second
Intl.Collator.compare (ASCII-only strings) 289.0 Ops/sec
String.prototype.localeCompare (ASCII-only strings) 569.7 Ops/sec
Intl.Collator.compare 168.1 Ops/sec
String.prototype.localeCompare 177.5 Ops/sec
Script Preparation code:
Tests:
  • Intl.Collator.compare (ASCII-only strings)

  • String.prototype.localeCompare (ASCII-only strings)

  • Intl.Collator.compare

  • String.prototype.localeCompare