summaryrefslogtreecommitdiff
path: root/lld/wasm
Commit message (Collapse)AuthorAgeFilesLines
* fix typos to cycle botsNico Weber2023-05-102-2/+2
|
* Revert "[Demangle] make llvm::demangle take std::string_view rather than ↵Nick Desaulniers2023-05-021-1/+1
| | | | | | | | | | | | | const std::string&" This reverts commit c117c2c8ba4afd45a006043ec6dd858652b2ffcc. itaniumDemangle calls std::strlen with the results of std::string_view::data() which may not be NUL-terminated. This causes lld/test/wasm/why-extract.s to fail when "expensive checks" are enabled via -DLLVM_ENABLE_EXPENSIVE_CHECKS=ON. See D149675 for further discussion. Back this out until the individual demanglers are converted to use std::string_view.
* [Demangle] make llvm::demangle take std::string_view rather than const ↵Nick Desaulniers2023-05-021-1/+1
| | | | | | | | | | | | | | | | | | std::string& As suggested by @erichkeane in https://reviews.llvm.org/D141451#inline-1429549 There's potential for a lot more cleanups around these APIs. This is just a start. Callers need to be more careful about sub-expressions producing strings that don't outlast the expression using ``llvm::demangle``. Add a release note. Reviewed By: MaskRay, #lld-macho Differential Revision: https://reviews.llvm.org/D149104
* [lld][WebAssembly] stub objects: Fix handling of LTO libcall dependenciesSam Clegg2023-04-131-7/+31
| | | | | | | | | | This actually simplifies the code by performs a pre-pass of the stub objects prior to LTO. This should be the final change needed before we can make the switch on the emscripten side: https://github.com/emscripten-core/emscripten/pull/18905 Differential Revision: https://reviews.llvm.org/D148287
* [lld][WebAssembly] Trace export of symbols when specified with ↵Sam Clegg2023-04-131-2/+6
| | | | | | --trace-symbol. NFC Differential Revision: https://reviews.llvm.org/D148190
* Fix warningsKazu Hirata2023-04-101-1/+1
| | | | | | | | | | This patch fixes: mlir/lib/Dialect/Linalg/TransformOps/LinalgTransformOps.cpp:1334:51: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] lld/wasm/Writer.cpp:250:39: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses]
* [lld][WebAssembly] Fix stub library parsing with windows line endingsSam Clegg2023-04-042-8/+12
| | | | | | | | Also, fix checking of first line in ::parse. We can't use the ::getLines helper here since that already does comment stripping internally. Differential Revision: https://reviews.llvm.org/D147548
* [lld][WebAssembly] Process stub libraries before performing LTOSam Clegg2023-03-301-4/+10
| | | | | | | | | | | | | | There are cases where stub library processing can trigger new exports which might require them to be included at LTO time. Specifically `processStubLibraries` marks symbols as `forceExports` which even effect the LTO process. And since the LTO process can generate new undefined symbols (specifically libcall function) we need to also process the stub libraries after LTO. Differential Revision: https://reviews.llvm.org/D147190
* [lld][WebAssembly] Initial support for stub librariesSam Clegg2023-03-239-5/+133
| | | | | | | | | | | See the docs in lld/docs/WebAssembly.rst for more on this. This feature unlocks a lot of simplification in the emscripten toolchain since we can represent the JS libraries to wasm-ld as stub libraries. See https://github.com/emscripten-core/emscripten/issues/18875 Differential Revision: https://reviews.llvm.org/D145308
* [NFC] Fix typo lld::wasm in commentCongcong Cai2023-03-231-1/+1
|
* [WebAssembly] Replace Bugzilla links with Github issuesHeejin Ahn2023-03-172-3/+4
| | | | | | Reviewed By: dschuff, asb Differential Revision: https://reviews.llvm.org/D145966
* [wasm] Silence 'not all control paths return a value' warning whenAlexandre Ganea2023-03-151-0/+1
| | | | building with MSVC on Windows
* [lld][WebAssembly] Use C++17 nested namespace syntax in most places. NFCSam Clegg2023-03-0917-69/+34
| | | | | | Like D131405, but for wasm-ld. Differential Revision: https://reviews.llvm.org/D145399
* [lld][WebAssembly] Implement --why-extract flag from the ELF backendSam Clegg2023-03-064-8/+56
| | | | | | See https://reviews.llvm.org/D109572 for the original ELF version. Differential Revision: https://reviews.llvm.org/D145431
* Reapply: [WebAssembly] Implement build-id featureDerek Schuff2023-03-036-0/+197
| | | | | | | | | | | | | | | | Implement the --build-id flag similarly to ELF, and generate a build_id section according to the WebAssembly tool convention specified in https://github.com/WebAssembly/tool-conventions/pull/183 The default style ("fast" aka "tree") hashes the contents of the output and (unlike ELF) generates a v5 UUID based on the hash (using a random namespace). It also supports generating a random v4 UUID, a sha1 hash, and a user-specified string (as ELF does). Differential Revision: https://reviews.llvm.org/D107662 Fix MSVC build by std::copy on the underying buffer rather than directly from std::array to llvm::MutableArrayRef
* Revert "[WebAssembly] Implement build-id feature"Derek Schuff2023-03-026-196/+0
| | | | | This reverts commit 41e31466af6a7feab82742bb01af43f4f3ae4ede due to a build failure on Windows.
* [WebAssembly] Implement build-id featureDerek Schuff2023-03-026-0/+196
| | | | | | | | | | | | | | Implement the --build-id flag similarly to ELF, and generate a build_id section according to the WebAssembly tool convention specified in https://github.com/WebAssembly/tool-conventions/pull/183 The default style ("fast" aka "tree") hashes the contents of the output and (unlike ELF) generates a v5 UUID based on the hash (using a random namespace). It also supports generating a random v4 UUID, a sha1 hash, and a user-specified string (as ELF does). Differential Revision: https://reviews.llvm.org/D107662
* [lld][WebAssembly] Fix handling of mixed strong and weak referencesSam Clegg2023-02-271-0/+10
| | | | | | | | | | When adding a undefined symbols to the symbol table, if the existing reference is weak replace the symbol flags with (potentially) non-weak binding. Fixes: https://github.com/llvm/llvm-project/issues/60829 Differential Revision: https://reviews.llvm.org/D144747
* [LLD] Add --lto-CGO[0-3] optionScott Linder2023-02-154-3/+16
| | | | | | | | | | | | | | | | | | Allow controlling the CodeGenOpt::Level independent of the LTO optimization level in LLD via new options for the COFF, ELF, MachO, and wasm frontends to lld. Most are spelled as --lto-CGO[0-3], but COFF is spelled as -opt:lldltocgo=[0-3]. See D57422 for discussion surrounding the issue of how to set the CG opt level. The ultimate goal is to let each function control its CG opt level, but until then the current default means it is impossible to specify a CG opt level lower than 2 while using LTO. This option gives the user a means to control it for as long as it is not handled on a per-function basis. Reviewed By: MaskRay, #lld-macho, int3 Differential Revision: https://reviews.llvm.org/D141970
* [lld][WebAssembly] Limit size of shared 64-bit memories of 2^^34Sam Clegg2023-02-131-1/+6
| | | | | | | | This is current limit in v8. See https://github.com/WebAssembly/memory64/issues/33 how we might change this in the future. Differential Revision: https://reviews.llvm.org/D143783
* [NFC][TargetParser] Replace uses of llvm/Support/Host.hArchibald Elliott2023-02-101-1/+1
| | | | | | | The forwarding header is left in place because of its use in `polly/lib/External/isl/interface/extract_interface.cc`, but I have added a GCC warning about the fact it is deprecated, because it is used in `isl` from where it is included by Polly.
* [NFC][TargetParser] Remove llvm/ADT/Triple.hArchibald Elliott2023-02-071-1/+1
| | | | | | I also ran `git clang-format` to get the headers in the right order for the new location, which has changed the order of other headers in two files.
* [lld] fix comment typos to cycle botsNico Weber2023-02-041-1/+1
|
* [lld][WebAssembly] Apply relocations to TLS dataSam Clegg2023-01-314-13/+68
| | | | | | | | | | This is only needed in the case of dynamic linking and pthreads. Previously these relocations were simply not being applied. Verified that this works using a more real world emscripten test: https://github.com/emscripten-core/emscripten/pull/18641 Differential Revision: https://reviews.llvm.org/D143020
* [lld] Remove transitional legacy pass manager flagsArthur Eubanks2023-01-261-2/+0
| | | | | | Reviewed By: asbirlea Differential Revision: https://reviews.llvm.org/D142571
* [OptTable] Precompute OptTable prefixes union table through tablegenserge-sans-paille2023-01-121-2/+2
| | | | | | | | | | | | | | This avoid rediscovering this table when reading each options, providing a sensible 2% speedup when processing and empty file, and a measurable speedup on typical workloads, see: This is optional, the legacy, on-the-fly, approach can still be used through the GenericOptTable class, while the new one is used through PrecomputedOptTable. https://llvm-compile-time-tracker.com/compare.php?from=4da6cb3202817ee2897d6b690e4af950459caea4&to=19a492b704e8f5c1dea120b9c0d3859bd78796be&stat=instructions:u Differential Revision: https://reviews.llvm.org/D140800
* [lld][WebAssembly] Fix memory.fill argument in 64-bit modeSam Clegg2023-01-101-1/+1
| | | | | | | | This only effects folks building with wasm64 + shared memory which is not currently a supported configuration in emscripten or any other wasm toolchain. Differential Revision: https://reviews.llvm.org/D141005
* [lld] Use std::optional instead of llvm::Optional (NFC)Kazu Hirata2023-01-0212-68/+79
| | | | | | | This is part of an effort to migrate from llvm::Optional to std::optional: https://discourse.llvm.org/t/deprecating-llvm-optional-x-hasvalue-getvalue-getvalueor/63716
* [lld] Fix iwyu problems after 83d59e05b201760e3f364ff6316301d347cbad95Fangrui Song2022-12-281-0/+1
| | | | | The commit transitively includes lld/include/lld/Common/ErrorHandler.h into lld/include/lld/Common/Driver.h, which is not intended.
* [clang] Use a StringRef instead of a raw char pointer to store builtin and ↵serge-sans-paille2022-12-271-1/+4
| | | | | | | | | | | | | | | | | call information This avoids recomputing string length that is already known at compile time. It has a slight impact on preprocessing / compile time, see https://llvm-compile-time-tracker.com/compare.php?from=3f36d2d579d8b0e8824d9dd99bfa79f456858f88&to=e49640c507ddc6615b5e503144301c8e41f8f434&stat=instructions:u This a recommit of e953ae5bbc313fd0cc980ce021d487e5b5199ea4 and the subsequent fixes caa713559bd38f337d7d35de35686775e8fb5175 and 06b90e2e9c991e211fecc97948e533320a825470. The above patchset caused some version of GCC to take eons to compile clang/lib/Basic/Targets/AArch64.cpp, as spotted in aa171833ab0017d9732e82b8682c9848ab25ff9e. The fix is to make BuiltinInfo tables a compilation unit static variable, instead of a private static variable. Differential Revision: https://reviews.llvm.org/D139881
* Revert "[clang] Use a StringRef instead of a raw char pointer to store ↵Vitaly Buka2022-12-251-4/+1
| | | | | | | | | | | | | | | | builtin and call information" Revert "Fix lldb option handling since e953ae5bbc313fd0cc980ce021d487e5b5199ea4 (part 2)" Revert "Fix lldb option handling since e953ae5bbc313fd0cc980ce021d487e5b5199ea4" GCC build hangs on this bot https://lab.llvm.org/buildbot/#/builders/37/builds/19104 compiling CMakeFiles/obj.clangBasic.dir/Targets/AArch64.cpp.d The bot uses GNU 11.3.0, but I can reproduce locally with gcc (Debian 12.2.0-3) 12.2.0. This reverts commit caa713559bd38f337d7d35de35686775e8fb5175. This reverts commit 06b90e2e9c991e211fecc97948e533320a825470. This reverts commit e953ae5bbc313fd0cc980ce021d487e5b5199ea4.
* [clang] Use a StringRef instead of a raw char pointer to store builtin and ↵serge-sans-paille2022-12-241-1/+4
| | | | | | | | | | | | | | | | | | | | | call information This avoids recomputing string length that is already known at compile time. It has a slight impact on preprocessing / compile time, see https://llvm-compile-time-tracker.com/compare.php?from=3f36d2d579d8b0e8824d9dd99bfa79f456858f88&to=e49640c507ddc6615b5e503144301c8e41f8f434&stat=instructions:u This is a recommit of 719d98dfa841c522d8d452f0685e503538415a53 that into account a GGC issue (probably https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92181) when dealing with intiailizer_list and constant expressions. Workaround this by avoiding initializer list, at the expense of a temporary plain old array. Differential Revision: https://reviews.llvm.org/D139881
* Revert "[clang] Use a StringRef instead of a raw char pointer to store ↵serge-sans-paille2022-12-231-3/+2
| | | | | | | | | | builtin and call information" There are still remaining issues with GCC 12, see for instance https://lab.llvm.org/buildbot/#/builders/93/builds/12669 This reverts commit 5ce4e92264102de21760c94db9166afe8f71fcf6.
* [clang] Use a StringRef instead of a raw char pointer to store builtin and ↵serge-sans-paille2022-12-231-2/+3
| | | | | | | | | | | | | | | | | call information This avoids recomputing string length that is already known at compile time. It has a slight impact on preprocessing / compile time, see https://llvm-compile-time-tracker.com/compare.php?from=3f36d2d579d8b0e8824d9dd99bfa79f456858f88&to=e49640c507ddc6615b5e503144301c8e41f8f434&stat=instructions:u This is a recommit of 719d98dfa841c522d8d452f0685e503538415a53 with a change to llvm/utils/TableGen/OptParserEmitter.cpp to cope with GCC bug https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108158 Differential Revision: https://reviews.llvm.org/D139881
* Revert "[clang] Use a StringRef instead of a raw char pointer to store ↵serge-sans-paille2022-12-231-3/+2
| | | | | | | | | builtin and call information" Failing builds: https://lab.llvm.org/buildbot#builders/9/builds/19030 This is GCC specific and has been reported upstream: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108158 This reverts commit 719d98dfa841c522d8d452f0685e503538415a53.
* [clang] Use a StringRef instead of a raw char pointer to store builtin and ↵serge-sans-paille2022-12-231-2/+3
| | | | | | | | | | | | | call information This avoids recomputing string length that is already known at compile time. It has a slight impact on preprocessing / compile time, see https://llvm-compile-time-tracker.com/compare.php?from=3f36d2d579d8b0e8824d9dd99bfa79f456858f88&to=e49640c507ddc6615b5e503144301c8e41f8f434&stat=instructions:u Differential Revision: https://reviews.llvm.org/D139881
* [Support] Move TargetParsers to new componentArchibald Elliott2022-12-201-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a fairly large changeset, but it can be broken into a few pieces: - `llvm/Support/*TargetParser*` are all moved from the LLVM Support component into a new LLVM Component called "TargetParser". This potentially enables using tablegen to maintain this information, as is shown in https://reviews.llvm.org/D137517. This cannot currently be done, as llvm-tblgen relies on LLVM's Support component. - This also moves two files from Support which use and depend on information in the TargetParser: - `llvm/Support/Host.{h,cpp}` which contains functions for inspecting the current Host machine for info about it, primarily to support getting the host triple, but also for `-mcpu=native` support in e.g. Clang. This is fairly tightly intertwined with the information in `X86TargetParser.h`, so keeping them in the same component makes sense. - `llvm/ADT/Triple.h` and `llvm/Support/Triple.cpp`, which contains the target triple parser and representation. This is very intertwined with the Arm target parser, because the arm architecture version appears in canonical triples on arm platforms. - I moved the relevant unittests to their own directory. And so, we end up with a single component that has all the information about the following, which to me seems like a unified component: - Triples that LLVM Knows about - Architecture names and CPUs that LLVM knows about - CPU detection logic for LLVM Given this, I have also moved `RISCVISAInfo.h` into this component, as it seems to me to be part of that same set of functionality. If you get link errors in your components after this patch, you likely need to add TargetParser into LLVM_LINK_COMPONENTS in CMake. Differential Revision: https://reviews.llvm.org/D137838
* Revert D139181 "[lld][Alignment][NFC] Use Align instead of log2 of alignment ↵Guillaume Chatelet2022-12-205-17/+15
| | | | | | | | in Wasm Sections" As discussed on the patch the Align type is probably not a good fit for linkers. This reverts commit cfe77f23d6f190d54763a7575cee95aceb9216bc.
* [lld] llvm::Optional::value => operator*/operator->Fangrui Song2022-12-172-4/+4
| | | | | std::optional::value() has undesired exception checking semantics and is unavailable in some older Xcode. The call sites block std::optional migration.
* llvm::Optional::value => operator*/operator->Fangrui Song2022-12-172-3/+3
| | | | | std::optional::value() has undesired exception checking semantics and is unavailable in some older Xcode. The call sites block std::optional migration.
* Store OptTable::Info::Name as a StringRefserge-sans-paille2022-12-081-1/+1
| | | | | | | | | | | | | | | | | | This is a recommit of 8ae18303f97d5dcfaecc90b4d87effb2011ed82e, with a few cleanups. This avoids implicit conversion to StringRef at several points, which in turns avoid redundant calls to strlen. As a side effect, this greatly simplifies the implementation of StrCmpOptionNameIgnoreCase. It also eventually gives a consistent, humble speedup in compilation time (timing updated since original commit). https://llvm-compile-time-tracker.com/compare.php?from=de4b6a1bc64db33643f001ad45fae7b92b4a4688&to=c23a93d1292052b4be2fbe8c586fa31143d0c7ed&stat=instructions:u Differential Revision: https://reviews.llvm.org/D139274
* [lld] Use std::nullopt instead of None (NFC)Kazu Hirata2022-12-023-15/+17
| | | | | | | | | | | | This patch mechanically replaces None with std::nullopt where the compiler would warn if None were deprecated. The intent is to reduce the amount of manual work required in migrating from Optional to std::optional. This is part of an effort to migrate from llvm::Optional to std::optional: https://discourse.llvm.org/t/deprecating-llvm-optional-x-hasvalue-getvalue-getvalueor/63716
* [lld][Alignment][NFC] Use Align instead of log2 of alignment in Wasm SectionsGuillaume Chatelet2022-12-025-15/+17
| | | | | | | | I intend to slowly upgrade all alignments to the Align type in lld as well. Some places talk about alignment in Bytes while other specify them as Log2(Bytes). Let's make sure all of this is coherent. Differential Revision: https://reviews.llvm.org/D139181
* [Alignment][NFC] Use Align in StringTableBuilder ctorGuillaume Chatelet2022-12-021-1/+2
|
* Reland "[LTO][COFF] Use bitcode file names in lto native object file names."Zequan Wu2022-11-221-6/+6
| | | | This reverts commit 34108082947c964ae9bbfcd9808f2fd31c0d672f with fixes.
* Revert "Reland "[LTO][COFF] Use bitcode file names in lto native object file ↵Roman Lebedev2022-11-231-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | names."" Breaks build of LLVMgold here: ``` /repositories/llvm-project/llvm/tools/gold/gold-plugin.cpp:1108:19: error: no matching function for call to 'localCache' Cache = check(localCache("ThinLTO", "Thin", options::cache_dir, AddBuffer)); ^~~~~~~~~~ /repositories/llvm-project/llvm/include/llvm/Support/Caching.h:72:21: note: candidate function not viable: no known conversion from '(lambda at /repositories/llvm-project/llvm/tools/gold/gold-plugin.cpp:1102:20)' to 'llvm::AddBufferFn' (aka 'function<void (unsigned int, const llvm::Twine &, std::unique_ptr<MemoryBuffer>)>') for 4th argument Expected<FileCache> localCache( ^ /repositories/llvm-project/llvm/tools/gold/gold-plugin.cpp:1110:18: error: no viable conversion from '(lambda at /repositories/llvm-project/llvm/tools/gold/gold-plugin.cpp:1094:20)' to 'llvm::AddStreamFn' (aka 'function<Expected<std::unique_ptr<CachedFileStream>> (unsigned int, const llvm::Twine &)>') check(Lto->run(AddStream, Cache)); ^~~~~~~~~ /usr/bin/../lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/bits/std_function.h:375:7: note: candidate constructor not viable: no known conversion from '(lambda at /repositories/llvm-project/llvm/tools/gold/gold-plugin.cpp:1094:20)' to 'std::nullptr_t' for 1st argument function(nullptr_t) noexcept ^ /usr/bin/../lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/bits/std_function.h:386:7: note: candidate constructor not viable: no known conversion from '(lambda at /repositories/llvm-project/llvm/tools/gold/gold-plugin.cpp:1094:20)' to 'const std::function<llvm::Expected<std::unique_ptr<llvm::CachedFileStream>> (unsigned int, const llvm::Twine &)> &' for 1st argument function(const function& __x) ^ /usr/bin/../lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/bits/std_function.h:404:7: note: candidate constructor not viable: no known conversion from '(lambda at /repositories/llvm-project/llvm/tools/gold/gold-plugin.cpp:1094:20)' to 'std::function<llvm::Expected<std::unique_ptr<llvm::CachedFileStream>> (unsigned int, const llvm::Twine &)> &&' for 1st argument function(function&& __x) noexcept ^ /usr/bin/../lib/gcc/x86_64-linux-gnu/12/../../../../include/c++/12/bits/std_function.h:435:2: note: candidate template ignored: requirement '_Callable<(lambda at /repositories/llvm-project/llvm/tools/gold/gold-plugin.cpp:1094:20) &, (lambda at /repositories/llvm-project/llvm/tools/gold/gold-plugin.cpp:1094:20), std::__invoke_result<(lambda at /repositories/llvm-project/llvm/tools/gold/gold-plugin.cpp:1094:20) &, unsigned int, const llvm::Twine &>>::value' was not satisfied [with _Functor = (lambda at /repositories/llvm-project/llvm/tools/gold/gold-plugin.cpp:1094:20) &] function(_Functor&& __f) ^ /repositories/llvm-project/llvm/include/llvm/LTO/LTO.h:278:25: note: passing argument to parameter 'AddStream' here Error run(AddStreamFn AddStream, FileCache Cache = nullptr); ^ ``` This reverts commit 387620aa8cea33174b6c1fb80c1af713fee732ac.
* Reland "[LTO][COFF] Use bitcode file names in lto native object file names."Zequan Wu2022-11-221-6/+6
| | | | This reverts commit eef5405f74ae208e3e2eb7daacecac923d7338f2.
* Revert "[LTO][COFF] Use bitcode file names in lto native object file names."Zequan Wu2022-11-221-6/+6
| | | | This reverts commit 531ed6d5aa65f41c6dfe2e74905d5c6c88fc95a7.
* [LTO][COFF] Use bitcode file names in lto native object file names.Zequan Wu2022-11-221-6/+6
| | | | | | | | | | | | | | | | | | Currently the lto native object files have names like main.exe.lto.1.obj. In PDB, those names are used as names for each compiland. Microsoft’s tool SizeBench uses those names to present to users the size of each object files. So, names like main.exe.lto.1.obj is not user friendly. This patch makes the lto native object file names more readable by using the bitcode file names as part of the file names. For example, if the input bitcode file has path like "path/to/foo.obj", its corresponding lto native object file path would be "path/to/main.exe.lto.foo.obj". Since the lto native object file name only bothers PDB, this patch only changes the lld-linker's behavior. Reviewed By: tejohnson, MaskRay, #lld-macho Differential Revision: https://reviews.llvm.org/D137217
* [ThinLTO] a ThinLTO warning is added if cache_size_bytes or cache_size_files ↵Ying Yi2022-11-141-1/+1
| | | | | | | | is too small for the current link job. The warning recommends the user to consider adjusting --thinlto-cache-policy. A specific case for ThinLTO cache pruning is that the current build is huge, and the cache wasn't big enough to hold the intermediate object files of that build. So in doing that build, a file would be cached, and later in that same build it would be evicted. This was significantly decreasing the effectiveness of the cache. By giving this warning, the user could identify the required cache size/files and improve ThinLTO link speed. Differential Revision: https://reviews.llvm.org/D135590