- Jun 04, 2024
-
-
Simon Camphausen authored
Currently an expression is inlined without emitting enclosing parentheses regardless of the context of the user. This could led to wrong evaluation order depending on the precedence of both expressions. If the inlining is intended, the user operation should be merged into the expression op. Fixes #93470.
-
Florian Hahn authored
Store getSE result in variable to re-use and use structured bindings when looping over bounds.
-
Pierre van Houtryve authored
-
David Spickett authored
This came up when testing the CI build, which is not being build with scripting yet.
-
Abid Qadeer authored
The DISubrange can take integer, dwarf expressions or variables. The current translation only handled integers. This PR adds handling of dwarf expressions and variables.
-
Vlad Serebrennikov authored
This patch refactors an existing test for [CWG2390](https://cplusplus.github.io/CWG/issues/2390.html) "Is the argument of `__has_cpp_attribute` macro-expanded?" to use `#error` instead of emitting a variable in IRGen and checking it via FileCheck. As a bonus, this makes it possible to move the test into `cwg23xx.cpp`.
-
Tom Eccles authored
The pass constructor can be generated automatically by tablegen. The pass is module-level and iterates over every operation within the module so it should not need any changes to support alternative top level operations.
-
Nikita Popov authored
This preserves the flags if a constexpr GEP is created (at least as long as they don't get dropped later -- the test cases uses a constexpr index to avoid that).
-
Chuanqi Xu authored
Motivated by the review process in https://github.com/llvm/llvm-project/pull/75912. This can also help to simplify the code slightly.
-
Florian Hahn authored
Add a test case with a missed simplification when hoisting runtime checks due to not applying loop guards.
-
Nikita Popov authored
This preserves the flags during that transform, but currently they will still end up getting dropped at a later stage.
-
Nikita Popov authored
Flags are already fully preserved for the instruction case, but lost on constant expressions.
-
Chuanqi Xu authored
This reverts commit d8ec452d. This fails on LLDB macOS CI. See https://github.com/llvm/llvm-project/pull/92083 for details.
-
Kai Luo authored
-
Balázs Kéri authored
Checker alpha.security.PutenvStackArray is moved to security.PutenvStackArray.
-
Nikita Popov authored
-
Ramkumar Ramachandra authored
VPTypeAnalysis::inferScalarTypeForRecipe is missing the case for VPInstruction::LogicalAnd, due to which the test vplan-incomplete-cases.ll crashes. Add this missing case, and move the test in vplan-infer-not-or-type.ll to vplan-incomplete-cases.ll, showing correct codegen for trip-counts 2 and 3.
-
Nikita Popov authored
Since the switch to opaque pointers, zero-index GEPs will be optimized away anyway, so there is no need to explicitly handle them here.
-
cor3ntin authored
Fix regression introduced by #93216
-
c8ef authored
Fixes #93650
-
Nikita Popov authored
-
Chuanqi Xu authored
Inspired by the review process in https://github.com/llvm/llvm-project/pull/92085. The check `ID >= FirstIdentID` can cover the following check `!II->isFromAST()`.
-
Michael Kruse authored
Update the folder titles for targets in the monorepository that have not seen taken care of for some time. These are the folders that targets are organized in Visual Studio and XCode (`set_property(TARGET <target> PROPERTY FOLDER "<title>")`) when using the respective CMake's IDE generator. * Ensure that every target is in a folder * Use a folder hierarchy with each LLVM subproject as a top-level folder * Use consistent folder names between subprojects * When using target-creating functions from AddLLVM.cmake, automatically deduce the folder. This reduces the number of `set_property`/`set_target_property`, but are still necessary when `add_custom_target`, `add_executable`, `add_library`, etc. are used. A LLVM_SUBPROJECT_TITLE definition is used for that in each subproject's root CMakeLists.txt.
-
Nikita Popov authored
-
Nikita Popov authored
-
Pavel Labath authored
-
Chuanqi Xu authored
Following of https://github.com/llvm/llvm-project/pull/86912 The motivation of the patch series is that, for a module interface unit `X`, when the dependent modules of `X` changes, if the changes is not relevant with `X`, we hope the BMI of `X` won't change. For the specific patch, we hope if the changes was about irrelevant declaration changes, we hope the BMI of `X` won't change. **However**, I found the patch itself is not very useful in practice, since the adding or removing declarations, will change the state of identifiers and types in most cases. That said, for the most simple example, ``` // partA.cppm export module m:partA; // partA.v1.cppm export module m:partA; export void a() {} // partB.cppm export module m:partB; export void b() {} // m.cppm export module m; export import :partA; export import :partB; // onlyUseB; export module onlyUseB; import m; export inline void onluUseB() { b(); } ``` the BMI of `onlyUseB` will change after we change the implementation of `partA.cppm` to `partA.v1.cppm`. Since `partA.v1.cppm` introduces new identifiers and types (the function prototype). So in this patch, we have to write the tests as: ``` // partA.cppm export module m:partA; export int getA() { ... } export int getA2(int) { ... } // partA.v1.cppm export module m:partA; export int getA() { ... } export int getA(int) { ... } export int getA2(int) { ... } // partB.cppm export module m:partB; export void b() {} // m.cppm export module m; export import :partA; export import :partB; // onlyUseB; export module onlyUseB; import m; export inline void onluUseB() { b(); } ``` so that the new introduced declaration `int getA(int)` doesn't introduce new identifiers and types, then the BMI of `onlyUseB` can keep unchanged. While it looks not so great, the patch should be the base of the patch to erase the transitive change for identifiers and types since I don't know how can we introduce new types and identifiers without introducing new declarations. Given how tightly the relationship between declarations, types and identifiers, I think we can only reach the ideal state after we made the series for all of the three entties. The design of the patch is similar to https://github.com/llvm/llvm-project/pull/86912, which extends the 32-bit DeclID to 64-bit and use the higher bits to store the module file index and the lower bits to store the Local Decl ID. A slight difference is that we only use 48 bits to store the new DeclID since we try to use the higher 16 bits to store the module ID in the prefix of Decl class. Previously, we use 32 bits to store the module ID and 32 bits to store the DeclID. I don't want to allocate additional space so I tried to make the additional space the same as 64 bits. An potential interesting thing here is about the relationship between the module ID and the module file index. I feel we can get the module file index by the module ID. But I didn't prove it or implement it. Since I want to make the patch itself as small as possible. We can make it in the future if we want. Another change in the patch is the new concept Decl Index, which means the index of the very big array `DeclsLoaded` in ASTReader. Previously, the index of a loaded declaration is simply the Decl ID minus PREDEFINED_DECL_NUMs. So there are some places they got used ambiguously. But this patch tried to split these two concepts. As https://github.com/llvm/llvm-project/pull/86912 did, the change will increase the on-disk PCM file sizes. As the declaration ID may be the most IDs in the PCM file, this can have the biggest impact on the size. In my experiments, this change will bring 6.6% increase of the on-disk PCM size. No compile-time performance regression observed. Given the benefits in the motivation example, I think the cost is worthwhile.
-
Benjamin Chetioui authored
-
Vladimir Vereschaka authored
Avoid usage DEFAULT_SYSROOT CMake variable to confgiure the ARM/Aarch64 cross platform toolchain builds. Use the Clang configuration files with proper `--sysroot=` in it instead. More details could be found here: https://github.com/llvm/llvm-project/issues/94284 -
martinboehme authored
To avoid generating unnecessary values, we don't create a new value but instead leave it to the specific analysis to do this if desired.
-
Nikita Popov authored
Remove support for the icmp and fcmp constant expressions. This is part of: https://discourse.llvm.org/t/rfc-remove-most-constant-expressions/63179 As usual, many of the updated tests will no longer test what they were originally intended to -- this is hard to preserve when constant expressions get removed, and in many cases just impossible as the existence of a specific kind of constant expression was the cause of the issue in the first place.
-
Tina Jung authored
Convert all arith.cmpf on floats (not vectors/tensors thereof) to EmitC. --------- Co-authored-by:
Matthias Gehre <matthias.gehre@amd.com> Co-authored-by:
Jose Lopes <jose.lopes@amd.com>
-
Christian Sigg authored
-
Christian Sigg authored
-
Han-Chung Wang authored
In some cases (see https://github.com/iree-org/iree/issues/16285), `memref.subview` ops can't be folded into transfer ops and sub-byte type emulation fails. This issue has been blocking a few things, including the enablement of vector flattening transformations (https://github.com/iree-org/iree/pull/16456 ). This PR extends the existing sub-byte type emulation support of `memref.subview` to handle multi-dimensional subviews with dynamic offsets and addresses the issues for some of the `memref.subview` cases that can't be folded. Co-authored-by:
Diego Caballero <diegocaballero@google.com>
-
LLVM GN Syncbot authored
-
Younan Zhang authored
This patch picks up #78598 with the hope that we can address such crashes in `tryCaptureVariable()` for unevaluated lambdas. In addition to `tryCaptureVariable()`, this also contains several other fixes on e.g. lambda parsing/dependencies. Fixes #63845 Fixes #67260 Fixes #69307 Fixes #88081 Fixes #89496 Fixes #90669 Fixes #91633
-
Maksim Panchenko authored
Move functionality for patching build ID into a separate rewriter class and change the way we do the patching. Support build ID in different note sections in order to update the build ID in the Linux kernel binary which puts in into ".notes" section instead of ".note.gnu.build-id".
-
Teresa Johnson authored
With the change in 2fa05919 we can now use a range for loop.
-
klensy authored
Similar to https://github.com/rust-lang/rust/pull/125007
-