Class ForUtil

java.lang.Object
org.apache.lucene.codecs.lucene90.ForUtil

final class ForUtil extends Object
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    (package private) static final int
     
    private static final int
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long
     
    private static final long[]
     
    private static final long[]
     
    private static final long[]
     
    private final long[]
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    private static void
    collapse16(long[] arr)
     
    private static void
    collapse32(long[] arr)
     
    private static void
    collapse8(long[] arr)
     
    (package private) void
    decode(int bitsPerValue, DataInput in, long[] longs)
    Decode 128 integers into longs.
    private static void
    decode1(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode10(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode11(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode12(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode13(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode14(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode15(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode16(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode17(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode18(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode19(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode2(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode20(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode21(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode22(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode23(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode24(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode3(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode4(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode5(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode6(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode7(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode8(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decode9(DataInput in, long[] tmp, long[] longs)
     
    private static void
    decodeSlow(int bitsPerValue, DataInput in, long[] tmp, long[] longs)
     
    (package private) void
    decodeTo32(int bitsPerValue, DataInput in, long[] longs)
    Decodes 128 integers into 64 longs such that each long contains two values, each represented with 32 bits.
    (package private) void
    encode(long[] longs, int bitsPerValue, DataOutput out)
    Encode 128 integers from longs into out.
    private static void
    expand16(long[] arr)
     
    private static void
    expand16To32(long[] arr)
     
    private static void
    expand32(long[] arr)
     
    private static void
    expand8(long[] arr)
     
    private static void
    expand8To32(long[] arr)
     
    private static long
    expandMask16(long mask16)
     
    private static long
    expandMask32(long mask32)
     
    private static long
    expandMask8(long mask8)
     
    private static long
    mask16(int bitsPerValue)
     
    private static long
    mask32(int bitsPerValue)
     
    private static long
    mask8(int bitsPerValue)
     
    (package private) int
    numBytes(int bitsPerValue)
    Number of bytes required to encode 128 integers of bitsPerValue bits per value.
    private static void
    shiftLongs(long[] a, int count, long[] b, int bi, int shift, long mask)
    The pattern that this shiftLongs method applies is recognized by the C2 compiler, which generates SIMD instructions for it in order to shift multiple longs at once.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • BLOCK_SIZE

      static final int BLOCK_SIZE
      See Also:
    • BLOCK_SIZE_LOG2

      private static final int BLOCK_SIZE_LOG2
      See Also:
    • tmp

      private final long[] tmp
    • MASKS8

      private static final long[] MASKS8
    • MASKS16

      private static final long[] MASKS16
    • MASKS32

      private static final long[] MASKS32
    • MASK8_1

      private static final long MASK8_1
    • MASK8_2

      private static final long MASK8_2
    • MASK8_3

      private static final long MASK8_3
    • MASK8_4

      private static final long MASK8_4
    • MASK8_5

      private static final long MASK8_5
    • MASK8_6

      private static final long MASK8_6
    • MASK8_7

      private static final long MASK8_7
    • MASK16_1

      private static final long MASK16_1
    • MASK16_2

      private static final long MASK16_2
    • MASK16_3

      private static final long MASK16_3
    • MASK16_4

      private static final long MASK16_4
    • MASK16_5

      private static final long MASK16_5
    • MASK16_6

      private static final long MASK16_6
    • MASK16_7

      private static final long MASK16_7
    • MASK16_9

      private static final long MASK16_9
    • MASK16_10

      private static final long MASK16_10
    • MASK16_11

      private static final long MASK16_11
    • MASK16_12

      private static final long MASK16_12
    • MASK16_13

      private static final long MASK16_13
    • MASK16_14

      private static final long MASK16_14
    • MASK16_15

      private static final long MASK16_15
    • MASK32_1

      private static final long MASK32_1
    • MASK32_2

      private static final long MASK32_2
    • MASK32_3

      private static final long MASK32_3
    • MASK32_4

      private static final long MASK32_4
    • MASK32_5

      private static final long MASK32_5
    • MASK32_6

      private static final long MASK32_6
    • MASK32_7

      private static final long MASK32_7
    • MASK32_8

      private static final long MASK32_8
    • MASK32_9

      private static final long MASK32_9
    • MASK32_10

      private static final long MASK32_10
    • MASK32_11

      private static final long MASK32_11
    • MASK32_12

      private static final long MASK32_12
    • MASK32_13

      private static final long MASK32_13
    • MASK32_14

      private static final long MASK32_14
    • MASK32_15

      private static final long MASK32_15
    • MASK32_17

      private static final long MASK32_17
    • MASK32_18

      private static final long MASK32_18
    • MASK32_19

      private static final long MASK32_19
    • MASK32_20

      private static final long MASK32_20
    • MASK32_21

      private static final long MASK32_21
    • MASK32_22

      private static final long MASK32_22
    • MASK32_23

      private static final long MASK32_23
    • MASK32_24

      private static final long MASK32_24
  • Constructor Details

    • ForUtil

      ForUtil()
  • Method Details

    • expandMask32

      private static long expandMask32(long mask32)
    • expandMask16

      private static long expandMask16(long mask16)
    • expandMask8

      private static long expandMask8(long mask8)
    • mask32

      private static long mask32(int bitsPerValue)
    • mask16

      private static long mask16(int bitsPerValue)
    • mask8

      private static long mask8(int bitsPerValue)
    • expand8

      private static void expand8(long[] arr)
    • expand8To32

      private static void expand8To32(long[] arr)
    • collapse8

      private static void collapse8(long[] arr)
    • expand16

      private static void expand16(long[] arr)
    • expand16To32

      private static void expand16To32(long[] arr)
    • collapse16

      private static void collapse16(long[] arr)
    • expand32

      private static void expand32(long[] arr)
    • collapse32

      private static void collapse32(long[] arr)
    • encode

      void encode(long[] longs, int bitsPerValue, DataOutput out) throws IOException
      Encode 128 integers from longs into out.
      Throws:
      IOException
    • numBytes

      int numBytes(int bitsPerValue)
      Number of bytes required to encode 128 integers of bitsPerValue bits per value.
    • decodeSlow

      private static void decodeSlow(int bitsPerValue, DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • shiftLongs

      private static void shiftLongs(long[] a, int count, long[] b, int bi, int shift, long mask)
      The pattern that this shiftLongs method applies is recognized by the C2 compiler, which generates SIMD instructions for it in order to shift multiple longs at once.
    • decode

      void decode(int bitsPerValue, DataInput in, long[] longs) throws IOException
      Decode 128 integers into longs.
      Throws:
      IOException
    • decodeTo32

      void decodeTo32(int bitsPerValue, DataInput in, long[] longs) throws IOException
      Decodes 128 integers into 64 longs such that each long contains two values, each represented with 32 bits. Values [0..63] are encoded in the high-order bits of longs [0..63], and values [64..127] are encoded in the low-order bits of longs [0..63]. This representation may allow subsequent operations to be performed on two values at a time.
      Throws:
      IOException
    • decode1

      private static void decode1(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode2

      private static void decode2(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode3

      private static void decode3(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode4

      private static void decode4(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode5

      private static void decode5(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode6

      private static void decode6(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode7

      private static void decode7(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode8

      private static void decode8(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode9

      private static void decode9(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode10

      private static void decode10(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode11

      private static void decode11(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode12

      private static void decode12(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode13

      private static void decode13(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode14

      private static void decode14(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode15

      private static void decode15(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode16

      private static void decode16(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode17

      private static void decode17(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode18

      private static void decode18(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode19

      private static void decode19(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode20

      private static void decode20(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode21

      private static void decode21(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode22

      private static void decode22(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode23

      private static void decode23(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException
    • decode24

      private static void decode24(DataInput in, long[] tmp, long[] longs) throws IOException
      Throws:
      IOException