- Dec 21, 2023
-
-
Florian Hahn authored
Extra test for TODO from #75750.
-
boxu.zhang authored
The UnrollMaxUpperBound should be target dependent, since different chips provide different register set which brings different ability of storing more temporary values of a program. So I add a MaxUpperBound value in UnrollingPreference which can be override by targets. All uses of UnrollMaxUpperBound are replaced with UP.MaxUpperBound. The default value is still 8 and the command line argument '--unroll-max-upperbound' takes final effect if provided.
-
Matthias Springer authored
When operations are modified in-place, the rewriter must be notified. This commit fixes `mlir/test/Conversion/ArmSMEToLLVM/unsupported.mlir`, `mlir/test/Dialect/ArmSME/tile-zero-masks.mlir` and `mlir/test/Dialect/ArmSME/vector-ops-to-llvm.mlir` when running with `MLIR_ENABLE_EXPENSIVE_PATTERN_API_CHECKS` enabled.
-
Chuanqi Xu authored
bits and extract big bits from packed bits Previously I tried to improve the size of .pcm files by introducing packed bits. And I find we can improve it further by reordering the bits. The secret comes from the VBR format. We can find the formal definition of VBR format in the doc of LLVM. The VBR format will be pretty efficicent for small numbers. For example, if we need to pack 8 bits into a value and the stored value is 0xf0, the actual stored value will be 0b000111'110000, which takes 12 bits actually. However, if we changed the order to be 0x0f, then we can store it as 0b001111, which takes 6 bits only now. So we can improve the size by placing bits with lower probability to be 1 in the higher bits and extract bit bigs from the packed bits to make it possible to be optimized by VBR. After this patch, the size of std module becomes to 27.7MB from 28.1MB.
-
Nikita Popov authored
If all the demanded elements are poison, return unknown instead of conflict to avoid downstream assertions. Fixes https://github.com/llvm/llvm-project/issues/75505.
-
martinboehme authored
Instead, synthetic fields should now be used for the same purpose. These have a number of advantages, as described in https://github.com/llvm/llvm-project/pull/73860, and longer-term, we want to eliminate `RecordValue` entirely. As `RecordValue`s cannot have properties any more, I have replaced the `OptionalIntAnalysis` with an equivalent analysis that tracks nullness of pointers (instead of whether an optional has a value). This serves the same purpose, namely to check whether the framework applies a custom `merge()` operation to widen properties.
-
Vitaly Buka authored
-
martinboehme authored
This template function casts the result of `getValue()` or `getStorageLocation()` to a given subclass of `Value` or `StorageLocation` (using `cast_or_null`). It's a common pattern to do something like this: ```cxx auto *Val = cast_or_null<PointerValue>(Env.getValue(E)); ``` This can now be expressed more concisely like this: ```cxx auto *Val = Env.get<PointerValue>(E); ``` Instead of adding a new method `get()`, I had originally considered simply adding a template parameter to `getValue()` and `getStorageLocation()` (with a default argument of `Value` or `StorageLocation`), but this results in an undesirable repetition at the callsite, e.g. `getStorageLocation<RecordStorageLocation>(...)`. The `Value` and `StorageLocation` in the method name adds nothing of value when the template argument already contains this information, so it seemed best to shorten the method name to simply `get()`.
-
Christian Sigg authored
-
Tobias Gysi authored
This revision changes the alloca handling in the LLVM inliner. It ensures that alloca operations, even those nested within a region operation, can be relocated to the entry block of the function, or the closest ancestor region that is marked with either the isolated from above or automatic allocation scope trait. While the LLVM dialect does not have any region operations, the inlining interface may be used on IR that mixes different dialects.
-
Qizhi Hu authored
[clang][ASTImporter] add processing of SubstNonTypeTemplateParmExpr in isAncestorDeclContextOf (#74991) Lack of processing of `SubstNonTypeTemplateParmExpr` in `isAncestorDeclContextOf` would make `hasAutoReturnTypeDeclaredInside` returns false and lead to infinite recursion. This patch adds the processor and try to fix [this issue](https://github.com/llvm/llvm-project/issues/74839 ) Co-authored-by:
huqizhi <836744285@qq.com>
-
Yeting Kuo authored
Fold (fp_to_int (frint X)) to (fcvt X) without rounding mode.
-
Matthias Springer authored
When operations are modified in-place, the rewriter must be notified. This commit fixes `mlir/test/Dialect/EmitC/transforms.mlir` when running with `MLIR_ENABLE_EXPENSIVE_PATTERN_API_CHECKS` enabled.
-
Timm Bäder authored
-
Brandon Wu authored
-
Valentin Clement authored
Re-land PR after being reverted because of buildbot failures. This patch adds representation for `device_type` clause information on compute construct (parallel, kernels, serial). The `device_type` clause on compute construct impacts clauses that appear after it. The values impacted by `device_type` are now tied with an attribute array that represent the device_type associated with them. `DeviceType::None` is used to represent the value produced by a clause before any `device_type`. The operands and the attribute information are parser/printed together. This is an example with `vector_length` clause. The first value (64) is not impacted by `device_type` so it will be represented with DeviceType::None. None is not printed. The second value (128) is tied with the `device_type(multicore)` clause. ``` !$acc parallel vector_length(64) device_type(multicore) vector_length(256) ``` ``` acc.parallel vector_length(%c64 : i32, %c128 : i32 [#acc.device_type<multicore>]) { } ``` When multiple values can be produced for a single clause like `num_gangs` and `wait`, an extra attribute describe the number of values belonging to each `device_type`. Values and attributes are parsed/printed together. ``` acc.parallel num_gangs({%c2 : i32, %c4 : i32}, {%c4 : i32} [#acc.device_type<nvidia>]) ``` While preparing this patch I noticed that the wait devnum is not part of the operations and is not lowered. It will be added in a follow up patch. -
Shengchen Kan authored
-
Shengchen Kan authored
This fixes the build error after 61b58123
-
Shengchen Kan authored
NDD (new data destination) instructions need to set NoCD8 and EVEX_4V. EVEX_4V already implies EVEX. If NoCD8 implied EVEX too, we would not be able to reuse the class.
-
Vitaly Buka authored
-
Chuanqi Xu authored
This patch tries to pack more bits into a value to reduce the size of .pcm files. Also, after we introduced BitsPackers, it may slightly better to adjust the way we use Abbrev. After this patch, the size of the BMI for std module reduce from 28.94MB to 28.1 MB. This was reverted due to it broke the build of lldb. The reason that we skip the serialization of a source location incorrectly. And this patch now fixes that.
-
kda authored
-
Konstantin Varlamov authored
-
Han-Chung Wang authored
-
Joseph Huber authored
Summary: These are keys into the AMDGPU target metadata. One of them had a typo which prevented it from being extracted.
-
Max Winkler authored
See https://github.com/llvm/llvm-project/pull/75711 for discussion. As a summary from the PR above, `<adxintrin.h>` includes adc intrinsics and adx intrinsics. To support MSVC STL we need to expose the adc intrinsics inside the currently proposed `<intrin0.h>` header. Move the processor agnostic adc intrinsics into a separate file that can be included from `<immintrin.h>` and the currently proposed `<intrin0.h>`.
-
Alexander Yermolovich authored
We would always allocate maximum amount for vector containing DWARFUnitInfo. In real usecases what ends up hapenning is we allocate a giant vector when processing one CU, or for thin-lto case multiple CUs. This lead to a lot of memory overhead, and 2x BOLT processing slowdown for at least one service built with monolithic DWARF. For binaries built with LTO with clang all of CUs that have cross references will share an abbrev table and will be processed in one batch. Rest of CUs are processesd in --cu-processing-batch-size size. Which defaults to 1. For theoretical cases where cross-cu references are present, but they do not share abbrev will increase the size of CloneUnitCtxMap as each CU is being processsed.
-
Valentin Clement authored
This reverts commit 8b885eb9.
-
Valentin Clement authored
This reverts commit 8fdc3b98.
-
NAKAMURA Takumi authored
-
Vitaly Buka authored
There is an assumption that we dont need to to mix sanitizer with symbolizer from different LLVM revison. If so we can detect it by `__sanitizer_symbolize_code` and assume that the rest is present.
-
Maksim Levental authored
-
Joseph Huber authored
Summary: We currently keep a cache of created ELF files from the relevant images. This shouldn't be necessary as the entire ELF interface is generally trivially constructable and extremely cheap. The cost of constructing one of these objects is simply a size check and writing a pointer to the underlying data. Given that, keeping a cache of these images should not be necessary overall.
-
michaelrj-google authored
Add LIBC_INLINE annotations to functions and fix variable cases within printf_core and scanf_core.
-
Jonas Paulsson authored
Atomic instructions (load / store/ atomicrwm / cmpxchg) are not really undefined behavior if they lack natural alignment. They will (with AtomicExpand pass enabled) be converted into libcalls. Update the language reference to reflect this.
-
Shilei Tian authored
This patch reduces the size of heap memory required by the test `malloc_parallel.c` and `malloc.c`. The original size is too large such that `malloc` returns `nullptr` on many threads, causing illegal memory access.
-
Ivan R. Ivanov authored
Using the LoopInfo from OMPInfoCache after the Attributor ran resulted in a crash due to it being in an invalid state. --------- Co-authored-by:Ivan Radanov Ivanov <ivanov2@llnl.gov>
-
Ethan Luis McDonough authored
This patch add three GTest unit tests that test plugin read and write operations. Tests can be compiled with `ninja -C runtimes/runtimes-bins LibomptUnitTests`.
-
Cyndy Ishida authored
Stubify broadly takes either tbd files or binary dylibs and turns them into tbd files. In future patches, stubify will also allow additional information to be embedded into the final TBD output too. Add Util APIs to TextAPI for common operations used by readtapi for now.
-
Mikhail Gudim authored
InstCombine canonicalizes `add` to `or` when possible, but this makes some optimizations applicable to `add` to be missed because they don't realize that the `or` is equivalent to `add`. In this patch we generalize `foldICmpBinOp` to handle such cases.
-