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

VideoCommon: remove unnecessary floor() #7456

Merged
merged 1 commit into from Oct 9, 2018

Conversation

3 participants
@Tilka
Member

Tilka commented Oct 5, 2018

floatindex is clamped to the range [0, 9]. For non-negative numbers floor() is equivalent to trunc(). Truncation happens implicitly when converting to uint, so the floor() is unnecessary.

@phire

This comment has been minimized.

Show comment
Hide comment
@phire

phire Oct 6, 2018

Member

This seems sane to me.

Member

phire commented Oct 6, 2018

This seems sane to me.

@stenzek

This comment has been minimized.

Show comment
Hide comment
@stenzek

stenzek Oct 6, 2018

Contributor

LGTM, it'd probably be safer to fix fifoci before merging, though.

Contributor

stenzek commented Oct 6, 2018

LGTM, it'd probably be safer to fix fifoci before merging, though.

VideoCommon: remove unnecessary floor()
floatindex is clamped to the range [0, 9]. For non-negative numbers
floor() is equivalent to trunc(). Truncation happens implicitly when
converting to uint, so the floor() is unnecessary.
@Tilka

This comment has been minimized.

Show comment
Hide comment
@Tilka

Tilka Oct 9, 2018

Member

fifoci seems happy

Member

Tilka commented Oct 9, 2018

fifoci seems happy

@Tilka Tilka merged commit bb6aff1 into dolphin-emu:master Oct 9, 2018

10 checks passed

default Very basic checks passed, handed off to Buildbot.
Details
lint Build succeeded on builder lint
Details
pr-android Build succeeded on builder pr-android
Details
pr-deb-dbg-x64 Build succeeded on builder pr-deb-dbg-x64
Details
pr-deb-x64 Build succeeded on builder pr-deb-x64
Details
pr-freebsd-x64 Build succeeded on builder pr-freebsd-x64
Details
pr-osx-x64 Build succeeded on builder pr-osx-x64
Details
pr-ubu-x64 Build succeeded on builder pr-ubu-x64
Details
pr-win-dbg-x64 Build succeeded on builder pr-win-dbg-x64
Details
pr-win-x64 Build succeeded on builder pr-win-x64
Details

@Tilka Tilka deleted the Tilka:drop_floor branch Oct 9, 2018

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