Skip to content
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

main: Replace MOD with bitwise AND #428

Merged
merged 1 commit into from
Jan 5, 2024
Merged

main: Replace MOD with bitwise AND #428

merged 1 commit into from
Jan 5, 2024

Conversation

crawfxrd
Copy link
Member

@crawfxrd crawfxrd commented Jan 3, 2024

This prevents moduint from being called for the superloop.

A bitwise AND is used instead of using the equivalent % 4 as an indication that modulo should not be used, as not using a power of 2 (which is optimized) will result in an expensive call to SDCC library functions.

This prevents `moduint` from being called for the superloop.

A bitwise AND is used instead of using the equivalent `% 4` as an
indication that modulo should not be used, as not using a power of 2
(which is optimized) will result in an expensive call to SDCC library
functions.

Signed-off-by: Tim Crawford <[email protected]>
@crawfxrd crawfxrd requested review from jackpot51 and a team January 3, 2024 01:17
Copy link
Member

@leviport leviport left a comment

Choose a reason for hiding this comment

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

serw13 seems the same after this change. Not seeing any issues.

@crawfxrd crawfxrd merged commit 4b86176 into master Jan 5, 2024
41 checks passed
@crawfxrd crawfxrd deleted the moduint branch January 5, 2024 22:04
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