Re: [I] Sum up bit count with vector API [lucene]

2023-10-10 Thread via GitHub
gf2121 commented on issue #12639: URL: https://github.com/apache/lucene/issues/12639#issuecomment-1755527114 on AVX-512: ``` Benchmark (size) Mode Cnt Score Error Units BitcountBenchmark.bitCountNew 32 thrpt5 62.222 ± 0.034 ops/us

Re: [I] Sum up bit count with vector API [lucene]

2023-10-10 Thread via GitHub
rmuir commented on issue #12639: URL: https://github.com/apache/lucene/issues/12639#issuecomment-1755455998 @jpountz on aarch64 (128-bit simd) the difference is small: ``` Benchmark (size) Mode CntScore Error Units BitCountBenchmark.bitCountNew 32

Re: [I] Sum up bit count with vector API [lucene]

2023-10-10 Thread via GitHub
jpountz commented on issue #12639: URL: https://github.com/apache/lucene/issues/12639#issuecomment-1755404204 I'm also curious if we get different numbers on size=32 (2,048 bits). This is the most interesting number to me since it is the window size of `BooleanScorer`. Likewise `IndexedDISI

Re: [I] Sum up bit count with vector API [lucene]

2023-10-10 Thread via GitHub
rmuir commented on issue #12639: URL: https://github.com/apache/lucene/issues/12639#issuecomment-1755378013 The compiler messes it up on arm, too: ``` Benchmark (size) Mode Cnt Score Error Units BitCountBenchmark.bitCountNew1024 thrpt5 3.440 ± 0

Re: [I] Sum up bit count with vector API [lucene]

2023-10-10 Thread via GitHub
rmuir commented on issue #12639: URL: https://github.com/apache/lucene/issues/12639#issuecomment-1755366199 I see less of an improvement: ``` Benchmark (size) Mode Cnt Score Error Units BitCountBenchmark.bitCountNew 1024 thrpt5 2.24

Re: [I] Sum up bit count with vector API [lucene]

2023-10-09 Thread via GitHub
gf2121 commented on issue #12639: URL: https://github.com/apache/lucene/issues/12639#issuecomment-1753084518 The scalar impl in JDK21 looks better ``` Benchmark (size) Mode Cnt Score Error Units BitcountBenchmark.bitCountNew 1024 thrpt5

Re: [I] Sum up bit count with vector API [lucene]

2023-10-09 Thread via GitHub
rmuir commented on issue #12639: URL: https://github.com/apache/lucene/issues/12639#issuecomment-1753033439 This is confusing since IMO compiler should be doing this already? I remember seeing it relatively recently but you are testing with JDK20... https://bugs.openjdk.org/browse/JDK

Re: [I] Sum up bit count with vector API [lucene]

2023-10-09 Thread via GitHub
gf2121 commented on issue #12639: URL: https://github.com/apache/lucene/issues/12639#issuecomment-1752926917 > is it the number of longs or the number of bits? It is the number of longs. Here is the whole class: ``` @BenchmarkMode(Mode.Throughput) @OutputTimeUnit(TimeUnit.MICR

Re: [I] Sum up bit count with vector API [lucene]

2023-10-09 Thread via GitHub
jpountz commented on issue #12639: URL: https://github.com/apache/lucene/issues/12639#issuecomment-1752922284 This looks appealing. What is the `size` parameter in your micro benchmark, is it the number of longs or the number of bits? -- This is an automated message from the Apache Git Se

[I] Sum up bit count with vector API [lucene]

2023-10-09 Thread via GitHub
gf2121 opened a new issue, #12639: URL: https://github.com/apache/lucene/issues/12639 ### Description I played with vector API to sum up bit count. This pattern can be used in [bitset cardinality](https://github.com/apache/lucene/blob/dfff1e635805ffc61dd6029a8060e2635bfcbdb9/lucene/c