- Sep 06, 2021
-
-
Fangrui Song authored
-
guopeilin authored
Currently, we use SExtValue to decide whether to invert tbz or tbnz. However, for the case zext (xor x, c), we should use ZExt rather than SExt otherwise we will generate totally opposite branches. Reviewed By: paquette Differential Revision: https://reviews.llvm.org/D108755
-
LLVM GN Syncbot authored
-
Ruslan Arutyunyan authored
Implementation of `three_way_comparable` and `three_way_comparable_with` concepts from <compare> header. Please note that I have temporarily removed `<compare>` header from `<utility>` due to cyclic dependency that prevents using `<concepts>` header in `<compare>` one. I tried to quickly resolve those issues including applying suggestions from @cjdb and dive deeper by myself but the problem seems more complicated that we thought initially. I am in progress to prepare the patch with resolving this cyclic dependency between headers but for now I decided to put all that I have to the review to unblock people that depend on that functionality. At first glance the patch with resolving cyclic dependency is not so small (unless I find the way to make it smaller and cleaner) so I don't want to mix everything to one review. Reviewed By: ldionne, cjdb, #libc, Quuxplusone Differential Revision: https://reviews.llvm.org/D103478
-
Benjamin Kramer authored
-
Arthur Eubanks authored
-
Arthur Eubanks authored
-
Arthur Eubanks authored
-
- Sep 05, 2021
-
-
Kazu Hirata authored
Identified with readability-const-return-type.
-
David Green authored
This appears to produce better code, even if the condition may need to be replicated.
-
Simon Pilgrim authored
Based off the improved fold in D108522 This should eventually allow us to replace the SLM only cost patterns with generic versions.
-
Simon Pilgrim authored
Add tests for vXi32 multiplies where the operands have been extended from vXi8/vXi16
-
David Green authored
Given a select_cc producing a constant and a invertion of the constant for a comparison more than zero, we can produce an xor with ashr instead, which produces smaller code. The ashr either sets all bits or clear all bits depending on if the value is negative. This is then xor'd with the constant to optionally negate the value. https://alive2.llvm.org/ce/z/DTFaBZ This includes a OneUseCheck on the Cmp, which seems to make thinks a little worse and will be removed in a followup. Differential Revision: https://reviews.llvm.org/D109149
-
David Green authored
Pulled out of D109149, this folds set_cc seteq (ashr X, BW-1), -1 -> set_cc setlt X, 0 to prevent some regressions later on when folding select_cc setgt X, -1, C, ~C -> xor (ashr X, BW-1), C Differential Revision: https://reviews.llvm.org/D109214
-
Dávid Bolvanský authored
-
David Green authored
-
Cheng Wang authored
-
Cheng Wang authored
-
Michael Kruse authored
Recommit of 707ce34b. Don't introduce a dependency to the LLVMPasses component, instead register the required passes individually. Add methods for loop unrolling to the OpenMPIRBuilder class and use them in Clang if `-fopenmp-enable-irbuilder` is enabled. The unrolling methods are: * `unrollLoopFull` * `unrollLoopPartial` * `unrollLoopHeuristic` `unrollLoopPartial` and `unrollLoopHeuristic` can use compiler heuristics to automatically determine the unroll factor. If possible, that is if no CanonicalLoopInfo is required to pass to another method, metadata for LLVM's LoopUnrollPass is added. Otherwise the unroll factor is determined using the same heurstics as user by LoopUnrollPass. Not requiring a CanonicalLoopInfo, especially with `unrollLoopHeuristic` allows greater flexibility. With full unrolling and partial unrolling with known unroll factor, instead of duplicating instructions by the OpenMPIRBuilder, the full ...
-
Arthur Eubanks authored
-
Min-Yih Hsu authored
Migrate the tests regarding fixup and relaxation on branch and call targets. This patch wraps up the migration from `test/CodeGen/M68k/Encoding` to `test/MC/M68k`.
-
Arthur Eubanks authored
-
Arthur Eubanks authored
-
Arthur Eubanks authored
-
Anton Afanasyev authored
Add tests monitoring issues fix. They should be fixed when https://reviews.llvm.org/D57059 ("Initial support for the vectorization of the non-power-of-2 vectors") is landed.
-
Jez Ng authored
Failing to do so results in `std::bad_function_call` being thrown when a pass tries to emit a diagnostic. I've copied the relevant test over from LLD-ELF's test suite. Reviewed By: #lld-macho, thevinster Differential Revision: https://reviews.llvm.org/D109274
-
Nikita Popov authored
By creating LLVMContext after parsing parameters.
-
Brad Smith authored
Most archs have switched to lld.
-
Dávid Bolvanský authored
-
Fangrui Song authored
The temporary object was used as a workaround when the target parser may change STI. D14346 made the MCSubtargetInfo argument to createMCAsmParser const, so we no longer need the temporary object.
-
Dávid Bolvanský authored
``` ---------------------------------------- define i1 @src(i8 %x, i8 %y, i8 %z) { %0: %f = fshl i8 %x, i8 %x, i8 %z %f2 = fshl i8 %y, i8 %y, i8 %z %r = icmp eq i8 %f, %f2 ret i1 %r } => define i1 @tgt(i8 %x, i8 %y, i8 %z) { %0: %r = icmp eq i8 %x, %y ret i1 %r } Transformation seems to be correct! ``` https://alive2.llvm.org/ce/z/qAZp8f Solves PR51565 Reviewed By: spatel Differential Revision: https://reviews.llvm.org/D109271
-
- Sep 04, 2021
-
-
Bjorn Pettersson authored
As part of the nontrivial unswitching we could end up removing child loops. This patch add a notification to the pass manager when that happens (using the markLoopAsDeleted callback). Without this there could be stale LoopAccessAnalysis results cached in the analysis manager. Those analysis results are cached based on a Loop* as key. Since the BumpPtrAllocator used to allocate Loop objects could be resetted between different runs of for example the loop-distribute pass (running on different functions), a new Loop object could be created using the same Loop pointer. And then when requiring the LoopAccessAnalysis for the loop we got the stale (corrupt) result from the destroyed loop. Reviewed By: aeubanks Differential Revision: https://reviews.llvm.org/D109257
-
Shivam Gupta authored
-
Kazu Hirata authored
Identified with readability-const-return-type.
-
Shivam Gupta authored
The current inconsistency confuse contributors which coding guidlines to follow. It would be better to have it consistent using clang-format tool. Reviewed By: mhjacobson Differential Revision: https://reviews.llvm.org/D109270
-
Simon Pilgrim authored
-
Simon Pilgrim authored
The xmm variant have half the throughput (and +1cy latency) of the mmx variants, but are still 1uop. I still need to do more thorough testing of SLM on test-suite before fixing the obvious bad numbers for WritePMULLD. But this helps the D103695 helper script get to more accurate numbers for vXi32 multiplies of extended operands (i.e. we can use PMADDWD, PMULLW/PMULHW etc). Matches what Intel AoM / Agner / llvm-exegesis reports.
-
Simon Pilgrim authored
Revert rG994da657 "[X86][SLM] WriteVecIMul instructions only take 1uop" This changed some codegen tests that I forgot about in my rebase, I'll recommit shortly with a fix.
-
Dávid Bolvanský authored
-
Simon Pilgrim authored
The xmm variant have half the throughput (and +1cy latency) of the mmx variants, but are still 1uop. I still need to do more thorough testing of SLM on test-suite before fixing the obvious bad numbers for WritePMULLD. But this helps the D103695 helper script get to more accurate numbers for vXi32 multiplies of extended operands (i.e. we can use PMADDWD, PMULLW/PMULHW etc). Matches what Intel AoM / Agner / llvm-exegesis reports.
-