Skip to content

Conversation

@dennisYatunin
Copy link
Member

@dennisYatunin dennisYatunin commented Mar 12, 2025

This PR replaces the recursive unrolling currently done for iterators up to length 2 with hard-coded unrolling for iterators up to length 3. This seems to minimize compilation overhead across most test cases, and it is also the pattern used in Base to unroll the ntuple(f, ::Val{N}) function.

@dennisYatunin dennisYatunin force-pushed the dy/manual_unrolling branch 2 times, most recently from 63b563f to 5a077e1 Compare March 13, 2025 23:40
@dennisYatunin dennisYatunin changed the title Replace recursive unrolling with manual unrolling Replace recursive unrolling with hard-coded unrolling Mar 13, 2025
@dennisYatunin dennisYatunin force-pushed the dy/manual_unrolling branch 5 times, most recently from bf2399a to a7a61bb Compare March 14, 2025 19:02
@dennisYatunin
Copy link
Member Author

I'm also going to bump the version number, since this change represents a significant improvement in latency.

@dennisYatunin dennisYatunin merged commit 7373be9 into main Mar 18, 2025
12 checks passed
@dennisYatunin dennisYatunin deleted the dy/manual_unrolling branch March 18, 2025 21:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants