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

ARDecrypt: Resolve seedtable at compile-time #9175

Merged
merged 1 commit into from Oct 21, 2020

Conversation

lioncash
Copy link
Member

We can boot the formation of the table off to the compiler at compile-time, rather than building the table at run-time.

We can boot the formation of the table off to the compiler at
compile-time, rather than building the table at run-time.
Copy link
Member

@leoetlino leoetlino left a comment

Choose a reason for hiding this comment

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

LGTM

seeds[j] = tmp3;
j -= 2;
}
u32 tmp3 = seeds[i];
Copy link
Member

Choose a reason for hiding this comment

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

Possible followup PR: use std::swap to get rid of tmp3?

Copy link
Member Author

Choose a reason for hiding this comment

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

Unfortunately std::swap isn't constexpr in C++17, so this can't be done. This would be a candidate whenever we move to C++20 though.

@leoetlino leoetlino merged commit eb5e1e6 into dolphin-emu:master Oct 21, 2020
10 checks passed
@lioncash lioncash deleted the action branch October 21, 2020 13:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants