mirror of https://github.com/lukechilds/node.git
Browse Source
String#toLowerCase() is incredibly slow and was costing a 15-30% performance hit for Buffers less than 1KB. Now instead it'll attempt to find the correct encoding directly from the passed encoding, only then afterwards it'll lowercase. The optimization for not passing any encoding at all is still at the top of the method. At most this may add 10% performance hit for passing a mixed case encoding.v0.11.8-release
1 changed files with 28 additions and 22 deletions
Loading…
Reference in new issue