asubiotto opened a new pull request, #12154:
URL: https://github.com/apache/arrow-rs/pull/12154

   # Which issue does this PR close?
   
   - Closes #12153.
   
   # Rationale for this change
   
   The string matching kernels return an error for `RunEndEncoded` inputs, so 
callers have to decode before filtering.
   
   # What changes are included in this PR?
   
   `like`, `ilike`, `nlike`, `nilike`, `starts_with`, `ends_with`, `contains` 
and `eq_ignore_ascii_case` accept run-end encoded operands, including run-end 
encoded dictionaries. Value types are the same as for unencoded inputs, so 
binary values also work with `starts_with`, `ends_with` and `contains`.
   
   Run-end encoded operands are rewritten into encodings the kernels already 
support:
   
   - **Against a scalar**: match each run once and repeat the result across the 
run.
   - **Two arrays**: look up each row through a dictionary view of the runs, 
without copying values.
   
   Adds an `ree_like` benchmark group.
   
   # Are these changes tested?
   
   Yes. The existing string test macros also run each case on `RunArray`, and 
new tests cover slicing mid-run, nulls, dictionary values, run-end encoded 
patterns, empty inputs, type errors and binary values.
   
   Benchmarks for 65,536 rows:
   
   | Benchmark | phys=64 | phys=1024 | phys=32768 |
   |---|---|---|---|
   | `like_flat_scalar` | 335 µs | 326 µs | 330 µs |
   | `like_ree_scalar` | 0.86 µs | 9.4 µs | 257 µs |
   | `like_ree_dict_scalar` | 1.03 µs | 10.0 µs | 271 µs |
   | `like_ree_decoded_scalar` | 787 µs | 847 µs | 976 µs |
   | `like_ree_flat` | 871 µs | 887 µs | 1.21 ms |
   
   # Are there any significant user-facing changes?
   
   No. Run-end encoded inputs that previously returned an error are now 
supported.
   
   AI assistance was used for this PR.
   


-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to