Skip to content

.toLowerCase is slow #605

@dcharbonnier

Description

@dcharbonnier

According to this http://jsperf.com/regex-vs-tolowercase toLowerCase is slow.
My test consist on doing 1000 multi each containing 100 sadd (real use-case for me).
Replacing toLowerCase with regexp increase performance by 5%, removing possibility of uppercase (using === string with no uppercase alternative) increase performance by 10%. Is there any good reason for allowing different case for functions ? When people use redis most of the time performance is critical.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions