Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-4871

Sorter API: better compress positions, offsets and payloads in SortingDocsAndPositionsEnum

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.3
    • Component/s: None
    • Labels:
      None
    • Lucene Fields:
      New

      Description

      SortingDocsAndPositionsEnum could easily save memory by using a Lucene40TCF-like compression method for positions, offsets and payloads:

      • delta-encode positions and startOffsets (with the previous end offset),
      • store the length of the tokens instead of their end offset (endOffset == startOffset + length),
      • use a single bit to say whether the token has a payload.

        Attachments

        1. LUCENE-4871.patch
          4 kB
          Adrien Grand

          Issue Links

            Activity

              People

              • Assignee:
                jpountz Adrien Grand
                Reporter:
                jpountz Adrien Grand
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: