Avoid unnecessary string copies in NumberParser for double parsing

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Server Programmability
    • SP Prioritized List
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Previously seen in SERVER-78480, we have observed this in profiling JParse(json.cpp). Parsing doubles copies the entire string which can be arbitrarily long. Given that we already have a StringData in parseNumberFromStringHelper<double>(), we can use C++ istringstream double parsing routine in place of strtod().

              Assignee:
              Unassigned
              Reporter:
              Jess Balint
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

                Created:
                Updated: