-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Add Xdelta support for softpatching #14706
Conversation
- Otherwise the static_assert calls can fail
- The patching itself isn't fully implemented yet
- Now checks max values instead of relying on autotools
- There may be undiscovered edge cases or bugs
- Otherwise the static_assert calls can fail
- The patching itself isn't fully implemented yet
- Now checks max values instead of relying on autotools
- There may be undiscovered edge cases or bugs
Whoops, I noticed that there are some compiler errors on Linux. (I've been developing this patch on Windows.) It has to do with xdelta's |
- C89 doesn't allow them
- Move them outside the XD3_USE_LARGEFILE64 block - Add more SIZE declarations - Make SIZEOF_UNSIGNED_LONG_LONG contingent on the presence of ULLONG_MAX
This pull request introduces 2 alerts when merging a9756fe into 2f7c298 - view on LGTM.com new alerts:
Heads-up: LGTM.com's PR analysis will be disabled on the 5th of December, and LGTM.com will be shut down ⏻ completely on the 16th of December 2022. Please enable GitHub code scanning, which uses the same CodeQL engine ⚙️ that powers LGTM.com. For more information, please check out our post on the GitHub blog. |
- Necessary for some patches
This pull request introduces 6 alerts when merging 62d81e5 into 2f7c298 - view on LGTM.com new alerts:
Heads-up: LGTM.com's PR analysis will be disabled on the 5th of December, and LGTM.com will be shut down ⏻ completely on the 16th of December 2022. Please enable GitHub code scanning, which uses the same CodeQL engine ⚙️ that powers LGTM.com. For more information, please check out our post on the GitHub blog. |
This pull request introduces 6 alerts when merging 594b48e into 2f7c298 - view on LGTM.com new alerts:
Heads-up: LGTM.com's PR analysis will be disabled on the 5th of December, and LGTM.com will be shut down ⏻ completely on the 16th of December 2022. Please enable GitHub code scanning, which uses the same CodeQL engine ⚙️ that powers LGTM.com. For more information, please check out our post on the GitHub blog. |
Personally, if there is no maximum limit, which i tend to agree with, i believe there should by a soft limit, based on a percentage of the computer physical memory (not 'virtual' memory). After all, even if the core is outdated, dolphin is a core, so the maximum size of a 'patched' file is 8gb or so. Unless this patching is done with temporary files, in which case i don't want to use it. |
This pull request introduces 6 alerts when merging dbb4af4 into 2f7c298 - view on LGTM.com new alerts:
Heads-up: LGTM.com's PR analysis will be disabled on the 5th of December, and LGTM.com will be shut down ⏻ completely on the 16th of December 2022. Please enable GitHub code scanning, which uses the same CodeQL engine ⚙️ that powers LGTM.com. For more information, please check out our post on the GitHub blog. |
- HAVE_XDELTA is on by default - HAVE_PATCH is still required for HAVE_XDELTA to be meaningful - Support is mostly contingent on the availability of LZMA - Anything modern should be okay - Legacy platforms (e.g. DOS) may need to have Xdelta support disabled - At least until some other solution can be found
This pull request introduces 6 alerts when merging 97efcc3 into 2f7c298 - view on LGTM.com new alerts:
Heads-up: LGTM.com's PR analysis will be disabled on the 5th of December, and LGTM.com will be shut down ⏻ completely on the 16th of December 2022. Please enable GitHub code scanning, which uses the same CodeQL engine ⚙️ that powers LGTM.com. For more information, please check out our post on the GitHub blog. |
- These come from looking at the failed builds on GitHub - These are guesses, and may turn out to be wrong
This pull request introduces 6 alerts when merging 0c04762 into 2f7c298 - view on LGTM.com new alerts:
Heads-up: LGTM.com's PR analysis will be disabled on the 5th of December, and LGTM.com will be shut down ⏻ completely on the 16th of December 2022. Please enable GitHub code scanning, which uses the same CodeQL engine ⚙️ that powers LGTM.com. For more information, please check out our post on the GitHub blog. |
Could someone please grant me approval (at least within this PR) to run workflows without having to await approval? There are a lot of environments I need to validate this patch against, and it's difficult to iterate locally. |
@i30817 Sorry, I missed your message over the @lgtm-com spam.
This seems sensible, but I'm not convinced that it would be the best use of my time right now. The cores that load games from ISOs (or other large disc image formats) don't support softpatching yet, so such an exercise would largely be academic. That mostly leaves Nintendo 64, DS, and Game Boy Advance games, which don't usually exceed 128MB (and that's pushing it). A device that can't spare that is unlikely to be able to run such games well anyway. On top of that, games for older/simpler platforms like the Genesis or Game Boy usually don't get patches in xdelta format (IPS, UPS, or BPS are more common). I'd be happy to revisit this once a few of the major disk-based cores that are known to run well on legacy/underpowered devices get softpatching support. But if the maintainers demand it now, I'll oblige.
Nope, it's all in-memory. The steps are as follows:
If there's not enough memory to allocate the patch (i.e. if |
- Whoops, looks like I need to call two cleanup functions - xd3_close_stream exists separately from xd3_free_stream
This pull request introduces 6 alerts when merging 3c57abd into 7b09cb2 - view on LGTM.com new alerts:
Heads-up: LGTM.com's PR analysis will be disabled on the 5th of December, and LGTM.com will be shut down ⏻ completely on the 16th of December 2022. Please enable GitHub code scanning, which uses the same CodeQL engine ⚙️ that powers LGTM.com. For more information, please check out our post on the GitHub blog. |
- GCC was complaining about #ifdefs within macro arguments being non-portable
- It's mostly using RetroArch's INLINE macro instead of the inline keyword
This reverts commit aaad220.
I keep stating this - it remains a huge issue that for first-time contributors or any other contributor outside the organization on GItlab, it remains impossible to run a CI lab (even on request by say me). This is a huge blindspot, huge issue, and it keeps screwing us up even despite the numerous Github action CI jobs we already have implemented, because it is just not possible to catch every single platform and toolchain out there. I really hope in the future our Gitlab CI can become more user friendly and just allow us to run a custom job on request when we need to check if a PR builds against our buildbot targets. That would be a ton better than finding out it doesn't compile, is non-salvageable, and then having to revert all these commits later on. |
it takes some effort on our end, but it seems like setting up a branch and merging the PR to that instead of directly to main/master does an okay job of letting us run the CI jobs for testing (like we're doing with HSM's PR) |
As I mentioned to @LibretroAdmin privately, I think act solves that problem pretty nicely. It lets you run workflows locally. Over the next few days I'll submit a PR that ensures the workflow files don't break in act; they're mostly fine, I just need to get them across the finish line. |
Is this still something in consideration, or was this basically axed after being reverted? |
|
Description
Adds support for the xdelta format to softpatching. Works the same as IPS, UPS, and BPS, in that xdelta patches are applied to ROMs with the same name (in supported emulators).
I've tested this patch with a Nintendo 64 ROM hack, but before it's merged I'd like to get some feedback on it to ensure I'm not missing any edge cases.