- Feb 28, 2020
-
-
Stephen Neuendorffer authored
Previously, lib/Support/JitRunner.cpp was essentially a complete application, performing all library initialization, along with dealing with command line arguments and actually running passes. This differs significantly from mlir-opt and required a dependency on InitAllDialects.h. This dependency is significant, since it requires a dependency on all of the resulting libraries. This patch refactors the code so that tools are responsible for library initialization, including registering all dialects, prior to calling JitRunnerMain. This places the concern about what dialect to support with the end application, enabling more extensibility at the cost of a small amount of code duplication between tools. It also fixes BUILD_SHARED_LIBS=on. Differential Revision: https://reviews.llvm.org/D75272
-
Stephen Neuendorffer authored
Collect a list of conversion libraries in cmake, so we don't have to list these explicitly in most binaries. Differential Revision: https://reviews.llvm.org/D75222
-
Stephen Neuendorffer authored
Instead of creating extra libraries we don't really need, collect a list of all dialects and use that instead. Differential Revision: https://reviews.llvm.org/D75221
-
Jacques Pienaar authored
-
Benjamin Kramer authored
This matches loops with a affine.min upper bound, limiting the trip count to a constant, and rewrites them into two loops, one with constant upper bound and one with variable upper bound. The assumption is that the constant upper bound loop will be unrolled and vectorized, which is preferable if this is the hot path. Differential Revision: https://reviews.llvm.org/D75240
-
Yitzhak Mandelbaum authored
[AST Matchers] Fix bug in 'optionally' matcher wherein all previous bindings are cleared when all inner matchers fail. Summary: The implementation of 'optionally' doesn't preserve bindings when none of the submatchers succeed. This patch adds a regression test for that behavior and fixes it. Reviewers: aaron.ballman, sbenza Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D75365
-
David Green authored
The alias analysis in DAG Combine looks at the BaseAlign, the Offset and the Size of two accesses, and determines if they are known to access different parts of memory by the fact that they are different offsets from inside that "alignment window". It does not seem to account for accesses that are not a multiple of the size, and may overflow from one alignment window into another. For example in the test case we have a 19byte memset that is splits into a 16 byte neon store and an unaligned 4 byte store with a 15 byte offset. This 15byte offset (with a base align of 8) wraps around to the next alignment windows. When compared to an access that is a 16byte offset (of the same 4byte size and 8byte basealign), the two accesses are said not to alias. I've fixed this here by just ensuring that the offsets are a multiple of the size, ensuring that they don't overlap by wrapping. Fixes PR45035, which was exposed by the UseAA changes in the arm backend. Differential Revision: https://reviews.llvm.org/D75238
-
Austin Kerbow authored
Extract index could be a differnet integral type. Differential Revision: https://reviews.llvm.org/D75327
-
Eric Fiselier authored
-
Valery N Dmitriev authored
This change adds an assertion to prevent tricky bug related to recursive approach of building vectorization tree. For loop below takes number of operands directly from tree entry rather than from scalars. If the entry at this moment turns out incomplete (i.e. not all operands set) then not all the dependencies will be seen by the scheduler. This can lead to failed scheduling (and thus failed vectorization) for perfectly vectorizable tree. Here is code example which is likely to fire the assertion: for (i : VL0->getNumOperands()) { ... TE->setOperand(i, Operands); buildTree_rec(Operands, Depth + 1,...); } Correct way is two steps process: first set all operands to a tree entry and then recursively process each operand. Differential Revision: https://reviews.llvm.org/D75296
-
Alexey Bataev authored
-
Craig Topper authored
This should avoid scalarizing the cvtph2ps intrinsics with D75162 Differential Revision: https://reviews.llvm.org/D75304
-
Sam Clegg authored
When there are both strong and weak references to an undefined symbol ensure that the strong reference prevails in the output symbol generating the correct error. Test case copied from lld/test/ELF/weak-and-strong-undef.s Differential Revision: https://reviews.llvm.org/D75322
-
Hiroshi Yamauchi authored
Devirtualize a call on alloca without waiting for post inline cleanup and next DevirtSCCRepeatedPass iteration. This aims to fix a missed inlining case. If there's a virtual call in the callee on an alloca (stack allocated object) in the caller, and the callee is inlined into the caller, the post-inline cleanup would devirtualize the virtual call, but if the next iteration of DevirtSCCRepeatedPass doesn't happen (under the new pass manager), which is based on a heuristic to determine whether to reiterate, we may miss inlining the devirtualized call. This enables inlining in clang/test/CodeGenCXX/member-function-pointer-calls.cpp. This is a second commit after a revert https://reviews.llvm.org/rG4569b3a86f8a4b1b8ad28fe2321f936f9d7ffd43 and a fix https://reviews.llvm.org/rG41e06ae7ba91. Differential Revision: https://reviews.llvm.org/D69591
-
Hiroshi Yamauchi authored
Summary: This fixes the crash that led to the revert of D69591. Reviewers: davidxl Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D75307
-
Valery N Dmitriev authored
This patch deletes some dead code out of SLP vectorizer. Couple of changes taken out of D57059 to slightly lighten it plus one more similar case fixed. Differential Revision: https://reviews.llvm.org/D75276
-
Christopher Tetreault authored
Summary: There exists no corresponding code change for this commit, and this commit causes downstream breakages. This reverts commit 2db5547c. Reviewers: samparker Subscribers: kristof.beyls, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D75358
-
aartbik authored
Reviewers: nicolasvasilache, andydavis1 Reviewed By: nicolasvasilache Subscribers: mehdi_amini, rriddle, jpienaar, burmako, shauheen, antiagainst, nicolasvasilache, arpith-jacob, mgester, lucyrfox, liufengdb, Joonsoo, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D75320
-
Simon Pilgrim authored
As suggested on D75162
-
Simon Pilgrim authored
As suggested on D75162
-
Jacques Pienaar authored
This call results in inserting operations that compute the return shape dynamically for the operation.
-
Teresa Johnson authored
Summary: Final patch in series to fix inlining between functions with different nobuiltin attributes/options, which was specifically an issue in LTO. See discussion on D61634 for background. The prior patch in this series (D67923) enabled per-Function TLI construction that identified the nobuiltin attributes. Here I have allowed inlining to proceed if the callee's nobuiltins are a subset of the caller's nobuiltins, but not in the reverse case, which should be conservatively correct. This is controlled by a new option, -inline-caller-superset-nobuiltin, which is enabled by default. Reviewers: hfinkel, gchatelet, chandlerc, davidxl Subscribers: arsenm, jvesely, nhaehnle, mehdi_amini, eraman, hiraditya, haicheng, dexonsmith, kerbowa, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D74162
-
Simon Pilgrim authored
-
Simon Pilgrim authored
We can only report the knownbits for a SCALAR_TO_VECTOR node if we only demand the 0'th element - the upper elements are undefined and shouldn't be trusted. This is causing a number of regressions that need addressing but we need to get the bugfix in first.
-
Pierre-vh authored
Fix for https://bugs.llvm.org/show_bug.cgi?id=37967 Differential Revision: https://reviews.llvm.org/D75173
-
Krzysztof Parzyszek authored
In some cases when HexagonTargetLowering::allowsMemoryAccess returned true, it did not set the "Fast" argument, leaving it uninitialized. [Hexagon] Improve casting of boolean HVX vectors to scalars - Mark memory access for bool vectors as disallowed in target lowering. This will prevent combining bitcasts of bool vectors with stores. - Replace the actual bitcasting code with a faster version. - Handle casting of v16i1 to i16.
-
David Green authored
This addes extra patterns for the VMLAS MVE instruction, which performs Qda = Qda * Qn + Rm, a similar pattern to the existing VMLA. The sinking of splat(Rm) into the loop is already performed, meaning we just need extra Pat's in tablegen. Differential Revision: https://reviews.llvm.org/D75115
-
David Green authored
-
Karasev Nikita authored
Existing 'modernize-pass-by-value' check works only with non template values in initializers. Fixes PR37210.
-
Simon Pilgrim authored
This shouldn't be relevant now that we just support VS2017+.
-
Jay Foad authored
-
Jay Foad authored
-
Jay Foad authored
-
Alexey Lapshin authored
Removed unused function getSectionByName() from dsymutil/DwarfStreamer.cpp.
-
Nathan James authored
Summary: Motivated by [[ https://bugs.llvm.org/show_bug.cgi?id=45045 | Tune inspections to a specific C++ standard. ]] Moves the isLanguageVersionSupported virtual function from `MakeSmartPtrCheck` to the base `ClangTidyCheck` class. This will disable registering matchers or pp callbacks on unsupported language versions for a check. Having it as a standalone function is cleaner than manually disabling the check in the register function and should hopefully encourage check developers to actually restrict the check based on language version. As an added bonus this could enable automatic detection of what language version a check runs on for the purpose of documentation generation Reviewers: aaron.ballman, gribozavr2, Eugene.Zelenko, JonasToth, alexfh, hokein Reviewed By: gribozavr2 Subscribers: xazax.hun, jkorous, arphaman, kadircet, usaxena95, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D75289
-
Jonathan Coe authored
Reviewers: MyDeveloperDay, krasimir Reviewed By: krasimir Subscribers: cfe-commits Tags: #clang-format, #clang Differential Revision: https://reviews.llvm.org/D75336
-
Simon Cook authored
When running under LTO, it is common to not specify the architecture spec, which is used for setting up the target machine, and instead rely on features specified in each function to generate the correct instructions. This works for the code generator, but the RISC-V backend uses the AsmPrinter to do instruction compression, which does not see these features but instead uses a MCSubtargetInfo object to see whether compression is enabled. Since this is configured based on the TargetMachine at startup, it will result in compressed instructions not being emitted when it has not been given the 'c' TargetFeature, but the function has it. This changes the RISCVAsmPrinter to re-initialize the STI feature set based on the current MachineFunction, such that compressed instructions are now correctly emitted regardless of the method used to enable them. Differential revision: https://reviews.llvm.org/D73339
-
LLVM GN Syncbot authored
-
Peter Smith authored
Fix buildbots that don't build ARM backend.
-
Jeremy Morse authored
Way back in D24994, the combination of LexicalScopes::dominates and LiveDebugValues was identified as having worst-case quadratic complexity, but it wasn't triggered by any code path at the time. I've since run into a scenario where this occurs, in a very large basic block where large numbers of inlined DBG_VALUEs are present. The quadratic-ness comes from LiveDebugValues::join calling "dominates" on every variable location, and LexicalScopes::dominates potentially touching every instruction in a block to test for the presence of a scope. We have, however, already computed the presence of scopes in blocks, in the "InstrRanges" of each scope. This patch switches the dominates method to examine whether a block is present in a scope's InsnRanges, avoiding walking through the whole block. At the same time, fix getMachineBasicBlocks to account for the fact that InsnRanges can cover multiple blocks, and add some unit tests, as Lexical Scopes didn't have any. Differential revision: https://reviews.llvm.org/D73725
-