- Apr 20, 2024
-
-
Jan Leyonberg authored
This patch changes the lowering of max and min to be lowered to arith::MaxNumFop and arith::MinNumFOp instead of using arith::MaximumFOp and arith::MinimumFOp. The arith::MaximumFOp and arith::MinimumFOp map to the corresponding intrinsics llvm.maximum.* and llvm.minimum.* intrinsics which conform to the semantics specified in the draft of IEEE 754-2019, which is not supported by all hardware. Instead using arith::MaximumFOp and arith::MinimumFOp will allow code generation for more targets and match the code generated by clang OpenMP. fixes #87955
-
Bill Wendling authored
A struct that declares an inner struct, but no fields, won't have a field count. So getting the offset of the inner struct fails. This happens in both C and C++: struct foo { struct bar { int Quantizermatrix[]; }; }; Here 'struct foo' has no fields. Closes: https://github.com/llvm/llvm-project/issues/88931 -
Valentin Clement (バレンタイン クレメン) authored
Fixed size array and scalar should be allowed with the `managed` attribute.
-
Jan Svoboda authored
Pruning non-affecting module maps is useful even when passing module maps explicitly via `-fmodule-map-file=<path>`. For this situation, this patch reinstates the behavior we had prior to #87849. For the situation where the explicit module map file arguments were generated by the dependency scanner (which already pruned the non-affecting ones), this patch introduces new `-cc1` flag `-fno-modules-prune-non-affecting-module-map-files` that avoids the extra work.
-
Craig Topper authored
This code used to use the PadToColumn feature of formatted_raw_ostream, but no longer does. formatted_raw_ostream is slower than regular raw_ostream because it has to keep track of the number of character since the last new line character.
-
Craig Topper authored
Planning to declare all extensions in tablegen so we can generate the tables for RISCVISAInfo.cpp. This requires making "e" consistent with other extensions.
-
Craig Topper authored
This requires type legalization to keep them the same. This means we no longer need to legalize the operand since it will be legalized when we legalize the second result.
-
Fabio D'Urso authored
Downstream disabled EnableContiguousRegions on RISCV-64 to avoid running out of virtual memory, but our tests still use the internal FuchsiaConfig class, which therefore needs to be changed too.
-
Fangrui Song authored
so that `Args.ClaimAllArgs(options::OPT_CompileOnly_Group);` in Driver::handleArguments will claim the options even if only linking is performed. Fix #87945
-
Michael Liao authored
- Add the missing token in @llvm.coro.end
-
Simon Pilgrim authored
This patch moves the promotion to vXi16 shifts and the upper/lower bit masking into LowerFunnelShift for targets that have a bit-select instruction (XOP's VPCMOV and AVX512's VPTERNLOG). This prevents the regressions in #89115 due to the masking of ((X << V) | (Y >> (8-V))) vXi8 shifts.
-
Slava Zakharin authored
This reverts commit 215eee60.
-
Michael Klemm authored
It seems like the `flang-to-external-fc` tool is no longer needed, because Flang is now a full compiler in its own right. After PR #85249 has landed, this tool will not be able to pick up the `.f18.mod` files.
-
Rob Suderman authored
If `tensor.reshape` occurs with `d0, d1, d2, ...` for the dimensions we know that the reshape is a no-op. Checking for this case lets us fold away the computation.
-
Krystian Stasiowski authored
[libc++] Fix usage of 'exclude_from_explicit_instantiation' attribute on local class members (#89377) #88777 adds a warning for when the `exclude_from_explicit_instantiation` attribute is applied to local classes and members thereof. This patch addresses the few instances of `exclude_from_explicit_instantiation` being applied to local class members in libc++.
-
Matthias Braun authored
This improves handling of `threadlocal.address` intrinsic in analyses: The thread-id cannot change within a function with the exception of suspend points of pre-split coroutines. This changes `llvm::getUnderlyingObject` to look through `threadlocal.address` in these cases. `GlobalsAAResult::AnalyzeUsesOfPointer` checks whether an address can be traced to simple loads/stores or escapes to other places. Starting the analysis from a thread-local `GlobalValue` the `threadlocal.address` intrinsic is safe to skip here. This improves issue #87437
-
LRFLEW authored
This PR is a followup to #81080. This PR makes two major changes to how the LCG operation is computed: The first is that I added an additional case where `ax + c` might overflow the intermediate variable, but `ax` by itself won't. In this case, it's much better to use `(ax mod m) + c mod m` than the previous behavior of falling back to Schrage's algorithm. The addition modulo is done in the same way as when using Schrage's algorithm (i.e. `x += c - (x >= m - c)*m`), but the multiplication modulo is calculated directly, which is faster. The second is that I added handling for the case where the `ax` intermediate might overflow, but Schrage's algorithm doesn't apply (i.e. r > q). In this case, the only real option is to increase the precision of the intermediate values. The good news is that - for `x`, `a`, and `c` being n-bit values - `ax + c` will never overflow a 2n-bit intermediary, meaning this promotion can only happen once, and will always be able to use the simplest implementation. This is already the case for 16-bit LCGs, as libcxx chooses to compute them with 32-bit intermediate values. For 32-bit LCGs, I simply added code similar to the 16-bit case to use the existing 64-bit implementations. Lastly, for 64-bit LCGs, I wrote a case that calculates it using `unsigned __int128` if it is available to use. While this implementation covers a *lot* of the missing cases from #81080, this still won't compile **every** possible `linear_congruential_engine`. Specifically, if `a`, `c`, and `m` are chosen such that it needs 128-bit integers, but the platform doesn't support `__int128` (eg. 32-bit x86), then it will fail to compile. However, this is a fairly rare case to see actually used, and libcxx would be in good company with this, as [libstdc++ also fails to compile under these circumstances](https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87744). Fixing **this** gap would require even **more** work of further complexity, so that would probably be best handled by a different PR (I'll put more details on what that PR would entail in a comment).
-
Fangrui Song authored
-
Jorge Gorbe Moya authored
-
Yijia Gu authored
-
Troy Butler authored
Fixes #83241 --------- Signed-off-by:
Troy-Butler <squintik@outlook.com> Co-authored-by:
Troy-Butler <squintik@outlook.com>
-
Arthur Eubanks authored
To be removed and promoted to a proper driver flag if experiments turn out fruitful. For now, this can be experimented with `-mllvm -pgo-cold-func-opt=[optsize|minsize|optnone|default] -mllvm -enable-pgo-force-function-attrs`. Original LLVM patch for this functionality: #69030
-
Jeff Niu authored
This PR changes the LLVM dialect's IntegerOverflowFlags to be stored on operations as native properties. Reland to fix flang
-
Fangrui Song authored
llvm-readelf/llvm-readobj print RELR as REL relocations with a fixed type (e.g. `R_*_RELATIVE`). GNU readelf printed only addresses and have recently switched to a more descritive style that includes a symbolic address column (symbolized using .symtab/.strtab) (milestone: binutils 2.43). This patch implements the new GNU style, which seems superior to the current REL style and essentially obsoletes LLVM-specific --raw-relr (`printRelrReloc`). Pull Request: https://github.com/llvm/llvm-project/pull/89162
-
Nick Desaulniers authored
- use namespaced identifiers - add corresponding headers for namespaced declarations - replace time.h and errno.h with finer grain includes - update cmake Fixes: #88987 Fixes: #89261 Link: #88997 Link: #89262
-
Fangrui Song authored
GNU ld added --default-script (alias: -dT) in 2007. The option specifies a default script that is processed if --script/-T is not specified. -dT can be used to override GNU ld's internal linker script, but only when the application does not specify -T. In addition, dynamorio's CMakeLists.txt may use -dT. The implementation is simple and the feature can be useful to dabble with different section layouts. Pull Request: https://github.com/llvm/llvm-project/pull/89327
-
- Apr 19, 2024
-
-
Simon Pilgrim authored
Silence pass by value warnings Fixes #89210
-
cor3ntin authored
Lambdas used in the initializer of a local class were not mangling the name of the member. Fixes #88906
-
Sergio Afonso authored
This patch extends verification of the `omp.parallel` operation to check it is correctly defined when taking a loop wrapper role. In OpenMP, a PARALLEL construct can be either a (potenially combined) block construct or a loop construct, when appearing as part of a composite construct. This is currently the case for the DISTRIBUTE PARALLEL DO/FOR and DISTRIBUTE PARALLEL DO/FOR SIMD exclusively. When used to represent the PARALLEL leaf of a composite construct, it must follow the rules of a wrapper loop operation in MLIR, and this is what this patch ensures. No additional restrictions are introduced for PARALLEL block constructs.
-
Sergio Afonso authored
This patch replaces some `saveInsertionPoint`, `restoreInsertionPoint` call pairs for an `InsertionGuard` instance where it makes sense within Flang OpenMP lowering to make further modifications less error-prone.
-
Christian Ulmann authored
This commit fixes a bug in the DICompositeType element ignore mode. It seems that vectors require the presence of elements, as they otherwise do not pass the verifier.
-
ZelinMa557 authored
fixes #88348 proof: https://alive2.llvm.org/ce/z/fJnM7t test will be added later --------- Signed-off-by:
ZelinMa557 <3388706467@qq.com>
-
Dinar Temirbulatov authored
This reverts commit 950bb097
-
Kojo Acquah authored
[mlir][ArmNeon] Update `LowerContractionToSMMLAPattern` to support proper unrolling for k dimension (#88591) Fixes correctness issue with current smmla unrolling patterns whereby unrolling K dimension would only include the result from the last tile along K. Updates patterns to feed previous smmla output of the previous tile into the next one along K.
-
Adam Siemieniuk authored
Adds a pass that folds aliasing ops into XeGPU ops.
-
Yaxun (Sam) Liu authored
__hipRegisterFatBinary only accepts one pointer argument. It is expected to get the fat binary size from the header. This patch adds a file size field to the header of the compressed bundle.
-
Paul Robinson authored
It caused the \headerfile directive to be considered as part of the brief description in some of our tooling.
-
Valentin Clement (バレンタイン クレメン) authored
-
Balazs Benics authored
Interestingly, this case crashed from the very beginning of the project, at least starting by clang-3. As a "fix" I just do the same thing as we do for concrete integers. It might not be the best we could do, but arguably, it's still better than crashing. Fixes #89185
-
Jay Foad authored
Needed for a future patch.
-