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

error param use in RadixSelector

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Trivial
    • Resolution: Won't Do
    • Affects Version/s: 8.8
    • Fix Version/s: None
    • Component/s: core/other
    • Labels:
    • Lucene Fields:
      Patch Available
    • Review Patch?:
      Yes

      Description

      there is error param used in org.apache.lucene.util.RadixSelector#select(int, int, int, int, int).

      what we expected in this method is:

      if the range becomes narrow or when the maximum level of recursion has been exceeded, then we get a fall-back selector(IntroSelector).

      so we should use the param l compare with level_threshold. NOT d.

      effect:  This does not affect the correctness of the program. but affect performance in some case. RadixSelector and IntroSelector are all in linear time. but this bug made bigger constatns.

       

      other evidence: 

      1. in comment. said maximum level of recursion has been exceeded. not the length of value.

      2. if d is right. the param f will never used in all method. It could be delete.

       

      Thanks for you read. I'm new of lucene, so reply me if I am wrong. or fix it.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              liupanfeng liupanfeng
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: