- Mar 28, 2021
-
-
Aaron Puchert authored
Currently we want to allow calling non-const methods even when only a shared lock is held, because -Wthread-safety-reference is already quite sensitive and not all code is const-correct. Even if it is, this might require users to add std::as_const around the implicit object argument. See D52395 for a discussion. Fixes PR46963.
-
Florian Hahn authored
-
Florian Hahn authored
Mark a few methods as const, as they do not modify any state.
-
Alex Reinking authored
Use the CMake 3.13 features of CMakeConfigPackageHelpers to generate LLVMConfigVersion.cmake with proper architecture detection, major+minor version matching, etc. Differential Revision: https://reviews.llvm.org/D99451
-
Fangrui Song authored
-
KareemErgawy-TomTom authored
This patch folds the following pattern: ``` %arg0 = ... %0 = zexti %arg0 : i1 to i8 %1 = trunci %0 : i8 to i1 ``` into just `%arg0`. Reviewed By: mehdi_amini Differential Revision: https://reviews.llvm.org/D99453
-
Nico Weber authored
-
Jan Svoboda authored
This patch enables cc1 argument round-trip for assert builds. It can be disabled by building clang with `-DCLANG_ROUND_TRIP_CC1_ARGS=OFF`. This will be committed only if we reach consensus in https://lists.llvm.org/pipermail/cfe-dev/2021-February/067714.html. Reviewed By: dexonsmith Differential Revision: https://reviews.llvm.org/D97462
-
- Mar 27, 2021
-
-
Simon Pilgrim authored
Remove VBROADCAST/MOVDDUP/splat-shuffle handling from foldShuffleOfHorizOp This can all be handled by canonicalizeShuffleMaskWithHorizOp along as we check that the HADD/SUB are only used once (to prevent infinite loops on slow-horizop targets which will try to reuse the nodes again followed by a post-hop shuffle).
-
Joel E. Denny authored
For example, <https://lab.llvm.org/buildbot/#/builders/132/builds/3929> has this diagnostic: ``` /opt/gcc/9.3.0/snos/include/g++/bits/stl_tree.h:780:8: error: static assertion failed: comparison object must be invocable as const 780 | is_invocable_v<const _Compare&, const _Key&, const _Key&>, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ```
-
Joel E. Denny authored
In input dump annotations, `check:2'1` indicates diagnostic 1 for the `CHECK` directive on check file line 2. Without this patch, `-dump-input` computes the diagnostic index with the assumption that FileCheck *consecutively* produces all diagnostics for the same pattern. Already, that can be a false assumption, as in the examples below. Moreover, it seems like a brittle assumption as FileCheck evolves. Finally, it actually complicates the implementation even if it makes it slightly more efficient. This patch avoids that assumption. Examples below show results after applying this patch. Before applying this patch, `'N` is omitted throughout these examples because the implementation doesn't notice there's more than one diagnostic per pattern. First, `CHECK-LABEL` violates the assumption because `CHECK-LABEL` tries to match twice, and other directives can match in between: ``` $ cat check CHECK: foobar CHECK-LABEL: foobar $ FileCheck -vv check < input |& tail -8 <<<<<< 1: text 2: foobar label:2'0 ^~~~~~ check:1 ^~~~~~ label:2'1 X error: no match found 3: text >>>>>> ``` Second, `--implicit-check-not` is obviously processed many times among other directives: ``` $ cat check CHECK: foo CHECK: foo $ FileCheck -vv -dump-input=always -implicit-check-not=foo \ check < input |& tail -16 <<<<<< 1: text not:imp1'0 X~~~~ 2: foo check:1 ^~~ not:imp1'1 X 3: text not:imp1'1 ~~~~~ 4: foo check:2 ^~~ not:imp1'2 X 5: text not:imp1'2 ~~~~~ 6: eof:2 ^ >>>>>> ``` Reviewed By: thopre, jhenderson Differential Revision: https://reviews.llvm.org/D97813 -
Nikita Popov authored
While explicit sext instructions were handled correctly, the implicit sext that occurs if the offset is smaller than the pointer size blindly assumed that sext(X * Scale + Offset) is the same as sext(X) * Scale + Offset, which is obviously not correct. Fix this by extracting the code that handles linear expression extension and reusing it for the implicit sext as well.
-
Nikita Popov authored
A number of variables need to be correctly initialized on entry to GetLinearExpression() for the implementation to behave reasonably. The fact that SExtBits can currenlty be non-zero on entry is a bug, as demonstrated by the added test: For implicit sexts by the GEP, we do currently skip legality checks.
-
Nikita Popov authored
Currently, we'd produce an incorrect decomposition, because we already recursively called GetLinearExpression(), so the Scale=1, Offset=0 will not necessarily be relative to the shl itself. Now, this doesn't actually matter for functional correctness, because such a shift is poison anyway, so its okay to return an incorrect decomposition. It's still unnecessarily confusing though, and we can easily avoid this by checking the bitwidth earlier.
-
Nikita Popov authored
Nowrap flags between mul and shl differ in that mul nsw allows multiplication of 1 * INT_MIN, while shl nsw does not. This means that it is always fine to transfer shl nowrap flags to muls, but not necessarily the other way around. In this case the NUW/NSW results refer to mul/add operations, so it's fine to retain the flags from the shl.
-
Simon Pilgrim authored
See if the combined shuffle mask is equivalent to an identity shuffle, typically this is due to repeated LHS/RHS ops in horiz-ops, but isTargetShuffleEquivalent might see other patterns as well. This is another small step towards getting rid of foldShuffleOfHorizOp and relying on canonicalizeShuffleMaskWithHorizOp and generic shuffle combining.
-
Juneyoung Lee authored
This is a small patch to make FoldBranchToCommonDest poison-safe by default. After fc3f0c9c, only two syntactic changes are needed to fix unit tests. This does not cause any assembly difference in testsuite as well (-O3, X86-64 Manjaro). Reviewed By: nikic Differential Revision: https://reviews.llvm.org/D99452
-
Sanjay Patel authored
This could crash in 2 ways: either one or both of the input vectors could be a different size than the math ops. https://llvm.org/PR49716
-
Alex Zinenko authored
Provide a registration mechanism for Linalg dialect-specific passes in C API and Python bindings. These are being built into the dialect library but exposed in separate headers (C) or modules (Python). Differential Revision: https://reviews.llvm.org/D99431
-
Juneyoung Lee authored
This is a minor fix to use m_LogicalAnd. This allows IRCE to recognize select form of and conditions as well.
-
Fangrui Song authored
sanitizer-ppc64le-linux is good while clang-ppc64le-linux has test failures due to GetStaticTlsRange(addr, size) set *addr is 0.
-
Jonas Devlieghere authored
Older watchOS SDKs *only* support i386 so we can't use x86_64/arm64 unconditionally.
-
George Burgess IV authored
This adds me as a Google representative for the LLVM security group. This was proposed, discussed, and voted on in the differential revision linked below; please see it for more information. Differential Revision: https://reviews.llvm.org/D99232
-
Jonas Devlieghere authored
This keeps breaking on my machine. It's time to move on.
-
Craig Topper authored
It's unlikely that FMADD and FMSUB would have different scheduling information so merge them. Reviewed By: HsiangKai Differential Revision: https://reviews.llvm.org/D99140
-
Hongtao Yu authored
During context promotion, intermediate nodes that are on a call path but do not come with a profile can be promoted together with their parent nodes. Do not print sample context string for such nodes since they do not have profile. Reviewed By: wenlei Differential Revision: https://reviews.llvm.org/D99441
-
Joseph Huber authored
Summary: If the call to `synchronize` fails, it will currently block the stream indefinitely if execution is continued from this point. Additionally, if the program exits it will trigger an assertion on the non-null value of the async queue and prevent the runtime from printing debugging information. Reviewers: jdoerfert Differential Revision: https://reviews.llvm.org/D99443
-
Jacques Pienaar authored
Now that NoTerminator is possible this op can be removed/it was only needed structurally before. NFC.
-
Jonas Devlieghere authored
Remove UpdateISAToDescriptorMapFromMemory because it's dead code.
-
Chris Lattner authored
-
Jonas Devlieghere authored
This adds the consistency I promised in D99315 between how we read the class info from the Objective-C runtime and the shared cache. (NFC) Differential revision: https://reviews.llvm.org/D99446
-
Jez Ng authored
The test is similar to the one used for LLD-ELF. Differential Revision: https://reviews.llvm.org/D99318
-
Jez Ng authored
Summary: We needed to use `Joined` instead of `Flag`. This wasn't caught because the relevant test that was copied from LLD-ELF was still invoking LLD-ELF instead of LLD-MachO... Differential Revision: https://reviews.llvm.org/D99313
-
Jez Ng authored
Pretty simple code-wise. Also threw in some refactoring: * Put the functionStartSection under Writer instead of InStruct, since it doesn't need to be accessed outside of Writer * Adjusted the test to put all files under the temp dir instead of at the top-level * Added some CHECK-LABELs to make it clearer where the function starts data is Differential Revision: https://reviews.llvm.org/D99112
-
Craig Topper authored
I've used IALU for the simplest operations from Zbb: min, minu, max, maxu, sext.b, sext.h, zext.h, andn, orn, xnor I've put add.uw in IALU32 and slli.uw in ShiftImm32. Remaining instructions have received new classes. All 3 sh*add are grouped together. sh*add.uw are grouped together. Rotate left and right are together. Everything else got their own class containing one instruction. I think what I have here is the minimum granularity we need. I could be convinced that we need more classes. Reviewed By: evandro Differential Revision: https://reviews.llvm.org/D99040
-
Josh Berdine authored
Followup to: 0b1dc49c [NFC][OCaml] Resolve const and unsigned compilation warnings Differential Revision: https://reviews.llvm.org/D99420
-
Sean Perry authored
The contents of the string returned by getenv() is not guaranteed across calls to getenv(). The code to handle the CC_PRINT etc env vars calls getenv() and saves the results in just a char *. The string returned by getenv() needs to be copied and saved. Switching the type of the strings from char * to std::string will do this and manage the alloated memory. Differential Revision: https://reviews.llvm.org/D98554
-
Nikita Popov authored
This reverts commit 166620a4. A miscompile has been reported in https://reviews.llvm.org/D93927#2653480 and following.
-
Jonas Devlieghere authored
Generic classes in Swift have their name instantiated on request, since the vast majority never need it, and it just wastes time and memory. This results in LLDB being unable to determine the dynamic type of these Swift objects. The main issues is that lazily named classes are not added to the gdb_objc_realized_classes hashtable. This means the class count in the table doesn't change when a class is realized and LLDB doesn't know it needs to re-parse the class info. But even if it did, the classes are not in the hash table. The first change in this patch is that we read objc_debug_realized_class_generation_count and re-parse the class info when the count changes. The second change in this patch is that we use objc_copyRealizedClassList (if available) to get all realized classes from the runtime. Unfortunately, objc_copyRealizedClassList calls _dyld_objc_class_count in its implementation. As we know, the Objective-C parsing code might get called before dyld is fully initialized, resulting in crashes or even a stranded lock. Therefore we only use objc_copyRealizedClassList when we know it's safe to do so by checking libSystemInitialized in dyld_all_image_infos. As a result, it's possible that the first time we read the Objective-C runtime we are forced to use gdb_objc_realized_classes. This should be fine, as there should be no lazily named classes at this point. Subsequent queries will detect the change in realized class generation count and use objc_copyRealizedClassList. This patch keeps the old behavior when objc_copyRealizedClassList or objc_debug_realized_class_generation_count are not available. Differential revision: https://reviews.llvm.org/D99315
-
Petr Hosek authored
Rather than including libc++ include dir, use the cxx-headers target. Differential Revision: https://reviews.llvm.org/D98367
-