Repository navigation
Commit 66e450c
authored
### Rationale for this change
Asd missing support for `float16` in hash kernels.
### What changes are included in this PR?
Support `float16` in hash kernels: `dictionary_encode`, `unique`, `value_counts`.
### Are these changes tested?
Added `UniqueHalfFloat`, `ValueCountsHalfFloat` and `DictEncodeHalfFloat` to `vector_hash_test.cc`, following the conventions in that file. Coverage includes nulls, repeated values, a no-nulls case, and sliced input. `float16` is not in `PrimitiveTypes()`, so it isn't picked up by the existing `TestHashKernelPrimitive` typed suite and needs its own `TEST_F` cases. `NaN`/`-0.0` cases are deliberately not tested, matching the existing float32/float64 tests.
Built and ran locally:
```
cmake -S cpp -B /tmp/arrow-build -DCMAKE_BUILD_TYPE=Debug -DARROW_COMPUTE=ON \
-DARROW_BUILD_TESTS=ON -DARROW_DEPENDENCY_SOURCE=BUNDLED -DARROW_SIMD_LEVEL=NONE
cmake --build /tmp/arrow-build --target arrow-compute-vector-test -j8
```
- The 3 new float16 tests pass.
- All 110 `*HashKernel*` tests pass.
- The full `arrow-compute-vector-test` binary passes: **1135 tests from 150 test suites**, no regressions.
### Are there any user-facing changes?
No (except for filling out the feature gap).
* GitHub Issue: #50512
Authored-by: Fredrik Fornwall <[email protected]>
Signed-off-by: Antoine Pitrou <[email protected]>
1 parent 68610e4 commit 66e450c
2 files changed
Lines changed: 10 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
550 | 550 | | |
551 | 551 | | |
552 | 552 | | |
| 553 | + | |
553 | 554 | | |
554 | 555 | | |
555 | 556 | | |
| |||
700 | 701 | | |
701 | 702 | | |
702 | 703 | | |
| 704 | + | |
| 705 | + | |
| 706 | + | |
| 707 | + | |
| 708 | + | |
| 709 | + | |
| 710 | + | |
703 | 711 | | |
704 | 712 | | |
705 | 713 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
150 | 150 | | |
151 | 151 | | |
152 | 152 | | |
153 | | - | |
154 | | - | |
| 153 | + | |
| 154 | + | |
155 | 155 | | |
156 | 156 | | |
157 | 157 | | |
| |||
0 commit comments