aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/IR/LegacyPassManager.cpp
AgeCommit message (Collapse)AuthorFilesLines
2025-07-14[llvm] Remove unused includes (NFC) (#148768)Kazu Hirata1-1/+0
These are identified by misc-include-cleaner. I've filtered out those that break builds. Also, I'm staying away from llvm-config.h, config.h, and Compiler.h, which likely cause platform- or compiler-specific build failures.
2025-07-04[IR] Use llvm::for_each (NFC) (#146989)Kazu Hirata1-4/+2
We can pass a range to llvm::for_each.
2025-06-11[DebugInfo][RemoveDIs] Remove scoped-dbg-format-setter (#143450)Jeremy Morse1-5/+0
This was a utility for flipping between intrinsic and debug record mode -- we don't need it any more. The "IsNewDbgInfoFormat" should be true everywhere.
2025-06-09[DebugInfo][RemoveDIs] Rip out the UseNewDbgInfoFormat flag (#143207)Jeremy Morse1-2/+1
Start removing debug intrinsics support -- starting with the flag that controls production of their replacement, debug records. This patch removes the command-line-flag and with it the ability to switch back to intrinsics. The module / function / block level "IsNewDbgInfoFormat" flags get hardcoded to true, I'll to incrementally remove things that depend on those flags.
2025-06-02[llvm] annotate interfaces in llvm/IR for DLL export (#141650)Andrew Rogers1-1/+2
## Purpose This patch is one in a series of code-mods that annotate LLVM’s public interface for export. This patch annotates the `llvm/IR`, `llvm/IRPrinter`, and `llvm/IRReader` libraries. These annotations currently have no meaningful impact on the LLVM build; however, they are a prerequisite to support an LLVM Windows DLL (shared library) build. ## Background This effort is tracked in #109483. Additional context is provided in [this discourse](https://discourse.llvm.org/t/psa-annotating-llvm-public-interface/85307), and documentation for `LLVM_ABI` and related annotations is found in the LLVM repo [here](https://github.com/llvm/llvm-project/blob/main/llvm/docs/InterfaceExportAnnotations.rst). The bulk of these changes were generated automatically using the [Interface Definition Scanner (IDS)](https://github.com/compnerd/ids) tool, followed formatting with `git clang-format`. The following manual adjustments were also applied after running IDS on Linux: - Add `#include "llvm/Support/Compiler.h"` to files where it was not auto-added by IDS due to no pre-existing block of include statements. - Add `LLVM_ABI_FRIEND` to friend member functions declared with `LLVM_ABI` - Add `LLVM_TEMPLATE_ABI` and `LLVM_EXPORT_TEMPLATE` to exported instantiated templates - Add `LLVM_ABI` to a subset of private class methods and fields that require export - Add `LLVM_ABI` to a small number of symbols that require export but are not declared in headers - Reorder `LLVM_ABI` with `[[deprecated]]` and `[[nodiscard]]` attributes. ## Validation Local builds and tests to validate cross-platform compatibility. This included llvm, clang, and lldb on the following configurations: - Windows with MSVC - Windows with Clang - Linux with GCC - Linux with Clang - Darwin with Clang
2025-03-20[llvm] Use *Set::insert_range (NFC) (#132325)Kazu Hirata1-1/+1
DenseSet, SmallPtrSet, SmallSet, SetVector, and StringSet recently gained C++23-style insert_range. This patch replaces: Dest.insert(Src.begin(), Src.end()); with: Dest.insert_range(Src); This patch does not touch custom begin like succ_begin for now.
2024-10-16[IR] Avoid repeated hash lookups (NFC) (#112469)Kazu Hirata1-5/+3
2024-08-07Revert "demangle function names in trace files (#87626)"Fangrui Song1-3/+1
This reverts commit 0fa20c55b58deb94090985a5c5ffda4d5ceb3cd1. Storing raw symbol names is generally preferred in profile files. Demangling might lose information. Language frontends might use demangling schemes not supported by LLVMDemangle (https://github.com/llvm/llvm-project/issues/45901#issuecomment-2008686663). In addition, calling `demangle` for each function has a significant performance overhead (#102222). I believe that even if we decide to provide a producer-side demangling, it would not be on by default. Pull Request: https://github.com/llvm/llvm-project/pull/102274
2024-08-02[LegacyPM] Drop analysis groups (#101670)Alexis Engelke1-37/+5
This improves the performance of recordAvailableAnalysis and freePass so that they don't need to call getPassInfo(), which acquires a lock on every call. The performance-wise interesting part is only in LegacyPassManager.cpp, everything else is just cleanup.
2024-07-10demangle function names in trace files (#87626)Trass3r1-1/+3
This improves consistency in the trace files as other entries are demangled too. Submitted by jamieschmeiser on behalf of trass3r @jamieschmeiser @An-DJ
2024-07-03[IR] Use range-based for loops (NFC) (#97575)Kazu Hirata1-3/+2
2024-04-04[RemoveDIs][NFC] Use ScopedDbgInfoFormatSetter in more places (#87380)Stephen Tozer1-6/+1
The class `ScopedDbgInfoFormatSetter` was added as a convenient way to temporarily change the debug info format of a function or module, as part of IR printing; since this process is repeated in a number of other places, this patch uses the format-setter class in those places as well.
2024-03-19[RemoveDIs][NFC] Rename DPValue -> DbgVariableRecord (#85216)Stephen Tozer1-2/+3
This is the major rename patch that prior patches have built towards. The DPValue class is being renamed to DbgVariableRecord, which reflects the updated terminology for the "final" implementation of the RemoveDI feature. This is a pure string substitution + clang-format patch. The only manual component of this patch was determining where to perform these string substitutions: `DPValue` and `DPV` are almost exclusively used for DbgRecords, *except* for: - llvm/lib/target, where 'DP' is used to mean double-precision, and so appears as part of .td files and in variable names. NB: There is a single existing use of `DPValue` here that refers to debug info, which I've manually updated. - llvm/tools/gold, where 'LDPV' is used as a prefix for symbol visibility enums. Outside of these places, I've applied several basic string substitutions, with the intent that they only affect DbgRecord-related identifiers; I've checked them as I went through to verify this, with reasonable confidence that there are no unintended changes that slipped through the cracks. The substitutions applied are all case-sensitive, and are applied in the order shown: ``` DPValue -> DbgVariableRecord DPVal -> DbgVarRec DPV -> DVR ``` Following the previous rename patches, it should be the case that there are no instances of any of these strings that are meant to refer to the general case of DbgRecords, or anything other than the DPValue class. The idea behind this patch is therefore that pure string substitution is correct in all cases as long as these assumptions hold.
2024-01-25Reapply 215b8f1e252, reverted in c3f7fb1421eJeremy Morse1-2/+4
Turns out I was using DbgMarker::getDbgValueRange rather than the helper utility in Instruction::getDbgValueRange, which checks for null-ness. Original commit message follows. [DebugInfo][RemoveDIs] Convert debug-info modes when loading bitcode (#78967) As part of eliminating debug-intrinsics in LLVM, we'll shortly be pushing the conversion from "old" dbg.value mode to "new" DPValue mode out from when the pass manager runs, to when modules are loaded. This patch adds that conversion process and some (temporary) options to llvm-lto{,2} to help test it. Specifically: now whenever we load a bitcode module, consider a flag of whether to "upgrade" it into the new debug-info mode, and if we're lazily materializing functions then do that lazily too. Doing this exposes an error in the IRLinker/materializer handling of DPValues, where we need to transfer the debug-info format flag correctly, and in ValueMapper we need to remap the Values that DPValues point at. I've added some test coverage in the modified tests; these will be exercised by our llvm-new-debug-iterators buildbot. This upgrading of debug-info won't be happening for the llvm18 release, instead we'll turn it on after the branch date, thenbe push the boundary of where "new" debug-info starts and ends down into the existing debug-info upgrade path over the course of the next release.
2024-01-25Revert "[DebugInfo][RemoveDIs] Convert debug-info modes when loading bitcode ↵Jeremy Morse1-4/+2
(#78967)" This reverts commit 215b8f1e252b4f30cf1b734faa370c0ac4b88659. Numerous builders exploded from this X_X, for example https://lab.llvm.org/buildbot/#/builders/46/builds/62657
2024-01-25[DebugInfo][RemoveDIs] Convert debug-info modes when loading bitcode (#78967)Jeremy Morse1-2/+4
As part of eliminating debug-intrinsics in LLVM, we'll shortly be pushing the conversion from "old" dbg.value mode to "new" DPValue mode out from when the pass manager runs, to when modules are loaded. This patch adds that conversion process and some (temporary) options to llvm-lto{,2} to help test it. Specifically: now whenever we load a bitcode module, consider a flag of whether to "upgrade" it into the new debug-info mode, and if we're lazily materializing functions then do that lazily too. Doing this exposes an error in the IRLinker/materializer handling of DPValues, where we need to transfer the debug-info format flag correctly, and in ValueMapper we need to remap the Values that DPValues point at. I've added some test coverage in the modified tests; these will be exercised by our llvm-new-debug-iterators buildbot. This upgrading of debug-info won't be happening for the llvm18 release, instead we'll turn it on after the branch date, thenbe push the boundary of where "new" debug-info starts and ends down into the existing debug-info upgrade path over the course of the next release.
2023-11-09[DebugInfo][RemoveDIs] Add conversion utilities for new-debug-info formatJeremy Morse1-0/+8
This patch plumbs the command line --experimental-debuginfo-iterators flag in to the pass managers, so that modules can be converted to the new format, passes run, then converted back to the old format. That allows developers to test-out the new debuginfo representation across some part of LLVM with no further work, and from the command line. It also installs flag-catchers at the various points that bitcode and textual IR can egress from a process, and temporarily convert the module to dbg.value format when doing so. No tests alas as it's designed to be transparent. Differential Revision: https://reviews.llvm.org/D154372
2023-04-13[LegacyPM] Reduce number of calls to getNameAlexis Engelke1-4/+6
Repeatedly calling getName adds some overhead, which can be easily avoided by querying the name just once per function. The improvements are rather small (~0.5% back-end time in a compile-time optimized setting), but also very easy to achieve. Note that getting the name should be entirely avoidable in the common case, but would require more substantial changes. Reviewed By: MaskRay Differential Revision: https://reviews.llvm.org/D148145
2023-04-12[LegacyPM] Call getPassName only when neededAlexis Engelke1-1/+4
Even when time tracing is disabled, getPassName is currently still called. This adds an avoidable virtual function call for each pass. Fetching the pass name only when required slightly improves compile-time (particularly when LLVM is built without LTO). Reviewed By: nikic, MaskRay Differential Revision: https://reviews.llvm.org/D148022
2022-03-17[LegacyPassManager] Move structural hashing into Pass classes. NFC.Jay Foad1-8/+4
Move structural hashing into virtual methods on Pass. This will allow MachineFunctionPass to override the method to add hashing of the MachineFunction. Differential Revision: https://reviews.llvm.org/D120123
2022-02-06[llvm] Use = default (NFC)Kazu Hirata1-1/+1
2022-02-02Add missing includes after LLVMCore header cleanupserge-sans-paille1-0/+5
- conditionally include header only used for expensive check - have Core.h always include llvm-c/ErrorHandling.h
2022-02-02Cleanup header dependencies in LLVMCoreserge-sans-paille1-6/+0
Based on the output of include-what-you-use. This is a big chunk of changes. It is very likely to break downstream code unless they took a lot of care in avoiding hidden ehader dependencies, something the LLVM codebase doesn't do that well :-/ I've tried to summarize the biggest change below: - llvm/include/llvm-c/Core.h: no longer includes llvm-c/ErrorHandling.h - llvm/IR/DIBuilder.h no longer includes llvm/IR/DebugInfo.h - llvm/IR/IRBuilder.h no longer includes llvm/IR/IntrinsicInst.h - llvm/IR/LLVMRemarkStreamer.h no longer includes llvm/Support/ToolOutputFile.h - llvm/IR/LegacyPassManager.h no longer include llvm/Pass.h - llvm/IR/Type.h no longer includes llvm/ADT/SmallPtrSet.h - llvm/IR/PassManager.h no longer includes llvm/Pass.h nor llvm/Support/Debug.h And the usual count of preprocessed lines: $ clang++ -E -Iinclude -I../llvm/include ../llvm/lib/IR/*.cpp -std=c++14 -fno-rtti -fno-exceptions | wc -l before: 6400831 after: 6189948 200k lines less to process is no that bad ;-) Discourse thread on the topic: https://llvm.discourse.group/t/include-what-you-use-include-cleanup Differential Revision: https://reviews.llvm.org/D118652
2022-01-07[llvm] Remove redundant member initialization (NFC)Kazu Hirata1-8/+6
Identified with readability-redundant-member-init.
2022-01-03Revert "[llvm] Remove redundant member initialization (NFC)"Kazu Hirata1-6/+8
This reverts commit fd4808887ee47f3ec8a030e9211169ef4fb094c3. This patch causes gcc to issue a lot of warnings like: warning: base class ‘class llvm::MCParsedAsmOperand’ should be explicitly initialized in the copy constructor [-Wextra]
2022-01-01[llvm] Remove redundant member initialization (NFC)Kazu Hirata1-8/+6
Identified with readability-redundant-member-init.
2021-12-09[llvm] Use range-based for loops (NFC)Kazu Hirata1-7/+5
2021-10-06[llvm] Replace report_fatal_error(std::string) uses with ↵Simon Pilgrim1-1/+1
report_fatal_error(Twine) As described on D111049, we're trying to remove the <string> dependency from error handling and replace uses of report_fatal_error(const std::string&) with the Twine() variant which can be forward declared.
2021-03-02[opt] Error if -debug-pass is specified alongside the new PMArthur Eubanks1-0/+2
Reviewed By: ychen Differential Revision: https://reviews.llvm.org/D97810
2021-02-27[IR] Use range-based for loops (NFC)Kazu Hirata1-7/+6
2021-02-25[PM] Show the pass argument in pre/post-pass IR dumpsNicolas Guillemot1-4/+8
This patch adds each pass' pass argument in the header for IR dumps. For example: Before: ``` *** IR Dump Before InstructionSelect *** ``` After: ``` *** IR Dump Before InstructionSelect (instruction-select) *** ``` The goal is to make it easier to know what argument to pass to command line options like `debug-only` or `run-pass` to further investigate a given pass.
2021-02-10Specify that some flags are legacy PM-specificArthur Eubanks1-9/+8
Reviewed By: asbirlea Differential Revision: https://reviews.llvm.org/D96100
2021-01-22[LegacyPM] Update InversedLastUser on the fly. NFC.Jay Foad1-11/+13
This speeds up setLastUser enough to give a 5% to 10% speed up on trivial invocations of opt and llc, as measured by: perf stat -r 100 opt -S -o /dev/null -O3 /dev/null perf stat -r 100 llc -march=amdgcn /dev/null -filetype null Don't dump last use information unless -debug-pass=Details to avoid printing lots of spam that will break some existing lit tests. Before this patch, dumping last use information was broken anyway, because it used InversedLastUser before it had been populated. Differential Revision: https://reviews.llvm.org/D92309
2021-01-20[PM] Avoid duplicates in the Used/Preserved/Required setsBjorn Pettersson1-6/+0
The pass analysis uses "sets" implemented using a SmallVector type to keep track of Used, Preserved, Required and RequiredTransitive passes. When having nested analyses we could end up with duplicates in those sets, as there was no checks to see if a pass already existed in the "set" before pushing to the vectors. This idea with this patch is to avoid such duplicates by avoiding pushing elements that already is contained when adding elements to those sets. To align with the above PMDataManager::collectRequiredAndUsedAnalyses is changed to skip adding both the Required and RequiredTransitive passes to its result vectors (since RequiredTransitive always is a subset of Required we ended up with duplicates when traversing both sets). Main goal with this is to avoid spending time verifying the same analysis mulitple times in PMDataManager::verifyPreservedAnalysis when iterating over the Preserved "set". It is assumed that removing duplicates from a "set" shouldn't have any other negative impact (I have not seen any problems so far). If this ends up causing problems one could do some uniqueness filtering of the vector being traversed in verifyPreservedAnalysis instead. Reviewed By: foad Differential Revision: https://reviews.llvm.org/D94416
2021-01-11[llvm] Use llvm::find_if (NFC)Kazu Hirata1-2/+1
2020-12-03[NewPM] Support --print-before/after in NPMArthur Eubanks1-75/+2
This changes --print-before/after to be a list of strings rather than legacy passes. (this also has the effect of not showing the entire list of passes in --help-hidden after --print-before/after, which IMO is great for making it less verbose). Currently PrintIRInstrumentation passes the class name rather than pass name to llvm::shouldPrintBeforePass(), meaning llvm::shouldPrintBeforePass() never functions as intended in the NPM. There is no easy way of converting class names to pass names outside of within an instance of PassBuilder. This adds a map of pass class names to their short names in PassRegistry.def within PassInstrumentationCallbacks. It is populated inside the constructor of PassBuilder, which takes a PassInstrumentationCallbacks. Add a pointer to PassInstrumentationCallbacks inside PrintIRInstrumentation and use the newly created map. This is a bit hacky, but I can't think of a better way since the short id to class name only exists within PassRegistry.def. This also doesn't handle passes not in PassRegistry.def but rather added via PassBuilder::registerPipelineParsingCallback(). llvm/test/CodeGen/Generic/print-after.ll doesn't seem very useful now with this change. Reviewed By: ychen, jamieschmeiser Differential Revision: https://reviews.llvm.org/D87216
2020-11-30[LegacyPM] Simplify PMTopLevelManager::collectLastUses. NFC.Jay Foad1-7/+3
2020-11-27[LegacyPM] Avoid a redundant map lookup in setLastUser. NFC.Jay Foad1-4/+2
As a bonus this makes it (IMO) obvious that the iterator is not invalidated, so remove the comment explaining that.
2020-11-27[LegacyPM] Remove unused undocumented parameter. NFC.Jay Foad1-2/+2
The Direction parameter to AnalysisResolver::getAnalysisIfAvailable has never been documented or used for anything.
2020-10-01Reland No.3: Add new hidden option -print-changed which only reports changes ↵Jamie Schmeiser1-2/+2
to IR A new hidden option -print-changed is added along with code to support printing the IR as it passes through the opt pipeline in the new pass manager. Only those passes that change the IR are reported, with others only having the banner reported, indicating that they did not change the IR, were filtered out or ignored. Filtering of output via the -filter-print-funcs is supported and a new supporting hidden option -filter-passes is added. The latter takes a comma separated list of pass names and filters the output to only show those passes in the list that change the IR. The output can also be modified via the -print-module-scope function. The code introduces an abstract template base class that generalizes the comparison of IRs that takes an IR representation as template parameter. Derived classes provide overrides that provide an event based API for generalized reporting of IRs as they are changed in the opt pipeline through the new pass manager. The first of several instantiations is provided that prints the IR in a form similar to that produced by -print-after-all with the above mentioned filtering capabilities. This version, and the others to follow will be introduced at the upcoming developer's conference. Reviewed By: aeubanks (Arthur Eubanks), yrouban (Yevgeny Rouban), ychen (Yuanfang Chen), MaskRay (Fangrui Song) Differential Revision: https://reviews.llvm.org/D86360
2020-09-17Revert "Re-land: Add new hidden option -print-changed which only reports ↵Douglas Yung1-2/+2
changes to IR" The test added in this commit is failing on Windows bots: http://lab.llvm.org:8011/builders/llvm-clang-win-x-armv7l/builds/1269 This reverts commit f9e6d1edc0dad9afb26e773aa125ed62c58f7080 and follow-up commit 6859d95ea2d0f3fe0de2923a3f642170e66a1a14.
2020-09-16Re-land: Add new hidden option -print-changed which only reports changes to IRJamie Schmeiser1-2/+2
A new hidden option -print-changed is added along with code to support printing the IR as it passes through the opt pipeline in the new pass manager. Only those passes that change the IR are reported, with others only having the banner reported, indicating that they did not change the IR, were filtered out or ignored. Filtering of output via the -filter-print-funcs is supported and a new supporting hidden option -filter-passes is added. The latter takes a comma separated list of pass names and filters the output to only show those passes in the list that change the IR. The output can also be modified via the -print-module-scope function. The code introduces a template base class that generalizes the comparison of IRs that takes an IR representation as template parameter. The constructor takes a series of lambdas that provide an event based API for generalized reporting of IRs as they are changed in the opt pipeline through the new pass manager. The first of several instantiations is provided that prints the IR in a form similar to that produced by -print-after-all with the above mentioned filtering capabilities. This version, and the others to follow will be introduced at the upcoming developer's conference. Reviewed By: aeubanks (Arthur Eubanks), yrouban (Yevgeny Rouban), ychen (Yuanfang Chen) Differential Revision: https://reviews.llvm.org/D86360
2020-09-03Revert "Add new hidden option -print-changed which only reports changes to IR"Jamie Schmeiser1-2/+2
This reverts commit 7bc9924cb2fbd9f3ae53577607822ace267a04e6 due to failure caused by missing a space between trailing >>, required by some versions of C++:wq.
2020-09-03Add new hidden option -print-changed which only reports changes to IRJamie Schmeiser1-2/+2
A new hidden option -print-changed is added along with code to support printing the IR as it passes through the opt pipeline in the new pass manager. Only those passes that change the IR are reported, with others only having the banner reported, indicating that they did not change the IR, were filtered out or ignored. Filtering of output via the -filter-print-funcs is supported and a new supporting hidden option -filter-passes is added. The latter takes a comma separated list of pass names and filters the output to only show those passes in the list that change the IR. The output can also be modified via the -print-module-scope function. The code introduces a template base class that generalizes the comparison of IRs that takes an IR representation as template parameter. The constructor takes a series of lambdas that provide an event based API for generalized reporting of IRs as they are changed in the opt pipeline through the new pass manager. The first of several instantiations is provided that prints the IR in a form similar to that produced by -print-after-all with the above mentioned filtering capabilities. This version, and the others to follow will be introduced at the upcoming developer's conference. See https://hotcrp.llvm.org/usllvm2020/paper/29 for more information. Reviewed By: yrouban (Yevgeny Rouban) Differential Revision: https://reviews.llvm.org/D86360
2020-08-28(Expensive) Check for Loop, SCC and Region pass return statusserge-sans-paille1-70/+2
This generalizes the logic introduced in https://reviews.llvm.org/D80916 to other passes. It's needed by https://reviews.llvm.org/D86442 to assert passes correctly report their status. Differential Revision: https://reviews.llvm.org/D86589
2020-07-28[OldPM] Print out a bit more when passes lie about changing IRJon Roelofs1-3/+6
https://reviews.llvm.org/D84686
2020-07-28[legacyPM] Do not compute preserved analysis if there's no local changeserge-sans-paille1-2/+4
All analysis are preserved if there's no local change, and thanks to 3667d87a33d3c8d4072a41fd84bb880c59347dc0 this property is enforced for all passes. Skipping the dependency computation improves the performance when there's a lot of small functions, where only a few change happen. Thanks to Nikita Popov who provided this numbers (extract below) https://llvm-compile-time-tracker.com/compare.php?from=183342c0a9850e60dd7a004b651c83dfb3a7d25e&to=f2f91e6a2743070471cc9471e4e8c646e50c653c&stat=instructions O3: (number of instructions) Benchmark Old New kimwitu++ 60783M 59968M (-1.34%) sqlite3 73200M 73083M (-0.16%) consumer-typeset 52776M 52712M (-0.12%) Bullet 133709M 132940M (-0.58%) tramp3d-v4 123864M 123186M (-0.55%) mafft 55534M 55477M (-0.10%) ClamAV 76292M 76164M (-0.17%) lencod 103190M 103061M (-0.13%) SPASS 64068M 63713M (-0.55%) 7zip 197332M 196308M (-0.52%) geomean 85750M 85389M (-0.42%) Differential Revision: https://reviews.llvm.org/D80707
2020-07-14Double check that passes correctly set their Modified statusserge-sans-paille1-0/+87
The approach is simple: if a pass reports that it's not modifying a Function/Module, compute a loose hash of that Function/Module and compare it with the original one. If we report no change but there's a hash change, then we have an error. This approach misses a lot of change but it's not super intrusive and can detect most of the simple mistakes. Differential Revision: https://reviews.llvm.org/D80916
2020-07-10Reland [NFC] Derive from PassInfoMixin for no-op/printing passesArthur Eubanks1-96/+106
PassInfoMixin should be used for all NPM passes, rater than a custom `name()`. This caused ambiguous references in LegacyPassManager.cpp, so had to remove "using namespace llvm::legacy" and move some things around. Reviewed By: ychen, asbirlea Differential Revision: https://reviews.llvm.org/D83498
2020-07-10Revert "[NFC] Derive from PassInfoMixin for no-op/printing passes"Davide Italiano1-106/+96
This reverts commit 8039d2c3bf14585ef37dc9343bf393ecad9aead9 as it breaks the modules build on macOS.