Repository navigation
Conversation
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
Add the explicit
--lower-bit-permutationoption for scalar 32/64-bit PEXT/PDEP lowering with--to-rosetta. Default Rosetta output keeps the native instructions. Register masks and eligible RSP-relative masks are lowered; unsupported memory forms remain native. Both executable and bundled-module conversion receive the option.The older-host motivation has published probe evidence: kiaramaldonado's merged #7953 includes raw
PDEP Illegal instruction: 4andPEXT Illegal instruction: 4results from an Apple M2 running macOS 14.8.9, using isolated x86-64 processes built with Apple clang 15.0.0. Modern M1/M5 reports execute the instructions, which is why this remains opt-in. This is an independent measurement, not a new run on my Windows host; no converted title or performance gain is claimed.Resolved current-main conflicts while preserving
--omit-unavailable-dependenciesalongside the lowering option. Merge-order dependencies: boykopovar#11525 first, as requested by its author, and boykopovar#15032 before this PR to avoid competing edits to guest-builder option propagation. This PR waits behind both. On the later rebase, retain boykopovar#11525's data-range argument toConvert, boykopovar#15032's function-symbol-root option, and this PR's lowering option; these implement separate behavior.Tested
Head
72bd72605c, merged with main04a9eb4fa2. Windows x64, MinGW GCC 13.2.0, Python 3.13.15, Ninja Release,ANYPS5_RELINKER_ONLY=ON,BUILD_TESTING=ON.andn_lowering,masked_store_lowering,relinker_conversion,amd64_only_windows,bit_permutation_lowering,cli_args,amd64_only_converter.guest_intel_trampolines,to_rosetta,bit_permutation_conversionwere blocked when Windows Application Control refused the compiled relinker (WinError 4551). Hosted CI subsequently passed on this head: Linux, Windows (686/686 tests), macOS arm64, macOS x86-64 and Linux ASan. Build run. No Windows security setting was changed.upstream/mainandgit diff --check upstream/main...HEADpassed. The required comparison against the fork's outdatedorigin/mainalso ran and reports six unrelated upstream commit-subject errors plus existing debt-length warnings.Independent earlier execution coverage: rooklz's review ran 65,856 generated-stub cases under Rosetta on an M5 with macOS 26.2 and killed 25 mutants. That review predates this integration update. No local Mac/Rosetta run, old-M2 retest, retail-title test or full product build.
Independent update on this exact head: TechLevelZero's AMD run merged
72bd726onto main5b1d381and reports 1,076 passed, seven skipped and four failures already present or unstable on main, with no new Vulkan validation IDs. Host: AMD Radeon RX 6300, Mesa 25.2.8, Ubuntu 26.04.1. This is contributor-reported coverage, not a local run.Review audit on 2026-11-05, exact head
72bd72605cd2760a3fbf0df015e84d096c8d6c4b: all four hosted relinker configurations (Linux, Windows, macOS arm64 and macOS x86-64), relinker ASan, eligibility, conventions and labels have successful completed checks; full product jobs were skipped by workflow policy. The published older-host evidence and the Usage-column correction are present in this head. The requested review changes are ready for reassessment.Current overlap boykopovar#15032 is option plumbing in
CliArgs.cpp,GuestImage.hpp,GuestModuleBuilder.cppandConversion.cpp; it implements function-symbol roots, not PEXT/PDEP. Its merge order is recorded on the checklist. Manually inspected the newly listed base-conflicting boykopovar#6149 (module-args test source), boykopovar#13486 (zero finalizers/stub-window safety), boykopovar#15245 (executable exports), boykopovar#14001 (program-header-table bounds) and boykopovar#15651 (section links/entry sizes); these do not implement this lowering or TLS image comparison. Older manual checks remain historical evidence, not a claim that base-conflicting PRs merge cleanly.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)