- May 16, 2022
-
-
David Green authored
Under some situations we can visit 64bit vector extract elements in tryCombineFixedPointConvert, where an assert fires as they are expected to have been converted to 128bit. Turn the assert into an if statement, bailing out and letting the extract be handled first. Also invert some ifs, using early exits to reduce indentation. Fixes #55417
-
Denis Antrushin authored
FunctionLoweringInfo::StatepointRelocationMaps map is used to pass GC pointer lowering information from statepoint to gc.relocate which may appear ini different block. D124444 introduced different lowering for local and non-local relocates. Local relocates use SDValue and non-local relocates use value exported to VReg. But I overlooked the fact that StatepointRelocationMap is indexed not by GCRelocate instruction, but by derived pointer. This works incorrectly when we have two relocates (one local and another non-local) of the same value, because they need different relocation records. This patch fixes the problem by recording relocation information per relocate instruction, not per derived pointer. This way, each gc.relocate can be lowered differently. Reviewed By: skatkov Differential Revision: https://reviews.llvm.org/D125538
-
owenca authored
Clean up UnwrappedLineParser for RemoveBracesLLVM to avoid calling mightFitOnOneLine() as much as possible. Differential Revision: https://reviews.llvm.org/D125626
-
Tobias Ribizel authored
I am working on support for forwarding parameter names in make_unique-like functions, first for inlay hints, later maybe for signature help. For that to work generically, I'd like to parse all of these functions in the preamble. Not sure how this impacts performance on large codebases though. Reviewed By: sammccall Differential Revision: https://reviews.llvm.org/D124688
-
Nicolas Abram Lujan authored
This is based on https://reviews.llvm.org/D125168 which adds a wrapper to allow use of opaque pointers from the C API. I added an opaque pointer mode test to echo.ll, and to fix assertions that forbid the use of mixed typed and opaque pointers that were triggering in it I had to also add wrappers for setOpaquePointers() and isOpaquePointer(). I also changed echo.ll to remove a bitcast i32* %x to i8*, because passing it through llvm-as and llvm-dis was generating a %0 = bitcast ptr %x to ptr, but when building that same bitcast in echo.cpp it was getting elided by IRBuilderBase::CreateCast (https://github.com/llvm/llvm-project/blob/08ac66124874d70dab63c731da0244f9e29ef168/llvm/include/llvm/IR/IRBuilder.h#L1998-L1999). Differential Revision: https://reviews.llvm.org/D125183
-
Jay Foad authored
This is a mechanical change to avoid passing MRI and TII around explicitly. NFC. Differential Revision: https://reviews.llvm.org/D125566
-
Jay Foad authored
Make this an externally callable function for use in a future patch. Differential Revision: https://reviews.llvm.org/D125565
-
Haojian Wu authored
With this patch, we're able to parse smaller chunks of C++ code (statement, declaration), rather than translation-unit. The start symbol is listed in the grammar in a form of `_ := statement`, each start symbol has a dedicated state (`_ := • statement`). We create and track all these separate states in the LRTable. When we start parsing, we lookup the corresponding state to start the parser. LR pasing table changes with this patch: - number of states: 1467 -> 1471 - number of actions: 82891 -> 83578 - size of the table (bytes): 334248 -> 336996 Differential Revision: https://reviews.llvm.org/D125006
-
Nikita Popov authored
While select conditions can be poison, branch on poison is immediate UB. As such, we need to freeze the condition when converting a select into a branch. Differential Revision: https://reviews.llvm.org/D125398
-
Diana Picus authored
At the moment the Fortran_main library is not installed, so it cannot be found by the driver when run from an install directory. This patch fixes the issue by replacing llvm_add_library with add_flang_library, which already contains all the proper incantations for installing a library. It also enhances add_flang_library to support a STATIC arg which forces the library to be static even when BUILD_SHARED_LIBS is on. Differential Revision: https://reviews.llvm.org/D124759 Co-authored-by:
Dan Palermo <Dan.Palermo@amd.com>
-
Nikita Popov authored
FastISel tries to fold loads into the single using instruction. However, if the register has fixups, then there may be additional uses through an alias of the register. In particular, this fixes the problem reported at https://reviews.llvm.org/D119432#3507087. The load register is (at the time of load folding) only used in a single call instruction. However, selection of the bitcast has added a fixup between the load register and the cross-BB register of the bitcast result. After fixups are applied, there would now be two uses of the load register, so load folding is not legal. Differential Revision: https://reviews.llvm.org/D125459
-
Gregory Fong authored
The combination of - AlignConsecutiveAssignments.Enabled = true - BinPackArguments = false would result in the first continuation line of a braced-init-list being improperly indented (missing a shift) when in a continued function call. Indentation was also wrong for braced-init-lists continuing a direct-list-initialization. Check for opening braced lists in continuation and ensure that the correct shift occurs. Fixes https://github.com/llvm/llvm-project/issues/55360 Reviewed By: curdeius Differential Revision: https://reviews.llvm.org/D125162
-
Kirill Bobyrev authored
-
David Sherwood authored
When the loop vectoriser encounters a known low trip count it tries to create a single predicated loop in order to get the benefit of vectorisation and eliminate the scalar tail. However, until now the vectoriser prevented the use of scalable vectors in this case due to concerns in the past about stability. I believe that tail-folded loops using scalable vectors are now sufficiently well tested that we can enable this. For the same reason I've also enabled it when optimising for code size too. Tests added here: Transforms/LoopVectorize/AArch64/sve-low-trip-count.ll Transforms/LoopVectorize/AArch64/sve-tail-folding-optsize.ll Transforms/LoopVectorize/RISCV/low-trip-count.ll Differential Revision: https://reviews.llvm.org/D121595
-
Kirill Bobyrev authored
Disable the warnings with `IWYU pragma: export` or `begin_exports` + `end_exports` until we have support for these pragmas. There are too many false-positive warnings for the headers that have the correct pragmas for now and it makes the user experience very unpleasant. Reviewed By: sammccall Differential Revision: https://reviews.llvm.org/D125468
-
stk authored
On Apple Silicon Macs, using a Darwin thread priority of PRIO_DARWIN_BG seems to map directly to the QoS class Background. With this priority, the thread is confined to efficiency cores only, which makes background indexing take forever. Introduce a new ThreadPriority "Low" that sits in the middle between Background and Default, and maps to QoS class "Utility" on Mac. Make this new priority the default for indexing. This makes the thread run on all cores, but still lowers priority enough to keep the machine responsive, and not interfere with user-initiated actions. I didn't change the implementations for Windows and Linux; on these systems, both ThreadPriority::Background and ThreadPriority::Low map to the same thread priority. This could be changed as a followup (e.g. by using SCHED_BATCH for Low on Linux). See also https://github.com/clangd/clangd/issues/1119. Reviewed By: sammccall, dgoldman Differential Revision: https://reviews.llvm.org/D...
-
Kito Cheng authored
-
Marek Kurdej authored
Fixes https://github.com/llvm/llvm-project/issues/55407. Given configuration: ``` UseTab: Always PointerAlignment: Right AlignConsecutiveDeclarations: true ``` Before, the pointer was misaligned in this code: ``` void f() { unsigned long long big; char *ptr; // misaligned int i; } ``` That was due to the fact that when handling right-aligned pointers, the Spaces were changed but StartOfTokenColumn was not. Also, a tab was used not only for indentation but for spacing too when using `UseTab: ForIndentation` config option: ``` void f() { unsigned long long big; char *ptr; // \t after char int i; } ``` Reviewed By: owenpan Differential Revision: https://reviews.llvm.org/D125528
-
Kito Cheng authored
This patch is preparation for D111617, use class/struct/enum rather than char/StringRef to present internal information as possible, that provide more compact way to store those info and also easier to serialize/deserialize. And also that improve readability of the code, e.g. "v" vs TypeProfile::Vector. Reviewed By: khchen Differential Revision: https://reviews.llvm.org/D124730
-
LLVM GN Syncbot authored
-
Jim Lin authored
SDIVREM and UDIVREM can be customized lowered in MipsSE. Fix https://github.com/llvm/llvm-project/issues/54991. Reviewed By: sdardis Differential Revision: https://reviews.llvm.org/D124980
-
Jim Lin authored
Copied from PowerPC. Reviewed By: sdardis Differential Revision: https://reviews.llvm.org/D124979
-
serge-sans-paille authored
When a non-const compound statement is used to initialize a constexpr pointer, the pointed value is not const itself and cannot be folded at codegen time. This matches GCC behavior for compound literal expr arrays. Fix issue #39324. Differential Revision: https://reviews.llvm.org/D124038
-
bzcheeseman authored
Casting from a type to itself should always be possible. Make this simple for all users, and add tests to ensure we keep being able to do this. Ref: https://reviews.llvm.org/D125543 Reviewed By: rriddle Differential Revision: https://reviews.llvm.org/D125590
-
jacquesguan authored
This patch replaces some for-each set with the new arrayref argument API, since it already used an array in defination, I think this change won't cause any ambiguity. Differential Revision: https://reviews.llvm.org/D125455
-
Chuanqi Xu authored
zero Closing https://github.com/llvm/llvm-project/issues/55402 Reviewed By: efriedma Differential Revision: https://reviews.llvm.org/D125521
-
Zakk Chen authored
We need to use tail undisturbed for vslideup to implement vector insert operation correctly. Ideally, we cound use the tail agnostic when insert subvector or element at the end of the vector. This will be in follow-up patch. Reviewed By: craig.topper Differential Revision: https://reviews.llvm.org/D125545
-
Matthias Springer authored
Instead of recomputing memref types from tensor types, try to infer them when possible. This results in more precise layout maps. Differential Revision: https://reviews.llvm.org/D125614
-
Simon Pilgrim authored
Make it easier to reuse in X86 ADD/SUB combines in an upcoming patch.
-
Florian Hahn authored
Under some circumstances, SCEVExpander will insert new instructions when expanding a predicate, but the final result of the expansion can be a false constant. In those cases, the expanded instructions may later be used by other expansions, e.g. the trip count. This may trigger an assertion during SCEVExpander cleanup. To avoid this, always mark the result as used. Fixes #55100.
-
Simon Pilgrim authored
znver1/2 models were incorrectly modelling these on fpupipe 0 instead of 2/3 and znver1 ymm variants also require double pumping. Now matches AMD SoG, Agner and instlatx64 numbers. Thanks to @fabian-r for the report
-
Alexey Lapshin authored
this review is extracted from D86539 1. delete areRelocationsResolved() method. 2. rename hasLiveMemoryLocation() -> isLiveVariable() hasLiveAddressRange() -> isLiveSubprogram(). Differential Revision: https://reviews.llvm.org/D125492 -
Daniel Kiss authored
This reverts commit f6366ef7.
-
Andrzej Warzynski authored
After the recent re-factoring of the driver code (https://reviews.llvm.org/D125007), `ExecuteAction` was renamed as `executeAction`. This patch updates the examples in Flang accordingly. If you set `FLANG_BUILD_EXAMPLES` to `On` when building Flang, then the refactoring from D125007 would have caused build failures for you. This patch fixes that. This is fairly straightforward and fixes buildbot failures, so I'm sending this without a review.
-
Craig Topper authored
-
Craig Topper authored
ctpop and cttz default expansion both end up using a multiply. This can either use a mul instruction or libcall. Make sure we test both cases.
-
Craig Topper authored
Add more i8/16 tets. Add ctlz_zero_undef tests.
-
Simon Pilgrim authored
-
- May 15, 2022
-
-
Simon Pilgrim authored
-
Simon Pilgrim authored
-