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

Improve performance of cheat searching & add input validation #7448

Merged
merged 1 commit into from May 26, 2019

Conversation

4 participants
@RolandMunsil
Copy link
Contributor

commented Oct 2, 2018

The previous implementation of cheat search would reconvert the input string for every single memory value. Now we do it once and construct a comparison lambda which we pass to the search code.

In addition, I also added input validation. So, for example, if you've selected Decimal input and you try to compare against "FF", it won't search and will instead let the user know they've entered an invalid value. Similar logic for if you enter "1.2" in a search for bytes. Before, it would just use 0 if it failed to convert the value.

@RolandMunsil

This comment has been minimized.

Copy link
Contributor Author

commented Oct 3, 2018

Oh yeah, also - would it be OK for me to reimplement the "compare to value at last search" feature from the old Wx cheat manager at some point? (where you can search for, say, values that have gotten bigger since the last cheat search)

@BhaaLseN

This comment has been minimized.

Copy link
Member

commented Oct 3, 2018

Sounds useful to me, so why not?

Remember that you can (and probably should!) squash your commits together at some point.

@RolandMunsil

This comment has been minimized.

Copy link
Contributor Author

commented Oct 3, 2018

Is that something I can do here on GitHub or do I need to squash the commits on my local copy of the repo (and then push to GitHub)?

@JosJuice

This comment has been minimized.

Copy link
Contributor

commented Oct 3, 2018

You will need to do it locally.

@RolandMunsil RolandMunsil force-pushed the RolandMunsil:improve-cheat-search branch from da89d4a to 58616f4 Oct 3, 2018

@RolandMunsil

This comment has been minimized.

Copy link
Contributor Author

commented Oct 4, 2018

Alright, commits have been squashed

@RolandMunsil

This comment has been minimized.

Copy link
Contributor Author

commented Jan 27, 2019

I thought my changes would trigger a notification, but maybe not? Just gonna comment in case it hasn't notified people - I addressed the issues.

CheatsManager: Improve performance of searching & add input validation
The previous implementation of cheat search would reconvert the input
string for every single memory value. Now we do it once and construct
a comparison lambda which we pass to the search code.

In addition, I also added input validation. So, for example, if you've
selected Decimal input and you try to compare against "FF",
it won't search and will instead let the user know they've entered an
invalid value. Similar logic for if you enter "1.2" in a search for
bytes. Before, it would just use 0 if it failed to convert the value.

@leoetlino leoetlino force-pushed the RolandMunsil:improve-cheat-search branch from e75eda5 to 4ce7079 May 26, 2019

@leoetlino

This comment has been minimized.

Copy link
Member

commented May 26, 2019

Sorry for the delay. I had accidentally disabled email notifications so I completely missed your updates (and even your comment).

@leoetlino leoetlino merged commit f819ea6 into dolphin-emu:master May 26, 2019

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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.