Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8224212

stringStream::as_string() is inefficient

    XMLWordPrintable

Details

    • Enhancement
    • Resolution: Won't Fix
    • P4
    • tbd
    • 13
    • hotspot
    • None

    Description

      stringStream::as_string() creates a copy of the backing memory inside the stream to return the printout to the caller.

      stringStream's internal buffer already contains the printed string and it is guaranteed to be zero terminated. So in a large number of places using this buffer directly instead of calling stringStream::as_string() is more efficient.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              stuefe Thomas Stuefe
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: