rusanoph opened a new issue, #27770: URL: https://github.com/apache/datafusion/issues/27770
### Is your feature request related to a problem or challenge? While independently benchmarking the hash join redesign in #27746, I observed that input row order can have a substantial impact on hash join performance, even when the input row multiset, key distributions, query results, and physical plans remain identical. Using an out-star self-join workload derived from the SNAP Enron graph (183,831 edges), I obtained the following results: | Input order | Baseline (`6a06058`) | PR #27746 (`2f6c665`) | |---|---:|---:| | Original dataset order | 120.73 ms | 75.51 ms | | Deterministically shuffled | 365.08 ms | 90.31 ms | The baseline exhibited approximately 3× sensitivity to input order, whereas the redesigned hash join showed approximately 1.2× sensitivity in this experiment. Both input orderings produced identical query results, verified against an independent correctness oracle. The existing hash join benchmarks cover several key distributions, selectivity levels, and duplicate-heavy workloads. A paired row-order benchmark could provide additional coverage for future performance changes. ### Describe the solution you'd like Add a small SQL benchmark consisting of two equivalent graph self-join workloads: - Original input row order. - Deterministically shuffled input row order. Both variants would use the same edge multiset, SQL query, and expected results. I propose integrating these cases into the existing SQL benchmark infrastructure, with reproducible input preparation and result validation. The scope would be limited to benchmark coverage, without changes to the hash join implementation. ### Describe alternatives you've considered - A synthetic dataset with controlled key distributions and row ordering, if preferable for benchmark infrastructure. - Keeping the benchmark external to DataFusion. - Adding a larger graph benchmark suite, which I think would be unnecessarily broad for this initial contribution. ### Additional context - Related hash join redesign: #27746 - Related graph benchmark discussion: #451 - [Reproducible benchmark results and artifacts](https://github.com/rusanoph/unchained-hash-join-research/tree/ab74b02eff94fd7164538bf54eb990a7e99ca6a8/datafusion/upstream-validation/pr-27746) I'd be happy to implement this benchmark. Before preparing a PR, I'd appreciate feedback on whether this coverage would be useful and whether a small SNAP-derived dataset or a synthetic equivalent would better fit the existing benchmark infrastructure. ### Willingness to contribute None -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
