Skip to content

[GLUTEN-8227][VL] fix: Update sort elimination rules for Hash Aggregate#9473

Open
acvictor wants to merge 6 commits intoapache:mainfrom
acvictor:acvictor/sortRules
Open

[GLUTEN-8227][VL] fix: Update sort elimination rules for Hash Aggregate#9473
acvictor wants to merge 6 commits intoapache:mainfrom
acvictor:acvictor/sortRules

Conversation

@acvictor
Copy link
Contributor

@acvictor acvictor commented Apr 30, 2025

What changes were proposed in this pull request?

Update sort elimination rules for hash aggregate only when the base aggregate was a sort aggregate. Only if a sort aggregate is transformed into a hash aggregate, can we safely assume that the aggregation does not depend on input order

(Part of fix for: #8227)

How was this patch tested?

(Please explain how this patch was tested. E.g. unit tests, integration tests, manual tests)

@github-actions github-actions bot added CORE works for Gluten Core VELOX CLICKHOUSE labels Apr 30, 2025
@github-actions
Copy link

Thanks for opening a pull request!

Could you open an issue for this pull request on Github Issues?

https://github.com/apache/incubator-gluten/issues

Then could you also rename commit message and pull request title in the following format?

[GLUTEN-${ISSUES_ID}][COMPONENT]feat/fix: ${detailed message}

See also:

@github-actions
Copy link

Run Gluten Clickhouse CI on x86

8 similar comments
@github-actions
Copy link

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

github-actions bot commented May 1, 2025

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

github-actions bot commented May 1, 2025

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

github-actions bot commented May 1, 2025

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

github-actions bot commented May 1, 2025

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

github-actions bot commented May 2, 2025

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

github-actions bot commented May 2, 2025

Run Gluten Clickhouse CI on x86

@acvictor acvictor changed the title Update rules [GLUTEN-8227][VL] fix: Update sort elimination rules for Hash Aggregate May 2, 2025
@github-actions
Copy link

github-actions bot commented May 2, 2025

#8227

@acvictor
Copy link
Contributor Author

acvictor commented May 5, 2025

@zhztheplayer @NEUpanning can you please help review this PR?

@acvictor
Copy link
Contributor Author

acvictor commented May 8, 2025

@ulysses-you can you please take a look at this PR?

@zhztheplayer
Copy link
Member

Compared to having this flag, can we just add a new operator for offloaded sort aggregation?

@acvictor
Copy link
Contributor Author

acvictor commented May 9, 2025

Compared to having this flag, can we just add a new operator for offloaded sort aggregation?

Thanks for the suggestion. I will try it out.

@acvictor acvictor closed this May 12, 2025
@acvictor acvictor force-pushed the acvictor/sortRules branch from 60698f9 to 9a71c14 Compare May 12, 2025 04:16
@acvictor acvictor reopened this May 12, 2025
@github-actions
Copy link

Run Gluten Clickhouse CI on x86

5 similar comments
@github-actions
Copy link

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

Run Gluten Clickhouse CI on x86

@FelixYBW
Copy link
Contributor

@zhztheplayer Any more comments?

@zhztheplayer
Copy link
Member

Apologize for the delay here! I'll revisit this shortly. Please feel free to jump in and review if anyone likes to.

@github-actions github-actions bot removed the stale stale label Oct 31, 2025
@github-actions
Copy link

This PR is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 10 days.

@github-actions github-actions bot added the stale stale label Dec 15, 2025
@zhztheplayer zhztheplayer removed the stale stale label Dec 15, 2025
@github-actions
Copy link

This PR is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 10 days.

@github-actions github-actions bot added the stale stale label Jan 30, 2026
@FelixYBW FelixYBW removed the stale stale label Jan 30, 2026
@github-actions
Copy link

Run Gluten Clickhouse CI on x86

1 similar comment
@github-actions
Copy link

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

github-actions bot commented Mar 3, 2026

Run Gluten Clickhouse CI on x86

1 similar comment
@github-actions
Copy link

github-actions bot commented Mar 3, 2026

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

github-actions bot commented Mar 3, 2026

Run Gluten Clickhouse CI on x86

@github-actions
Copy link

github-actions bot commented Mar 3, 2026

Run Gluten Clickhouse CI on x86

@acvictor acvictor requested a review from rui-mo March 6, 2026 05:10
@acvictor
Copy link
Contributor Author

@zhztheplayer @rui-mo can you please review this again? The main change was in response to the comment "how about directly adding SortAggregateExecTransformer? Then we can decide whether to remove the sort based on the operator class."

@github-actions
Copy link

Run Gluten Clickhouse CI on x86

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CORE works for Gluten Core VELOX

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants