Repository navigation
Add targeted address, padding and local-width repairs - #136
Merged
Merged
Conversation
RetroGameDeveloper
pushed a commit
that referenced
this pull request
Oct 31, 2026
* Visual C++ 2017 (PC) compiler pack, run through wine on Linux and macOS The msvc2017 pack: Visual C++ 2017's 14.16 toolset (cl 19.16.27027.1) and the Windows 10 SDK 10.0.17763, pinned by sha256. Two compilers, selectable in Settings and by try_compiler: MSVC/14.16 (32-bit) and MSVC/14.16-x64. wibo can't run them, so on Linux and macOS they run through wine (wine.py), which the user manually installs; the older compiler packs stay on wibo. Games built with 2017 are still refused at import (subject of the next PR). * The Windows 10 SDK is now a toolchain of its own; changed installs are offered again The msvc2017 pack kept the Windows 10 SDK's headers inside each of its version folders, so the SDK was on disk twice (14.16 and 14.16-x64, about 130 MB each), and every future pack created that uses that SDK (2015, 2019) would have downloaded and stored it again. The SDK is now its own toolchain, winsdk-10.0.17763, which a pack names in `headers`: installed first, once, and each version folder gets an includes.txt saying where it is. The build searches it after the compiler's own Include, so Visual C++'s sal.h and concurrencysal.h still win as before; compiled code and data are identical to the merged layout's. The pack goes from 350 MB to 220 MB on disk. Nothing compared an install with toolchains.toml, so a changed entry left existing installs as they were, silently (here: a 2017 pack without its SDK folder). An install now records a fingerprint of its entry (parts, hashes, where each goes, requires); when the entry changes, the install counts as not installed, Compilers & tools says it changed and offers to install it again, and the archives already downloaded are reused. Installs made before fingerprints are judged by the archives their manifest records, and are given the fingerprint when they still match, so updating decompdecomp reinstalls nothing that didn't change (tested for every toolchain in the registry). Multiple tools needing the same toolchain would download simultaneously causing the destination to be corrupt. If multiple threads need the same toolchain, it is now installed one at a time. * The Mac wine lookup test skips on Windows, which doesn't need wine * search Homebrew, MacPorts, Gcenx paths for wine * The wine lookup's comment says where each install puts wine * Review fixes: the wine prefix is required, manifests are written atomically, each pack names itself - compile.py refuses --wine without --wine-prefix (it would have used ~/.wine) - installed() and install() write the manifest to a file beside it and move it over (os.replace) - wine.problem() names the pack that needs wine, not always Visual C++ 2017 - wineboot runs under limits.capped(), as every heavy tool - a 2012-2015 game's message and the agents' x86 guide say what the packs have now * Wine is found when a 2017 file builds, and its server leaves by itself Review of #136. configure.py wrote wine's path and prefix into build.ninja, so a project configured before the pack or wine was installed couldn't build a file switched to 14.16 (ninja configures again with the project's own arguments, which had none), and tool_args gave --wine to projects whose older configure.py refuses it. Now configure.py only marks a 14.x file for wine; tools/compile.py finds wine and the app's prefix when the file builds, in DECOMPNET_WINE and DECOMPNET_WINE_PREFIX, which the app's build steps get from the console (Console.build_env, set in ForkProject.run). tool_args has nothing about wine, and starts nothing. - wineserver -p600: the server leaves ten minutes after its last compile, however the app ended, and at once when the app quits (wine.stop) - a prefix that fails fails the install with wineboot's reason, not a later "install wine" - DECOMPNET_WINE_PREFIX also names a scratch prefix: the PC tests use one and stop its server * Rules and texts say where wine and Visual C++ 2017 come from Review of #136. AGENTS.md and docs/CONVENTIONS.md give wine, a system tool for the wine = true packs, as the one exception to pinned tools, with why. CONTRIBUTING says where to take a compiler the decomp community keeps no copy of (2015 and newer: decomp.me's newest x86 Visual C++ is 2005 SP1), and the install confirmation names each toolchain's own source instead of saying every one is kept by the community. * No wine server is started that nothing will use wine's idle countdown (wineserver -p600) only begins once a wine program has run and ended (measured with wine 9.0: a -p20 server nobody used was still up after 70 s; one a program used left 25 s after it ended). prepare() ended by starting a server, so every install left one running for good. Only the build starts it now (tools/compile.py, right before it runs cl.exe through it), and its test checks that prepare leaves none. * The idle time is compile.py's alone, and the PR's lines stay near 120 characters wine.py kept a copy of compile.py's SERVER_IDLE_SECONDS; since the app no longer starts the server itself, only the build uses it. compile.py keeps it, saying why it can't share one with the app (it's copied into each project and runs without decompdecomp). The lines this PR added over 120 characters are wrapped, the Compilers & tools card's template too (the same HTML for every card). Left as they are: a Markdown table row, and toolchains.toml's URLs, inline keep tables and one-line descriptions, as its other entries. * More formatting cleanup * The 2017 pack's id is msvc2015, the version that is to join it The packs are named after the first version they hold (msvc: 6.0-7.1, msvc2005: 2005-2010), and Visual C++ 2015 Update 3 is to join this one beside 2017, both run through wine. An install is filed under its pack's id, and a renamed id would leave every install behind, so it's chosen now, before the pack is released. What users read still says 2017 (its name, its card), until 2015 is in it. * VISUAL-CPP.md lists Visual C++ 2017, which this pack adds The builds table gets 2017 15.9's 32-bit and 64-bit compilers (msvc2015), the import's steps say they can be chosen per file though 2017 games aren't started yet, a paragraph says the pack runs through wine where the older ones run through wibo, and 2017 15.9 leaves the builds that would help next. * Final changes, another formatting touch up. --------- Co-authored-by: risner <8061434+risner@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
Add four bounded deterministic repair families to the shared draft-repair and
try_local_repairspipelines:Existing budgets, revision checks, durable miss caching and ordinary exact judges remain in force. Imported projects and ROM mode share these candidates. Volatile, escaping, ambiguous and unsupported cases are skipped; no compiler settings change automatically.
Evidence
Worked only on a private copy of an N64 checkpoint, with no paid helper sessions:
try_local_repairsand the normal compiler/link judge.try_local_repairstoo. All four new matches have automatic repair reproductions. Missing-frame growth is MIPS-only until other processors implement its reader; unhinted padding removal/shrinking remains shared.Validation
git diff --checkpassed.