- May 16, 2023
-
-
Erich Keane authored
-
Jay Foad authored
This method is unused since MipsRegisterInfo is abstract and it is overridden in both concrete subclasses.
-
Joseph Huber authored
We do a lot of arithmetic on void pointers here, so include a helper and make some more consistent names. Changes no functionality. Reviewed By: JonChesterfield Differential Revision: https://reviews.llvm.org/D150576
-
Mateja Marjanovic authored
For image and buffer stores the default behaviour on GFX11 and older is to set all unset components to zero. So if we pass only X component it will be the same as X000, or XY same as XY00. This patch simplifies the passed vector of components in InstCombine by removing zero components from the end. For image stores it also trims DMask if necessary. Reviewed By: foad, arsenm Differential Revision: https://reviews.llvm.org/D146737
-
Dinar Temirbulatov authored
Currently any cast operation with fixed length vectors uses NEON costs, If those operations are end up using SVE instruction then we estimate those operations based upon SVE costs. Differential Revision: https://reviews.llvm.org/D133955
-
Kadir Cetinkaya authored
FunctionDecls can be created with null types (D124351 added such a new code path), to be filled in later. But parsing can stop before completing the Decl (e.g. if code completion point is reached). Unfortunately most of the methods in FunctionDecl and its derived classes assume a complete decl and don't perform null-checks. Since we're not encountring crashes in the wild along other code paths today introducing extra checks into quite a lot of places didn't feel right (due to extra complexity && run time checks). I believe another alternative would be to change Parser & Sema to never create decls with invalid types, but I can't really see an easy way of doing that, as most of the pieces are structured around filling that information as parsing proceeds. Differential Revision: https://reviews.llvm.org/D149733
-
- May 15, 2023
-
-
Erich Keane authored
Now that we've updated to C++23, we need to add C++26/C++2c command line flags, as discussed in https://discourse.llvm.org/t/rfc-lets-just-call-it-c-26-and-forget-about-the-c-2c-business-at-least-internally/70383 Differential Revision: https://reviews.llvm.org/D150450
-
J. Ryan Stinnett authored
This reverts commit d421f522. LLDB tests are failing as shown in https://green.lab.llvm.org/green/view/LLDB/job/lldb-cmake/55133/testReport/
-
Aart Bik authored
The sparse compiler now has two prototype strategies for GPU acceleration: * CUDA codegen: this converts sparsified code to CUDA threads * CUDA libgen: this converts pre-sparsified code to cuSPARSE library calls This revision introduces the first steps required for the second approach. Reviewed By: ThomasRaoux Differential Revision: https://reviews.llvm.org/D150170
-
Qiongsi Wu authored
This patch adds clang options `-mxcoff-roptr` and `-mno-xcoff-roptr` to specify storage locations for constant pointers on AIX. When the `-mxcoff-roptr` option is in effect, constant pointers, virtual function tables, and virtual type tables are placed in read-only storage. When the `-mno-xcoff-roptr` option is in effect, pointers, virtual function tables, and virtual type tables are placed are placed in read/write storage. This patch depends on https://reviews.llvm.org/D144189. Reviewed By: hubert.reinterpretcast, stephenpeckham Differential Revision: https://reviews.llvm.org/D144190
-
Jay Foad authored
-
Oleg Shyshkov authored
Differential Revision: https://reviews.llvm.org/D150543
-
Chenle Yu authored
This patch implements the "task record and replay" mechanism. The idea is to be able to store tasks and their dependencies in the runtime so that we do not pay the cost of task creation and dependency resolution for future executions. The objective is to improve fine-grained task performance, both for those from "omp task" and "taskloop". The entry point of the recording phase is __kmpc_start_record_task, and the end of record is triggered by __kmpc_end_record_task. Tasks encapsulated between a record start and a record end are saved, meaning that the runtime stores their dependencies and structures, referred to as TDG, in order to replay them in subsequent executions. In these TDG replays, we start the execution by scheduling all root tasks (tasks that do not have input dependencies), and there will be no involvement of a hash table to track the dependencies, yet tasks do not need to be created again. At the beginning of __kmpc_start_record_task, we must check if a TDG has already been recorded. If yes, the function returns 0 and starts to replay the TDG by calling __kmp_exec_tdg; if not, we start to record, and the function returns 1. An integer uniquely identifies TDGs. Currently, this identifier needs to be incremented manually in the source code. Still, depending on how this feature would eventually be used in the library, the caller function must do it; also, the caller function needs to implement a mechanism to skip the associated region, according to the return value of __kmpc_start_record_task. Reviewed By: tianshilei1992 Differential Revision: https://reviews.llvm.org/D146642
-
Nikita Popov authored
Align the way we perform exhaustive tests for KnownBits with what we do for ConstantRange. Test each case separately by specifying a function on KnownBits and one on APInts. Additionally, specify a callback that determines which cases are supposed to be optimal, rather than only correct. Unlike the ConstantRange case there is a well-defined, unique notion of optimality for KnownBits. If a failure occurs, print out the inputs, computed result and exact result. Adjust the printing function to produce the output in a format that is meaningful for KnownBits, i.e. print the actual known bits, using ? to signify unknowns and ! to signify conflicts.
-
Erich Keane authored
This came up during the C++26 flag discussion, so split this out into a separate patch.
-
Sameer Sahasrabuddhe authored
At a cycle C with divergent exits, UA was using a naive traversal of the exiting edges to locate blocks that may use values defined inside C. But this traversal fails when it encounters a cycle. This is now replaced with a much simpler propagation that iterates over every instruction in C and checks any uses that are outside C. But such an iteration can be expensive when C is very large; the original strategy may need to be reconsidered if there is a regression in compilation times. Also fixed lit tests that should have originally caught the missed propagation of temporal divergence. Reviewed By: foad Differential Revision: https://reviews.llvm.org/D149646
-
Manupa Karunaratne authored
This commit adds lowering of lib func call to support erf in rocdl. Reviewed By: ThomasRaoux Differential Revision: https://reviews.llvm.org/D150355
-
Alex Zinenko authored
Structured fusion proceeds by iteratively finding the next suitable producer to be fused into the loop. Therefore, it shouldn't matter if the same producer is listed multiple times (e.g., it is used as multiple operands). Adjust the implementation of the transform op to support this case. Also fix the checking code in the interpreter to actually respect the TransformOpInterface indication that repeated payload is allowed, it seems to have been accidentally dropped in one of the refactorings. Reviewed By: nicolasvasilache Differential Revision: https://reviews.llvm.org/D150561
-
Kyle Huey authored
Prior to this patch, for the DWARF frame base LLVM uses the frame pointer register if available, otherwise the stack pointer register. If the stack pointer register is being used and a call or other code modifies the stack pointer during the body of the function this results in the locations being wrong and the debugger displaying the wrong values for variables. By using DW_OP_call_frame_cfa in these situations the emitted location for the variable will automatically handle changes in the stack pointer. The CFA needs to be adjusted for the offset between the frame pointer/stack pointer to allow the variable locations themselves to remain unchanged by this patch. Reviewed By: #debug-info, scott.linder, jryans Differential Revision: https://reviews.llvm.org/D143463
-
Florian Hahn authored
Extra test using mull for D150482.
-
khei4 authored
Differential Revision: https://reviews.llvm.org/D150515 Reviewed By: nikic
-
Nikolas Klauser authored
This reverts commit cbd9e545. The wrong patch was landed.
-
Francesco Petrogalli authored
Remove the warning caused by a missing field initializer. The field is `StartAtCycle` of `struct MCWriteProcResEntry`. It has been set to the default `StartAtCycle = 0`. Differential Revision: https://reviews.llvm.org/D150569
-
Nikolas Klauser authored
Reviewed By: ldionne, #libc Spies: libcxx-commits Differential Revision: https://reviews.llvm.org/D149615
-
Matthias Springer authored
Block arguments and yielded values are not equivalent if there are not enough block arguments. This fixes #59442. Differential Revision: https://reviews.llvm.org/D145575
-
Matthias Springer authored
This is useful for debugging. Differential Revision: https://reviews.llvm.org/D143314
-
Jan Kuhle authored
Contributed by @jankuehle! https://reviews.llvm.org/D150116 introduced a bug. `export type X = Y` was considered an export declaration and took part in import sorting. This is not correct. With this change `export type X = Y` properly terminates import sorting. Reviewed By: krasimir Differential Revision: https://reviews.llvm.org/D150563
-
Matthias Springer authored
Instead of passing traversal options as a long list of arguments, store them in a TraversalConfig object and pass that object. Differential Revision: https://reviews.llvm.org/D143927
-
Jay Foad authored
We can use the following 16-VGPR tuple directly instead of splitting it into smaller parts: $vgpr240_vgpr241_vgpr242_vgpr243_vgpr244_vgpr245_vgpr246_vgpr247_vgpr248_vgpr249_vgpr250_vgpr251_vgpr252_vgpr253_vgpr254_vgpr255
-
https://reviews.llvm.org/D149718Manna, Soumi authored
The patch(https://reviews.llvm.org/D149718) broke buildbot ../../clang/include/clang/Sema/ParsedAttr.h:705:18: error: explicitly defaulted move assignment operator is implicitly deleted [-Werror,-Wdefaulted-function-deleted] AttributePool &operator=(AttributePool &&pool) = default; ^ ../../clang/include/clang/Sema/ParsedAttr.h:674:21: note: move assignment operator of 'AttributePool' is implicitly deleted because field 'Factory' is of reference type 'clang::AttributeFactory &' AttributeFactory &Factory; ^ 1 error generated. This patch fixes the build error.
-
Nikita Popov authored
GlobalDCE will only remove functions with available externally linkage if they are unreferenced. As such, I don't believe there is any problem with running this pass as part of the ThinLTO pre-link pipeline. It will only remove functions that are completely dead in that module, and I don't think there is any benefit to keeping them around for the post-link phase. There is no compile-time impact from the additional pass. This is a followup to one of the side discussions in D146776. Differential Revision: https://reviews.llvm.org/D149446
-
Piotr Sobczak authored
Update code that assumes llvm.canonicalize only handles scalars, by adding a call to getScalarType(). This is fine, as the intrinsic is trivially vectorizable. Introduced in D147870, and uncovered by D148065. Differential Revision: https://reviews.llvm.org/D150556
-
Matthias Springer authored
Incorrect API usage was detected by D144552. Differential Revision: https://reviews.llvm.org/D145167
-
Matthias Springer authored
If an op is unknown to the analysis, it must be treated conservatively: assume that every operand aliases with every result. Differential Revision: https://reviews.llvm.org/D150546
-
Haojian Wu authored
[clangd] Fix fixAll not shown when there is only one unused-include and missing-include diagnostics. Discovered during the review in https://reviews.llvm.org/D149437#inline-1444851. Differential Revision: https://reviews.llvm.org/D149822
-
Alejandro Álvarez Ayllón authored
* After a malformed top-level declaration * After a malformed templated class method declaration In both cases, when there is a malformed declaration, any following namespace is dropped from the AST. This can trigger a cascade of confusing diagnostics that may hide the original error. An example: ``` // Start #include "SomeFile.h" template <class T> void Foo<T>::Bar(void* aRawPtr) { (void)(aRawPtr); } // End #include "SomeFile.h" int main() {} ``` We get the original error, plus 19 others from the standard library. With this patch, we only get the original error. clangd can also benefit from this patch, as namespaces following the malformed declaration is now preserved. i.e. ``` MACRO_FROM_MISSING_INCLUDE("X") namespace my_namespace { //... } ``` Before this patch, my_namespace is not visible for auto-completion. Differential Revision: https://reviews.llvm.org/D150258 -
Joseph Huber authored
This patch adds another variable to cache cases where we know that we own the buffer. This allows us to skip the atomic load on the inbox because we already know its state. This is legal immediately after opening a port, or when sending immediately after a recieve. This caching nets a significant (~17%) speedup for the basic open, send, recieve combination. Reviewed By: JonChesterfield Differential Revision: https://reviews.llvm.org/D150516
-
Joseph Huber authored
We use a simple bump ptr in the `libc` tests. If we run out of data we can currently return other static memory and have weird failure cases. We should fail more explicitly here by returning a null pointer instead. Reviewed By: sivachandra Differential Revision: https://reviews.llvm.org/D150529
-
Martin Braenne authored
Attempting to analyze templated code doesn't have a good cost-benefit ratio. We have so far done a best-effort attempt at this, but maintaining this support has an ongoing high maintenance cost because the AST for templates can violate a lot of the invariants that otherwise hold for the AST of concrete code. As just one example, in concrete code the operand of a UnaryOperator '*' is always a prvalue (https://godbolt.org/z/s3e5xxMd1), but in templates this isn't true (https://godbolt.org/z/6W9xxGvoM). Further rationale for not analyzing templates: * The semantics of a template itself are weakly defined; semantics can depend strongly on the concrete template arguments. Analyzing the template itself (as opposed to an instantiation) therefore has limited value. * Analyzing templates requires a lot of special-case code that isn't necessary for concrete code because dependent types are hard to deal with and the AST violates invariants that otherwise hold for concrete code (see above). * There's precedent in that neither Clang Static Analyzer nor the flow-sensitive warnings in Clang (such as uninitialized variables) support analyzing templates. Reviewed By: gribozavr2, xazax.hun Differential Revision: https://reviews.llvm.org/D150352
-
Florian Hahn authored
Update VPReplicateRecipe to use VPRecipeWithIRFlags for IR flag handling. Retire separate MayGeneratePoisonRecipes map. Depends on D149082. Reviewed By: Ayal Differential Revision: https://reviews.llvm.org/D150027
-