alexanderbianchi commented on PR #12039: URL: https://github.com/apache/arrow-rs/pull/12039#issuecomment-6866322307
I adapted DataFusion's `shared_dictionary_views` take/concat regression from apache/datafusion#23564 and found two additional shared-buffer cases: - Eight references to a 63,000-byte dictionary produce a 504,000-byte compacted data buffer, because ranges are grouped by buffer-list index rather than the referenced byte region. - 5,000 references to a roughly 1 MiB dictionary disable compaction through the 4 GiB guard, even when all selected rows reference one 63-byte value. The regression checks the guard before writing, so it does not allocate/serialize multiple GB. I put a small follow-up against your branch at https://github.com/adriangb/arrow-rs/pull/4 rather than opening a competing Apache PR. It canonicalizes repeated `(pointer, length)` buffer entries before merging ranges and uses distinct-buffer sizes for the guard. The tests cover Utf8View, BinaryView, nested maps, and all three compression modes, with value roundtrips and byte assertions. Both new regressions fail on `91329d7f` and pass with the follow-up; the full arrow-ipc suite also passes. AI-assisted, with local red/green validation. The commit can also be cherry-picked: `7359bafc1`. -- 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]
