Uploaded image for project: 'Commons Compress'
  1. Commons Compress
  2. COMPRESS-435

Use Switch Instead of InstanceOf For Snappy/LZ4

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Trivial
    • Resolution: Fixed
    • 1.15
    • 1.16
    • Compressors
    • None

    Description

      Instead of checking for instanceof in determining block types emitted from Snappy/LZ4, use Enumerator + Switch statement.

      My micro-benchmarks indicate about a 1% performance improvement over the current implementation.

      Attachments

        1. COMPRESS-435.1.patch
          6 kB
          David Mollitor

        Activity

          People

            Unassigned Unassigned
            belugabehr David Mollitor
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: