- Oct 13, 2018
-
-
Simon Pilgrim authored
This patch changes the vector CTTZ lowering from: cttz(x) = ctpop((x & -x) - 1) to: cttz(x) = ctpop(~x & (x - 1)) Not only does this make better use of the PANDN instruction, but it also matches the LegalizeDAG method which should allow us to remove the x86 specific code at some point in the future (we need to fix some issues with the bitcasted logic ops and CTPOP lowering first). Differential Revision: https://reviews.llvm.org/D53214 llvm-svn: 344447
-
Simon Pilgrim authored
Add shuffle lowering for the case where we can shuffle the lanes into place followed by an in-lane permute. This is mainly for cases where we can have non-repeating permutes in each lane, but for now I've just enabled it for v4f64 unary shuffles to fix PR39161 - there is no test coverage for other shuffles that might benefit yet. We now have several cross-lane shuffle lowering methods that all do something similar - I've looked at merging some of these (notably by making the repeated mask mechanism in lowerVectorShuffleByMerging128BitLanes optional), but there is a lot of assertions/assumptions in the way that makes this tricky - I ended up going for adding yet another relatively simple method instead. Differential Revision: https://reviews.llvm.org/D53148 llvm-svn: 344446
-
Adam Balogh authored
llvm-svn: 344445
-
Adam Balogh authored
Checking whether a functions throws indirectly may be very expensive because it needs to visit its whole call graph. Therefore we should first check whether the function is forbidden to throw and only check whether it throws afterward. This also seems to solve bug https://bugs.llvm.org/show_bug.cgi?id=39167 where the execution time is so long that it seems to hang. Differential Revision: https://reviews.llvm.org/D53187 llvm-svn: 344444
-
Adam Balogh authored
In earlier Clang Static Analyzer versions `check::Bind() was not invoked for parameter passing, so we needed a trick which is not needed anymore. However add the tests to ensure its working. Differential Revision: https::/reviews.llvm.org/D32906 llvm-svn: 344443
-
Jonas Toth authored
Revert "[clang-tidy] New checker for not null-terminated result caused by strlen(), size() or equal length" This reverts commit r344374. llvm-svn: 344442
-
Jonas Toth authored
This reverts commit r344379. llvm-svn: 344441
-
Miklos Vajna authored
And also enable it by default to be consistent with e.g. modernize-use-using. This improves consistency inside the check itself as well: both checks are now disabled in macros by default. This helps e.g. when running this check on client code where the macro is provided by the system, so there is no easy way to modify it. Reviewed By: alexfh Differential Revision: https://reviews.llvm.org/D53217 llvm-svn: 344440
-
Arnaud A. de Grandmaison authored
Summary: AArch64 can fold some shift+extend operations on the RHS operand of comparisons, so swap the operands if that makes sense. This provides a fix for https://bugs.llvm.org/show_bug.cgi?id=38751 Reviewers: efriedma, t.p.northover, javed.absar Subscribers: mcrosier, kristof.beyls, llvm-commits Differential Revision: https://reviews.llvm.org/D53067 llvm-svn: 344439
-
Thomas Lively authored
Summary: Depends on D52324 and D52764. Reviewers: aheejin, dschuff Subscribers: sbc100, jgravelle-google, sunfish, llvm-commits Differential Revision: https://reviews.llvm.org/D52325 llvm-svn: 344438
-
Thomas Lively authored
Summary: These new intrinsics have the semantics of the `minimum` and `maximum` operations specified by the latest draft of IEEE 754-2018. Unlike llvm.minnum and llvm.maxnum, these new intrinsics propagate NaNs and always treat -0.0 as less than 0.0. `minimum` and `maximum` lower directly to the existing `fminnan` and `fmaxnan` ISel DAG nodes. It is safe to reuse these DAG nodes because before this patch were only emitted in situations where there were known to be no NaN arguments or where NaN propagation was correct and there were known to be no zero arguments. I know of only four backends that lower fminnan and fmaxnan: WebAssembly, ARM, AArch64, and SystemZ, and each of these lowers fminnan and fmaxnan to instructions that are compatible with the IEEE 754-2018 semantics. Reviewers: aheejin, dschuff, sunfish, javed.absar Subscribers: kristof.beyls, dexonsmith, kristina, llvm-commits Differential Revision: https://reviews.llvm.org/D52764 llvm-svn: 344437
-
Thomas Lively authored
Reviewers: aheejin, dschuff Subscribers: sbc100, jgravelle-google, sunfish, llvm-commits Differential Revision: https://reviews.llvm.org/D53172 llvm-svn: 344436
-
Dan Liew authored
Summary: The previous value looks Linux specific so that has been guarded with the host OS being Linux. On Apple platforms `%shared_libasan` expands to the absolute path of the ASan dylib. Previously on Linux `%shared_libasan` expanded to just the file name of the shared library rather than the absolute path to the library. This is likely a bug because it would rely on the OS's dynamic linker to find the shared library which could accidentally pick up a system copy rather than the shared library that was just built. For other platforms we emit a warning if `config.asan_dynamic` is true. This patch also only defines the substitution when `config.asan_dynamic` is true because using this substitution only makes sense when the dynamic library is available. Reviewers: kubamracek, george.karpenkov, mgorny, phosek, etienneb, samsonov, kcc Subscribers: #sanitizers, llvm-commits Differential Revision: https://reviews.llvm.org/D53111 llvm-svn: 344434
-
Kostya Serebryany authored
Summary: GetOrCreateFunctionComdat is currently used in SanitizerCoverage, where it's defined. I'm planing to use it in HWASAN as well, so moving it into a common location. NFC Reviewers: morehouse Reviewed By: morehouse Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D53218 llvm-svn: 344433
-
Alex Bradbury authored
SelectionDAGBuilder::visitShift will always zero-extend a shift amount when it is promoted to the ShiftAmountTy. This results in zero-extension (masking) which is unnecessary for RISC-V as the shift operations only read the lower 5 or 6 bits (RV32 or RV64). I initially proposed adding a getExtendForShiftAmount hook so the shift amount can be any-extended (D52975). @efriedma explained this was unsafe, so I have instead eliminate the unnecessary and operations at instruction selection time in a manner similar to X86InstrCompiler.td. Differential Revision: https://reviews.llvm.org/D53224 llvm-svn: 344432
-
Zachary Turner authored
llvm-svn: 344431
-
Fangrui Song authored
.note.llvm.cgprofile was an obvious typo in rL333823 llvm-svn: 344430
-
Zachary Turner authored
This adds -- before any filenames, so that /U doesn't get interpreted as a command line. It also adds better error checking, so that we don't get assertions on the failure path when a file fails to parse as a PDB. llvm-svn: 344429
-
Craig Topper authored
There's no guarantee that vector indices should use pointer types. So use the correct query method. llvm-svn: 344428
-
Rui Ueyama authored
- Removed redundant `llvm::` - Typedef a long type name - Initialize members by member initializers llvm-svn: 344427
-
Evgeniy Stepanov authored
Fix line splitting logic to avoid sending empty lines to syslog, as that adds extra newlines. llvm-svn: 344426
-
Craig Topper authored
[X86] Improve type legalization of (v2i32/v4i16/v8i16 (bitcast (v2f32))) to avoid a stack stack temporary. llvm-svn: 344425
-
Craig Topper authored
[X86] Simplify the end of custom type legalization for (v2i32/v4i16/v8i8 (bitcast (f64))) by just emitting an EXTRACT_SUBVECTOR instead of a BUILD_VECTOR. Generic legalization should be able to finish legalizing the EXTRACT_SUBVECTOR probably by turning it into a BUILD_VECTOR. But we should emit the simplest sequence. llvm-svn: 344424
-
- Oct 12, 2018
-
-
Craig Topper authored
[X86] Skip (v2i32/v4i16/v8i8 (bitcast (f64))) handling in ReplaceNodeResults if the dest type can be widened by generic legalization. NFCI The algorithm we would do previously was identical to generic legalization. If we ever switch to legalizing integer vectors via widening we'll be able to kill off the code since it now only runs for promotion. llvm-svn: 344423
-
Craig Topper authored
[LegalizeVectorTypes] When widening the result of a bitcast from a scalar type, use a scalar_to_vector to turn the scalar into a vector intead of a build vector full of mostly undefs. This is more consistent with what we usually do and matches some code X86 custom emits in some cases that I think I can cleanup. The MIPS test change just looks to be an instruction ordering change. llvm-svn: 344422
-
Marshall Clow authored
llvm-svn: 344421
-
Jim Ingham authored
Most of the time SIGPIPE is just annoying, and so we should pass it on silently it by default. <rdar://problem/39359145> llvm-svn: 344418
-
Marshall Clow authored
llvm-svn: 344417
-
Marshall Clow authored
llvm-svn: 344416
-
Samuel Benzaquen authored
Summary: Benchmarks for construct, copy, move, swap, destroy and invoke, with 8 different input states. For the cases that matter, it tests with and without allowing constant value propagation from construction into the operation tested. This also adds helper functions to generate the cartesian product of different configurations and generate benchmarks for all of them. Reviewers: EricWF Subscribers: christof, ldionne, libcxx-commits Differential Revision: https://reviews.llvm.org/D53087 llvm-svn: 344415
-
Jason Molenda authored
llvm-svn: 344414
-
Alexey Bataev authored
Additional reduction of the global memory usage in the target regions without parallel regions. llvm-svn: 344413
-
Martin Storsjö authored
Differential Revision: https://reviews.llvm.org/D53195 llvm-svn: 344412
-
Michal Gorny authored
llvm-svn: 344411
-
Stella Stamenova authored
If the path was not specified (and it's None), lexists throws an exception rather than returning False. get_filecheck_path now checks whether filecheck is set before calling lexists llvm-svn: 344410
-
Zachary Turner authored
This was originally reverted due to some test failures on Linux. Those problems turned out to require several additional patches to lld and clang in order to fix, which have since been submitted. This patch is resubmitted unchanged. All tests now pass on both Linux and Windows. llvm-svn: 344409
-
Simon Pilgrim authored
Windows buildbots are still not happy Now that both issues found out during the last iteration have been fixed, reenable the Python binding tests on buildbots. ........ llvm-svn: 344408
-
Shafik Yaghmour authored
Changing test names in TestDataFormatterLibcxxVariant.py and TestStdFunctionStepIntoCallable.py to be unique, NFC llvm-svn: 344407
-
Ben Hamilton authored
Summary: > clang-format --version > clang-format version 7.0.0 (tags/RELEASE_700/final) > echo "@implementation Foo\n- (void)foo:(id)bar\n{\n}\n@end\n" |clang-format -style='{BreakBeforeBraces: Custom, BraceWrapping: {AfterFunction: true}}' ``` @implementation Foo - (void)foo:(id)bar { } @end ``` with patch: > bin/clang-format --version > clang-format version 8.0.0 (trunk 344285) > echo "@implementation Foo\n- (void)foo:(id)bar\n{\n}\n@end\n" |bin/clang-format -style='{BreakBeforeBraces: Custom, BraceWrapping: {AfterFunction: true}}' ``` @implementation Foo - (void)foo:(id)bar { } @end ``` Contributed by hultman@. Reviewers: benhamilton, jolesiak, klimek, Wizard Reviewed By: benhamilton Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D53197 llvm-svn: 344406
-
Eli Friedman authored
The initial patch was not reviewed, and does not have any tests; it should not have been merged. This reverts 344395, 344390, 344387, 344385, 344381, 344376, and 344366. llvm-svn: 344405
-