Uploaded image for project: 'Thrift'
  1. Thrift
  2. THRIFT-4293

Reuse Mutable TField on read

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 0.12.0
    • None
    • Patch Available
    • Patch

    Description

      The struct 'read' method allocates a TField object on each readFieldBegin(). This adds up to a lot of garbage. The patch creates and reuses a mutable TField object for reading.

      The patch modifies the TBinaryProtocol as an example, but the other protocols should probably be optimized as well (including TProtocolDecorator).

      Attachments

        1. mutable_read.patch
          5 kB
          Mike Rettig

        Activity

          People

            Unassigned Unassigned
            mrettig Mike Rettig
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: