8000 Issue #16250: Window Range Performance by hawkfish · Pull Request #16320 · duckdb/duckdb · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Issue #16250: Window Range Performance #16320

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 21, 2025
Merged

Conversation

hawkfish
Copy link
Contributor
  • Use <= for previous start checks now that they are properly vectorised.
  • This reduces the benchmark time by 5x to 3.858s.

* Use <= for previous start checks now that they are properly vectorised.
* This reduces the benchmark time by 5x to 3.858s.
Copy link
Contributor
@lnkuiper lnkuiper left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR! I think it's all good, although I'm not sure if I follow how a 1-line change makes a benchmark 5x faster. Care to explain?

I don't think the regression failure is related, that benchmark query shouldn't have anything to do with the window operator, although we might want to re-run CI just to be sure.

@hawkfish
Copy link
Contributor Author
hawkfish commented Feb 20, 2025

Thanks for the PR! I think it's all good, although I'm not sure if I follow how a 1-line change makes a benchmark 5x faster. Care to explain?

@lnkuiper I may have made a mistake on which query I looked at, but from stepping through the code, we were in a situation where the previous bound got reused a lot when it was the first value in the partition: there are only 83 dates for ~10MR, and if you go back a year, you often end up at the start of the partition. The check specifically excluded this situation for no good reason (we know the previous bound is valid) and since it came up a lot in this data set we ended up searching instead of reusing the value.

@Mytherin Mytherin merged commit 134e0ae into duckdb:main Feb 21, 2025
48 of 49 checks passed
@Mytherin
Copy link
Collaborator

Thanks!

@hawkfish hawkfish deleted the range-le branch February 21, 2025 21:40
Antonov548 added a commit to Antonov548/duckdb-r that referenced this pull request Mar 4, 2025
krlmlr pushed a commit to duckdb/duckdb-r that referenced this pull request Mar 5, 2025
krlmlr added a commit to duckdb/duckdb-r that referenced this pull request May 15, 2025
krlmlr added a commit to duckdb/duckdb-r that referenced this pull request May 15, 2025
krlmlr added a commit to duckdb/duckdb-r that referenced this pull request May 17, 2025
krlmlr added a commit to duckdb/duckdb-r that referenced this pull request May 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0