Skip to content

Allow n<=1 in bit_reversal_permutation#565

Merged
asn-d6 merged 2 commits intoethereum:mainfrom
jtraglia:allow-fepc-1
May 9, 2025
Merged

Allow n<=1 in bit_reversal_permutation#565
asn-d6 merged 2 commits intoethereum:mainfrom
jtraglia:allow-fepc-1

Conversation

@jtraglia
Copy link
Member

When testing FIELD_ELEMENTS_PER_CELL=1, I got a C_KZG_BADARGS from bit_reversal_permutation because we treated 1 as an invalid length. We just hadn't considered this being valid, but it is. For 0 and 1, we can just return without doing anything. This function is only used with controlled constants, so it shouldn't really affect anything.

Copy link
Contributor

@asn-d6 asn-d6 left a comment

Choose a reason for hiding this comment

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

LGTM! Thanks!

@asn-d6 asn-d6 merged commit 76203a3 into ethereum:main May 9, 2025
43 checks passed
@jtraglia jtraglia deleted the allow-fepc-1 branch May 9, 2025 15:37
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.

3 participants