- Nov 22, 2022
-
-
Alvin Wong authored
Fixes https://github.com/llvm/llvm-project/issues/59021 Reviewed By: #libc, philnik Differential Revision: https://reviews.llvm.org/D138268
-
Max Kazantsev authored
Currently this is NFC, because SymbolicMaximum for BB is not implemented and just reuses exact result. However, from code purity perspective, it's a necessary step to do. Plans to implement symbolic max for blocks are underway.
-
Pierre van Houtryve authored
Add missing logic to select i16 variants and enable GISel testing. Reviewed By: arsenm Differential Revision: https://reviews.llvm.org/D136448
-
Lorenzo Chelini authored
Pack and Unpack return new tensors within which the individual elements are reshuffled according to the packing specification. This has the consequence of modifying the canonical order in which a given operator (i.e., Matmul) accesses the individual elements. After bufferization, this typically translates to increased access locality and cache behavior improvement, e.g., eliminating cache line splitting. Co-authored-by:
Mahesh Ravishankar <ravishankarm@google.com> Co-authored-by:
Han-Chung Wang <hanchung@google.com> RFC: https://discourse.llvm.org/t/rfc-tensor-pack-and-tensor-unpack/66408/1 Reviewed By: nicolasvasilache, rengolin, hanchung Differential Revision: https://reviews.llvm.org/D138119
-
Chen Zheng authored
Add global isel support for G_FADD, G_FSUB, G_FMUL, G_FDIV. Reviewed By: Kai, nemanjai, arsenm, amyk Differential Revision: https://reviews.llvm.org/D132942
-
gonglingqin authored
As discussed in D137541, it supports processing when the depth of __builtin_frame_address is greater than 0 instead of reporting an error. Unsafe calls rely on the '-Wframe-address' option for diagnosis. Differential Revision: https://reviews.llvm.org/D138084
-
Chen Zheng authored
For case that LROffset + FrameSize can not be encoded to the LR store instruction, we have to store the LR before the stack update.
-
Chen Zheng authored
-
David Green authored
The add from the IV in the inner loop was always checking for 2 uses, the phi and the compare. The compare could be based on the phi though, leaving one valid use of the compare. In the testcase we could be left with the phi and a lcssa phi as the two users, invalidly allowing flattening where we shouldn't. Fixes 58441 Differential Revision: https://reviews.llvm.org/D138404
-
Mahesh Ravishankar authored
Elementwise op fusion conserves the result of the producer in the fused op, relying on later clean up patterns to drop unused results of the fused op. Instead, if the producer result has no other use apart from the consumer op, avoid making the producer result available in the fused node. This saves some unnecessary IR manipulations. Differential Revision: https://reviews.llvm.org/D138096
-
Max Kazantsev authored
These limitations are too strict, and their only purpose is to avoid code size explosion. These restrictions seem obsolete, and the size problem is solved in other places through cheap expansion limits. The motivation is that the old code cannot deal with comparisons against induction variant's increment. Differential Revision: https://reviews.llvm.org/D138412 Reviewed By: lebedev.ri, reames
-
KAWASHIMA Takahiro authored
`-fapprox-func` should be disabled by `-fp-model={strict|precise}`, as well as other fast-math flags. See the last changes in `clang/test/Driver/fp-model.c`. Probably this route (`case options::OPT_ffp_model_EQ`) was forgot to update in D106191 and D114564. There is no appropriate reason not to disable the flag. This commit also updates other regression tests, which are not directly related to this bug, for consistency with other fast-math flags. Differential Revision: https://reviews.llvm.org/D138109 -
Craig Topper authored
After D137970, we do the fixable instruction conversion in place so we don't need to worry about iterator invalidation. This lets us to conversion and updates in a single loop. Reviewed By: reames Differential Revision: https://reviews.llvm.org/D138043
-
Craig Topper authored
Instead of creating a new instruction and copying operands, we can use setDesc to convert in place. Reviewed By: reames Differential Revision: https://reviews.llvm.org/D137970
-
Craig Topper authored
If the immediate is a shifted mask, we will use a pair of shifts and never materialize the immediate. Consider the immediate free. Reviewed By: reames, luismarques Differential Revision: https://reviews.llvm.org/D138260
-
Kazu Hirata authored
This patch replaces: return Optional<T>(); with: return None; to make the migration from llvm::Optional to std::optional easier. Specifically, I can deprecate None (in my source tree, that is) to identify all the instances of None that should be replaced with std::nullopt. Note that "return None" far outnumbers "return Optional<T>();". There are more than 2000 instances of "return None" in our source tree. All of the instances in this patch come from functions that return Optional<T> except Archive::findSym and ASTNodeImporter::import, where we return Expected<Optional<T>>. Note that we can construct Expected<Optional<T>> from any parameter convertible to Optional<T>, which None certainly is. 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 Differential Revision: https://reviews.llvm.org/D138464
-
Kazu Hirata authored
Since std::optional does not offer getPointer(), this patch replaces X.getPointer() with &*X to make the migration from llvm::Optional to std::optional easier. 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 Differential Revision: https://reviews.llvm.org/D138466
-
Phoebe Wang authored
This patch is an alternative of D100091. It solved the problems in `f80` type lowering. Reviewed By: LuoYuanke Differential Revision: https://reviews.llvm.org/D137946
-
Vitaly Buka authored
Update pattern on Linux and Darwin for consistency.
-
Stephen Neuendorffer authored
This tool only parsed options after creating the LLVMContext. Unfortunately, this means that some options, such as --opaque-pointers, which are read when the LLVMContext is created are impossible to set from the command line. This patch moves the LLVMContext creation after the option parsing.
-
Vitaly Buka authored
tr is not available on Windows bot.
-
Nico Weber authored
-
KAWASHIMA Takahiro authored
Indentation is significant for Sphinx. Lines with indentation after a `.. option::` line are treated as explanations of the option.
-
KAWASHIMA Takahiro authored
-
KAWASHIMA Takahiro authored
Sphinx has the `option` directive. Most option descriptions in `clang/docs/UsersManual.rst` used it but some didn't. This commit changes the remaining option descriptions to use the `option` directive. This makes a consistent view in HTML. The `option` directive automatically creates a cross-reference target. So labeling by `.. _opt_XXX:` is almost unnecessary. However, options with and without `no-` (e.g. `-fno-show-column`/`-fshow-column`) cannot be distinguish for the cross-reference. So some required `.. _opt_XXX:` directives are kept unremoved. Differential Revision: https://reviews.llvm.org/D138088
-
Vitaly Buka authored
-
Peiming Liu authored
Reviewed By: aartbik Differential Revision: https://reviews.llvm.org/D138169
-
Christopher Di Bella authored
This makes it possible for programmers to run IWYU and get more accurate standard library inclusions. Prior to this commit, the following program would be transformed thusly: ```cpp // Before #include <algorithm> #include <vector> void f() { auto v = std::vector{0, 1}; std::find(std::ranges::begin(v), std::ranges::end(v), 0); } ``` ```cpp // After #include <__algorithm/find.h> #include <__ranges/access.h> #include <vector> ... ``` There are two ways to fix this issue: to use [comment pragmas](https://github.com/include-what-you-use/include-what-you-use/blob/master/docs/IWYUPragmas.md) on every private include, or to write a canonical [mapping file](https://github.com/include-what-you-use/include-what-you-use/blob/master/docs/IWYUMappings.md) that provides the tool with a manual on how libc++ is laid out. Due to the complexity of libc++, this commit opts for the latter, to maximise correctness and minimise developer burden. To mimimise... -
Kazu Hirata authored
The last use of emitCalleeSavedFrameMoves was removed on March 24, 2022 in commit 50a97aac. Differential Revision: https://reviews.llvm.org/D138388
-
Evgenii Stepanov authored
Mysterious failures on the x86_64-linux-qemu, to be debugged. This reverts commit 1dd54691.
-
Aart Bik authored
Reviewed By: Peiming Differential Revision: https://reviews.llvm.org/D138343
-
Nico Weber authored
Adds build files for libraries, tools, and tests -- everything except the runtime. Doesn't hook up bolt in the main BUILD.gn file yet -- I want to verify that it builds on Linux, macOS, Windows before doing that. (I've only checked on macOS so far.) `ninja check-bolt` passes on macOS with this. (I locally bumped the deployment target to macOS 10.12 for that. bolt/ uses std::mutex quite a bit, which requires 10.12.) Differential Revision: https://reviews.llvm.org/D138355
-
Advenam Tacet authored
This revision is a part of a series of patches extending AddressSanitizer C++ container overflow detection capabilities by adding annotations, similar to those existing in std::vector, to std::string and std::deque collections. These changes allow ASan to detect cases when the instrumented program accesses memory which is internally allocated by the collection but is still not in-use (accesses before or after the stored elements for std::deque, or between the size and capacity bounds for std::string). The motivation for the research and those changes was a bug, found by Trail of Bits, in a real code where an out-of-bounds read could happen as two strings were compared via a std::equals function that took iter1_begin, iter1_end, iter2_begin iterators (with a custom comparison function). When object iter1 was longer than iter2, read out-of-bounds on iter2 could happen. Container sanitization would detect it. This revision adds a new compiler-rt ASa...
-
Vitaly Buka authored
-
Vitaly Buka authored
-
Nico Weber authored
This has the following advantages: - std::shared_timed_mutex is macOS 10.12+ only. llvm::sys::RWMutex automatically switches to a different implementation internally when targeting older macOS versions. - bolt only needs std::shared_mutex, not std::shared_timed_mutex. llvm::sys::RWMutex automatically uses std::shared_mutex internally where available. std::shared_mutex and RWMutex have the same API, so no code changes other than types and includes are needed. Differential Revision: https://reviews.llvm.org/D138423
-
Aart Bik authored
This brings back previous SIMD functionality, but in a separate pass. The idea is to improve this new pass incrementally, going beyond for-loops to while-loops for co-iteration as welll (masking), while introducing new abstractions to make the lowering more progressive. The separation of sparsification and vectorization is a very good first step on this journey. Also brings back ArmSVE support Still to be fine-tuned: + use of "index" in SIMD loop (viz. a[i] = i) + check that all ops really have SIMD support + check all forms of reductions + chain reduction SIMD values Reviewed By: dcaballe Differential Revision: https://reviews.llvm.org/D138236
-
David Blaikie authored
-
Kai Nacke authored
Extends the global isel implementation to support G_ADD and G_SUB. Reviewed By: arsenm, amyk Differential Revision: https://reviews.llvm.org/D128106
-
Louis Dionne authored
Differential Revision: https://reviews.llvm.org/D138435
-