pitrou commented on pull request #6985:
URL: https://github.com/apache/arrow/pull/6985#issuecomment-630078764
Here are some benchmarks on my machine, with gcc 7.5:
* ARROW_SIMD_LEVEL=NONE:
```
BM_DefinitionLevelsToBitmapRepeatedAllMissing 965 ns 965 ns
2895940 bytes_per_second=1.97577G/s
BM_DefinitionLevelsToBitmapRepeatedAllPresent 1565 ns 1565 ns
1835474 bytes_per_second=1.21861G/s
BM_DefinitionLevelsToBitmapRepeatedMostPresent 1709 ns 1709 ns
1628131 bytes_per_second=1.11626G/s
```
* ARROW_SIMD_LEVEL=AVX2:
```
BM_DefinitionLevelsToBitmapRepeatedAllMissing 3726 ns 3726 ns
748789 bytes_per_second=524.229M/s
BM_DefinitionLevelsToBitmapRepeatedAllPresent 5781 ns 5780 ns
484016 bytes_per_second=337.895M/s
BM_DefinitionLevelsToBitmapRepeatedMostPresent 5776 ns 5775 ns
485316 bytes_per_second=338.183M/s
```
With clang 8.0:
* ARROW_SIMD_LEVEL=NONE:
```
BM_DefinitionLevelsToBitmapRepeatedAllMissing 935 ns 935 ns
3009389 bytes_per_second=2.04013G/s
BM_DefinitionLevelsToBitmapRepeatedAllPresent 1326 ns 1326 ns
2152178 bytes_per_second=1.43859G/s
BM_DefinitionLevelsToBitmapRepeatedMostPresent 1601 ns 1601 ns
1789999 bytes_per_second=1.19129G/s
```
* ARROW_SIMD_LEVEL=AVX2:
```
BM_DefinitionLevelsToBitmapRepeatedAllMissing 1126 ns 1126 ns
2483214 bytes_per_second=1.69443G/s
BM_DefinitionLevelsToBitmapRepeatedAllPresent 3044 ns 3043 ns
909419 bytes_per_second=641.808M/s
BM_DefinitionLevelsToBitmapRepeatedMostPresent 2873 ns 2872 ns
962839 bytes_per_second=679.975M/s
```
So the BMI2 instructions incur a large slowdown here (even catastrophic with
gcc).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]