- Jun 19, 2020
-
-
Alex Zinenko authored
Existing implementation of affine loop nest builders relies on EDSC ScopedContext, which is not used pervasively. Provide a common OpBuilder-based helper function to construct a perfect nest of affine loops with the body of the innermost loop populated by a callback. Use this function to implement the EDSC version. Affine "for" loops differ from SCF "for" loops by (1) not allowing to yield values and (2) supporting short-hand form for constant bounds, which justifies a separate implementation of the loop nest builder for the same of simplicity. Differential Revision: https://reviews.llvm.org/D81955
-
River Riddle authored
Traditionally patterns have always had the root operation kind hardcoded to a specific operation name. This has worked well for quite some time, but it has certain limitations that make it undesirable. For example, some lowering have the same implementation for many different operations types with a few lowering entire dialects using the same pattern implementation. This problem has led to several "solutions": a) Provide a template implementation to the user so that they can instantiate it for each operation combination, generally requiring the inclusion of the auto-generated operation definition file. b) Use a non-templated pattern that allows for providing the name of the operation to match - No one ever does this, because enumerating operation names can be cumbersome and so this quickly devolves into solution a. This revision removes the restriction that patterns have a hardcoded root type, and allows for a class patterns that could match "any" operation type. The major downside of root-agnostic patterns is that they make certain pattern analyses more difficult, so it is still very highly encouraged that an operation specific pattern be used whenever possible. Differential Revision: https://reviews.llvm.org/D82066
-
River Riddle authored
This class enables for abstracting more of the details for the rewrite process, and will allow for clients to apply specific cost models to the pattern list. This allows for DialectConversion and the GreedyPatternRewriter to share the same underlying matcher implementation. This also simplifies the plumbing necessary to support dynamic patterns. Differential Revision: https://reviews.llvm.org/D81985
-
Shuhong Liu authored
[AIX] Split lit test shtest-format into two separate tests and add AIX as UNSUPPORTED for shtest-format-argv0 Summary: lit test `shtest-format.py` fails on AIX because one of the subtest of shtest-format requires the tool `[` to be installed under the system PATH. For AIX, `[` is only available as a shell builtin and does not present as an executable file under PATH. Hence, split the original shtest-format into two separate test files and added AIX as UNSUPPORTED for the test using `[` . Reviewers: daltenty, hubert.reinterpretcast Reviewed By: hubert.reinterpretcast Subscribers: delcypher, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D82100
-
aartbik authored
Reviewers: ftynse, nicolasvasilache, reidtatge Reviewed By: nicolasvasilache Subscribers: mehdi_amini, rriddle, jpienaar, shauheen, antiagainst, nicolasvasilache, arpith-jacob, mgester, lucyrfox, liufengdb, stephenneuendorffer, Joonsoo, grosul1, Kayjukh, jurahul, msifontes Tags: #mlir Differential Revision: https://reviews.llvm.org/D82117
-
Christopher Tetreault authored
Reviewers: efriedma, c-rhodes, david-arm, Tyker, asbirlea Reviewed By: david-arm Subscribers: tschuett, hiraditya, rkruppe, psnobl, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D82057
-
Yaxun (Sam) Liu authored
Enable -amdgpu-internalize-symbols to eliminate unused functions and global variables for whole program to speed up compilation and improve performance. For -fno-gpu-rdc, -amdgpu-internalize-symbols is passed to clang -cc1. For -fgpu-rdc, -amdgpu-internalize-symbols is passed to lld. Differential Revision: https://reviews.llvm.org/D81959
-
Thomas Raoux authored
This extends the types supported as kernel arguments when using vulkan runner. Differential Revision: https://reviews.llvm.org/D82068
-
Alexandre Ganea authored
[CodeView] Revert 8374bf43 and 403f9537 This reverts: 8374bf43 [CodeView] Fix generated command-line expansion in LF_BUILDINFO. Fix the 'pdb' entry which was previously a null reference, now an empty string. 403f9537 [CodeView] Add full repro to LF_BUILDINFO record This is causing the lld/test/COFF/pdb-relative-source-lines.test to fail: http://lab.llvm.org:8011/builders/lld-x86_64-win/builds/1096/steps/test-check-all/logs/FAIL%3A%20lld%3A%3Apdb-relative-source-lines.test And clang/test/CodeGen/debug-info-codeview-buildinfo.c fails as well: http://lab.llvm.org:8011/builders/clang-s390x-linux/builds/33346/steps/ninja%20check%201/logs/FAIL%3A%20Clang%3A%3Adebug-info-codeview-buildinfo.c
-
Sam Clegg authored
Some projects use the constructor attribute on functions that also return values. In this case we just ignore them. The error was reported in the libgpg-error project that marks gpg_err_init with the `__constructor__` attribute. Differential Revision: https://reviews.llvm.org/D81962
-
Thomas Raoux authored
muladd can have differenti types for lhs/rhs and acc/destination. Change verifier and update the test to use supported example. Differential Revision: https://reviews.llvm.org/D82042
-
Jacques Pienaar authored
If one uses an OpVariable (such as via Res) then the result type constraint should be returned. Differential Revision: https://reviews.llvm.org/D82119
-
Kirill Naumov authored
This functionality is very similar to Function compatibility with AnnotationWriter. This change allows us to use AnnotationWriter with BasicBlock through BB.print() method. Reviewed-By: apilipenko Differntial Revision: https://reviews.llvm.org/D81321
-
Sanjay Patel authored
The predicate can always be used to distinguish between icmp and fcmp, so we don't need to keep repeating this check in the callers.
-
Eric Christopher authored
-
Matt Arsenault authored
This should probably be implied for all the speculatable ones. I think the only ones where this plausibly doesn't apply is s_sendmsghalt and maybe kill.
-
Davide Italiano authored
Sometimes a dead block gets folded and the debug information is still retained. This manifests as jumpy stepping in lldb, see the bugzilla PR for an end-to-end C testcase. Fixes https://bugs.llvm.org/show_bug.cgi?id=46008 Differential Revision: https://reviews.llvm.org/D82062
-
Eduardo Caldas authored
Reviewers: gribozavr2 Reviewed By: gribozavr2 Subscribers: hlopko, gribozavr2, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D81168
-
Christopher Ferris authored
Summary: When enabling some malloc debug features on Android, multiple 32 bit regions become exhausted, and the allocations fail. Allow allocations to keep trying each bigger class in the Primary until it finds a fit. In addition, some Android tests running on 32 bit fail sometimes due to a running out of space in two regions, and then fail the allocation. Reviewers: cryptoad Reviewed By: cryptoad Subscribers: #sanitizers, llvm-commits Tags: #sanitizers Differential Revision: https://reviews.llvm.org/D82070
-
Michael Liao authored
Reviewers: arsenm Subscribers: wdng, hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D82025
-
Louis Dionne authored
Add a simple CMakeLists.txt to build the runtimes in lockstep without building all of LLVM. See [1] for details. [1]: http://lists.llvm.org/pipermail/llvm-dev/2020-June/142384.html
-
peter klausler authored
Summary: Fix build problems encountered on osx in two files. The one in character.cpp fixes a legitimate bug that elicited a valid warning. Reviewers: tskeith, PeteSteinfeld, sscalpone, jdoerfert, DavidTruby Reviewed By: tskeith, PeteSteinfeld Subscribers: llvm-commits, flang-commits Tags: #flang, #llvm Differential Revision: https://reviews.llvm.org/D82107
-
serge-sans-paille authored
Move code that may update the IR after precondition, so that if precondition fail, the IR isn't modified. Differential Revision: https://reviews.llvm.org/D81225
-
Matt Arsenault authored
These don't really modify any memory, and should not expect memory operands.
-
Siva Chandra Reddy authored
Current implementations of single precision and double precision floating point operations operate on bits of the integer type of same size. The code made use of magic masks which were listed as literal integer values. This is not possible in the case of long double type as the mantissa of quad-precision long double type used on non-x86 architectures is wider that the widest integer type for which we can list literal values. So, in this patch, to avoid using magic masks specified with literal values, we use packed bit-field struct types and let the compiler generate the masks. This new scheme allows us to implement long double flavors of the various floating point operations. To keep the size of the patch small, only the implementations of fabs and trunc have been switched to the new scheme. In following patches, all exisiting implementations will be switched to the new scheme. Reviewers: asteinhauser Differential Revision: https://revie...
-
aartbik authored
Summary: The "i1" (viz. bool) type does not have a proper equivalent on the "C" size. So, to avoid any ABIs issues, we simply use print_i32 on an i32 value of one or zero for true and false. This has the added advantage that one less function needs to be implemented when porting the runtime support library. Reviewers: ftynse, bkramer, nicolasvasilache Reviewed By: ftynse Subscribers: mehdi_amini, rriddle, jpienaar, shauheen, antiagainst, nicolasvasilache, arpith-jacob, mgester, lucyrfox, liufengdb, stephenneuendorffer, Joonsoo, grosul1, frgossen, Kayjukh, jurahul, msifontes Tags: #mlir Differential Revision: https://reviews.llvm.org/D82048
-
Martijn Vels authored
Summary: This change adds local 'end' and 'pos' variables for the main loop inmstead of using the ConstructTransaction variables directly. We observed that not all vector initialization and resize operations got properly vectorized, i.e., (partially) unrolled into XMM stores for floats. For example, `vector<int32_t> v(n, 1)` gets vectorized, but `vector<float> v(n, 1)`. It looks like the compiler assumes the state is leaked / aliased in the latter case (unclear how/why for float, but not for int32), and because of this fails to see vectorization optimization? See https://gcc.godbolt.org/z/UWhiie By using a local `__new_end_` (fixed), and local `__pos` (copied into __tx.__pos_ per iteration), we offer the compiler a clean loop for unrolling. A demonstration can be seen in the isolated logic in https://gcc.godbolt.org/z/KoCNWv The com Reviewers: EricWF, #libc! Subscribers: libcxx-commits Tags: #libc Differential Revision: https://reviews.llvm.org/D82111
-
Hanhan Wang authored
Summary: Fixed build of D81618 Add a pattern for expanding tanh op into exp form. A `tanh` is expanded into: 1) 1-exp^{-2x} / 1+exp^{-2x}, if x => 0 2) exp^{2x}-1 / exp^{2x}+1 , if x < 0. Differential Revision: https://reviews.llvm.org/D82040 -
Daniel Grumberg authored
-
Alexey Bataev authored
-
Ties Stuij authored
Summary: As part of moving the argument lowering handling for bfloat arguments and returns to the backend, this patch removes the code that was responsible for handling the coercion of those arguments in Clang's Codegen. Subscribers: kristof.beyls, danielkiss, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D81837
-
Alexey Bataev authored
Summary: Compiler may erroneously treat current context in OpenMP pragmas as the context where new type declaration/definition is allowed. But the declartation/definition of the new types in OpenMP pragmas should not be allowed. Reviewers: jdoerfert Subscribers: yaxunl, guansong, sstefan1, cfe-commits, caomhin Tags: #clang Differential Revision: https://reviews.llvm.org/D82019
-
Hiroshi Yamauchi authored
etc. happens to be in the InstallDir path in the -### output. Differential Revision: https://reviews.llvm.org/D82046
-
Stanislav Mekhanoshin authored
Nothing breaks yet, but all encodings shall be in the map. Differential Revision: https://reviews.llvm.org/D81974
-
Alex Richardson authored
When testing libc++ for our cross-compiled CheriBSD target we specify an explicit LIBCXX_CXX_ABI_INCLUDE_PATHS for libcxxrt. The hardcoded path /usr/include/c++/v1 was introduced in 61e89737 and overrides any value passed on the CMake command line. Fix this by using it as a fallback rather than a fixed default value. Reviewed By: #libc, ldionne Differential Revision: https://reviews.llvm.org/D82095
-
Alex Richardson authored
Previously the script only handled C input, this change extends the JSON parsing to to also include C++ function types such as methods, constructors and destructors. Reviewed By: MaskRay Differential Revision: https://reviews.llvm.org/D80914
-
Alex Richardson authored
Function declarations can in fact have an 'inner' node that lists the ParmVarDecls. It seems like either the JSON output has changed or that I tested the original JSON parsing change with test files that only have function definitions without arguments. Reviewed By: MaskRay Differential Revision: https://reviews.llvm.org/D80913
-
Cullen Rhodes authored
Highlight the `bfloat` type introduced in D78190.
-
Arthur Eubanks authored
When possible (e.g. internal linkage), strip preallocated attribute off parameters/arguments. This requires removing the "preallocated" operand bundle from the call site, replacing @llvm.call.preallocated.arg() with an alloca and a bitcast to i8*, and removing the @llvm.call.preallocated.setup(). Since @llvm.call.preallocated.arg() can be called multiple times with the same arg index, we create an alloca per arg index. We add a @llvm.stacksave() where the @llvm.call.preallocated.setup() was and a @llvm.stackrestore() after the preallocated call to prevent the stack from blowing up. This is valid because the argument would normally not exist on the stack after the call before the transformation. This does not currently handle all possible preallocated calls. We will need to figure out where to put @llvm.stackrestore() in the cases where there is no obvious place to put it, for example conditional preallocated calls, invokes. This sort of transformation may need to be moved to somewhere more accessible to accomodate similar transformations (like inlining) in the future. Reviewers: efriedma, hans Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D80951
-
Francesco Petrogalli authored
Summary: The new SVE builtin type __SVBFloat16_t` is used to represent scalable vectors of bfloat elements. Reviewers: sdesmalen, efriedma, stuij, ctetreau, shafik, rengolin Subscribers: tschuett, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D81304
-