- Sep 04, 2021
-
-
Balazs Benics authored
Quoting https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html: > In the absence of the zero-length array extension, in ISO C90 the contents > array in the example above would typically be declared to have a single > element. We should not assume that the size of the //flexible array member// field has a single element, because in some cases they use it as a fallback for not having the //zero-length array// language extension. In this case, the analyzer should return `Unknown` as the extent of the field instead. Reviewed By: martong Differential Revision: https://reviews.llvm.org/D108230
-
Kazuaki Ishizaki authored
`the the` -> `the` Reviewed By: xgupta Differential Revision: https://reviews.llvm.org/D77470
-
Loren Maggiore authored
Create a gpu memset op and corresponding CUDA and ROCm wrappers. Reviewed By: herhut, lorenrose1013 Differential Revision: https://reviews.llvm.org/D107548
-
Kazu Hirata authored
-
Brad Smith authored
-
Brad Smith authored
-
Kevin Athey authored
This reverts commit 095bea23. Broke buildbot: https://lab.llvm.org/buildbot/#/builders/5/builds/11411
-
William S. Moses authored
FuncOp always lowers to an LLVM external linkage presently. This makes it impossible to define functions in mlir which are local to the current module. Until MLIR FuncOps have a more formal linkage specification, this commit allows funcop's to have an optionally specified llvm.linkage attribute, whose value will be used as the linkage of the llvm funcop when lowered. Differential Revision: https://reviews.llvm.org/D108524 Support LLVM linkage
-
Brad Smith authored
-
Ben Shi authored
Prevent the folding if it leads to worse code. Reviewed By: dmgreen Differential Revision: https://reviews.llvm.org/D108871
-
Lang Hames authored
-
Richard Smith authored
-
Med Ismail Bennani authored
This patch should fix the build failure that surfaced when build llvm with GCC: https://lab.llvm.org/staging/#/builders/16/builds/10450 GCC complained that I explicitely specialized `ScriptedPythonInterface::ExtractValueFromPythonObject` in a in non-namespace scope, which is tolerated by Clang. To solve this issue, the specialization were declared out of the class and implemented in the source file. Signed-off-by:
Med Ismail Bennani <medismail.bennani@gmail.com>
-
Brad Smith authored
-
Mehdi Amini authored
This makes the IR more readable, in particular when this will be used on the builtin func outside of the LLVM dialect. Reviewed By: wsmoses Differential Revision: https://reviews.llvm.org/D109209
-
Frederic Cambus authored
Differential Revision: https://reviews.llvm.org/D109244
-
David Blaikie authored
-
Michael Kruse authored
The preprocessor definitions __BYTE_ORDER__, __ORDER_BIG_ENDIAN__, and __ORDER_LITTLE_ENDIAN__ are gcc extensions (also supported by clang), but msvc (and others) do not define them. As a result __BYTE_ORDER__ and __ORDER_BIG_ENDIAN__ both evaluate to 0 by the prepreprocessor, and __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__, the first `#if` condition to 1, hence assuming the wrong byte order for x86(_64). This patch instead uses CMake's TestBigEndian module to determine target architecture's endianness at configure-time. Note this also uses the same mechanism for the runtime. If compiling flang as a cross-compiler, the runtime for the compile-target must be built separately (Flang does not support the LLVM_ENABLE_RUNTIMES mechanism yet). Fixes llvm.org/PR51597 Reviewed By: ijan1, Leporacanthicus Differential Revision: https://reviews.llvm.org/D109108
-
Michael Jones authored
Fix edge case where "0x" would be considered a complete hexadecimal number for purposes of str_end. Now the hexadecimal prefix needs a valid digit after it, else just the 0 will be counted as the number. Reviewed By: sivachandra Differential Revision: https://reviews.llvm.org/D109084
-
Aart Bik authored
This simplifies setting up sparse tensors through C-style data structures. Useful for runtimes that want to interact with MLIR-generated code without knowning about all bufferization details (viz. memrefs). Reviewed By: bixia Differential Revision: https://reviews.llvm.org/D109251
-
Jinsong Ji authored
The test driver-fopenmp-extensions.c is failing on platforms that does not use integrated-as. It can be reproduced using -fno-integrated-as on Linux too. bin/clang -c -Xclang -verify=omp -fopenmp -fopenmp-extensions -fno-openmp-extensions ../llvm-project/clang/test/OpenMP/driver-fopenmp-extensions.c -fno-integrated-as Assembler messages: Error: can't open /tmp/driver-fopenmp-extensions-8fafe8.s for reading: No such file or directory clang-14: error: assembler command failed with exit code 1 (use -v to see invocation) The goal of this test is to verify syntax diags only, so we should use clang_cc1 to test. Reviewed By: jdenny, ABataev Differential Revision: https://reviews.llvm.org/D109255
-
Jonas Devlieghere authored
Follow up to 2cbd3b04 which added support for unnamed images but missed the use case in parse_frames.
-
Louis Dionne authored
Those constructors are very easy to misuse -- one could easily think that the size passed to the constructor is the size of the range to exhibit from the subrange. Instead, it's a size hint and it's UB to get it wrong. Hence, when it's cheap to compute the real size of the range, it's cheap to make sure that the user didn't get it wrong. Differential Revision: https://reviews.llvm.org/D108827
-
Louis Dionne authored
This reverts commit 2fbd254a, which broke the libc++ CI. I'm reverting to get things stable again until we've figured out a way forward. Differential Revision: https://reviews.llvm.org/D108696
-
David Blaikie authored
This does add some extra superfluous whitespace (eg: "int *") intended to make the Simplified Template Names work easier - this makes the DIE-based names match more exactly the clang-generated names, so it's easier to identify cases that don't generate matching names. (arguably we could change clang to skip that whitespace or add some fuzzy matching to accommodate differences in certain whitespace - but this seemed easier and fairly low-impact)
-
Rong Xu authored
Make the dtor virtual to fix the warning.
-
Amy Kwan authored
[libc++][NFC] Mark values in gdb pretty print comparison functions as live to prevent values being optimized out. It appears when testing LLVM 13 on Power, we run into failures with the `libcxx/test/libcxx/gdb/gdb_pretty_printer_test.sh.cpp` test case optimizing values out. Despite some the functions in the test already being marked with optnone, adding the `MarkAsLive()` calls inside of the pretty printer comparison functions resolves the issues of the values being optimized out. This patch aims to address https://llvm.org/PR51675. Differential Revision: https://reviews.llvm.org/D109204
-
Sanjay Patel authored
This generalizes the examples shown in: https://llvm.org/PR51566 https://alive2.llvm.org/ce/z/V-sEy9
-
Sanjay Patel authored
-
Sanjay Patel authored
-
David Spickett authored
We've been seeing this test return 31 instead of 32 for the "functions" line in this test on our AArch64 bots. One possible cause is some of the children not finishing in time before the llvm-profdata commands are run, if the machine is heavily loaded. Wait for all the children to finish before exiting the parent. Reviewed By: zequanwu Differential Revision: https://reviews.llvm.org/D109222
-
Matheus Izvekov authored
See PR51708. Attempting copy elision in dependent contexts with invalid variable, such as a variable with incomplete type, would cause a crash when attempting to calculate it's alignment. The fix is to just skip this optimization on invalid VarDecl, as otherwise this provides no benefit to error recovery: This functionality does not try to diagnose anything, it only calculates a flag which will affect where the variable will be allocated during codegen. Signed-off-by:
Matheus Izvekov <mizvekov@gmail.com> Reviewed By: rtrieu Differential Revision: https://reviews.llvm.org/D109191
-
Stanislav Mekhanoshin authored
-
Louis Dionne authored
_LIBCPP_HAS_NO_LONG_LONG was only defined on FreeBSD. Instead, use the using_if_exists attribute to skip over declarations that are not available on the base system. Note that there's an annoying limitation that we can't conditionally define a function based on whether the base system provides a function, so for example we still need preprocessor logic to define the abs() and div() overloads. Differential Revision: https://reviews.llvm.org/D108630
-
Louis Dionne authored
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97675 has now been resolved in GCC 11, so we can remove those workarounds. Differential Revision: https://reviews.llvm.org/D109188
-
David Green authored
As an extension to D107866, this adds store(fptosisat(..)) patterns, similar to the existing fptosi patterns, to prevent unnecessarily moving into gpr regs where we can use fp stores directly. Differential Revision: https://reviews.llvm.org/D108378
-
Nico Weber authored
Ran `git ls-files '*.gn' '*.gni' | xargs llvm/utils/gn/gn.py format`.
-
Jinsong Ji authored
The file is requiring x86, but using llc without triple. This will cause problem on non-x86 platforms, as the default triple will not be x86. eg: On PowerPC le, it will emit warnings as: 'x86-64' is not a recognized processor for this target (ignoring processor) '+cx8' is not a recognized feature for this target (ignoring feature) '+fxsr' is not a recognized feature for this target (ignoring feature) '+mmx' is not a recognized feature for this target (ignoring feature) '+sse' is not a recognized feature for this target (ignoring feature) .. On some other platform, it may even crash -- if some of the feature are with same name (eg: soft-float). Add the triple as this was the intention test target.
-
Alexandre Rames authored
Per the comments, `hash_code` values "are not stable to save or persist", so are unsuitable for the module hash, which must persist across compilations for the implicit module hashes to match. Note that in practice, today, `hash_code` are stable. But this is an implementation detail, with a clear `FIXME` indicating we should switch to a per-execution seed. The stability of `MD5` also allows modules cross-compilation use-cases. The `size_t` underlying storage for `hash_code` varying across platforms could cause mismatching hashes when cross-compiling from a 64bit target to a 32bit target. Note that native endianness is still used for the hash computation. So hashes will differ between platforms of different endianness. Reviewed By: jansvoboda11 Differential Revision: https://reviews.llvm.org/D102943
-
Peter Klausler authored
Move the closure of the subset of flang/runtime/*.h header files that are referenced by source files outside flang/runtime (apart from unit tests) into a new directory (flang/include/flang/Runtime) so that relative include paths into ../runtime need not be used. flang/runtime/pgmath.h.inc is moved to flang/include/flang/Evaluate; it's not used by the runtime. Differential Revision: https://reviews.llvm.org/D109107
-