- May 25, 2020
-
-
Simon Pilgrim authored
If we're extracting an upper subvector from a broadcast we're better off extracting the lowest subvector instead as it avoids an actual extract instruction and might help SimplifyDemandedVectorElts further simplify the code.
-
Sanjay Patel authored
EarlyCSE was added with D75145, but the motivating test is not regressed by removing the extra pass now. That might be because VectorCombine altered the way it processes instructions, or it might be from (re)moving VectorCombine in the pipeline. The extra round of EarlyCSE appears to cost approximately 0.26% in compile-time as discussed in D80236, so we need some evidence to justify its inclusion here, but we do not have that (yet). I suspect that between SLP and VectorCombine, we are creating patterns that InstCombine and/or codegen are not prepared for, but we will need to reduce those examples and include them as PhaseOrdering and/or test-suite benchmarks.
-
Florian Hahn authored
Currently we unconditionally get the first lane of the condition operand, even if we later use the full vector condition. This can result in some unnecessary instructions being generated. Suggested as follow-up in D80219.
-
- May 24, 2020
-
-
Sanjay Patel authored
As discussed in D80236 - this test (like all PhaseOrdering tests?) was intended to show that there is no difference with the new pass manager, but the 'opt' command requires extra parameters to make that happen.
-
Simon Pilgrim authored
This initial version only peeks through cases where we just demand the sign bit of an ashr shift, but we could generalize this further depending on how many sign bits we already have. The pr18014.ll case is a minor annoyance - we've failed to to move the psrad/paddd after the blendvps which would have avoided the extra move, but we have still increased the ILP.
-
Simon Pilgrim authored
Replace TargetMachine.h include with forward declaration and CodeGen.h include in AMDGPU.h. Exposes a couple of implicit dependencies that require additional forward declarations/includes.
-
Kang Zhang authored
Summary: This patch add the InstAlias definitions for below instructions. ADDI ADDIS ADDI8 ADDIS8 RLWINM8 ISEL ISEL8 OR OR_rec ORI ORI8 XORI8 CNTLZW8 CNTLZW8_rec TEND TSR RFEBB NOR NOR_rec MTCRF SUBF SUBF_rec SUBFC SUBFC_rec RLDICL_32_64 TW Reviewed By: steven.zhang Differential Revision: https://reviews.llvm.org/D77559
-
Nathan James authored
Summary: Fix a potential assert in use-noexcept check if there is an issue getting the `TypeSourceInfo` as well as a small clean up. Reviewers: aaron.ballman, alexfh, gribozavr2 Reviewed By: aaron.ballman Subscribers: xazax.hun, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D80371
-
Sanjay Patel authored
Similar to D79116 and rGbfd51216 - if the 1st cast is exact, then we can go directly to the destination type because there is no double-rounding.
-
Sanjay Patel authored
Readability is not reduced with these opcodes/match lines, so reduce odds of awkward wrapping from 80-col limit.
-
Simon Pilgrim authored
Fixes implicit dependency that will be exposed by a future patch.
-
Florian Hahn authored
VPWidenSelectRecipe already contains a VPUser, but it is not used. This patch updates the code related to VPWidenSelectRecipe to use VPUser for its operands. Reviewers: Ayal, gilr, rengolin Reviewed By: gilr Differential Revision: https://reviews.llvm.org/D80219
-
Simon Pilgrim authored
As we're inheriting from TargetLoweringObjectFileELF, TargetLoweringObjectFileImpl.h already declares all types we require in the overrides.
-
Simon Pilgrim authored
Ensure AMDGPULibFunc.h module header is first, and fix exposed missing forward declaration.
-
Simon Pilgrim authored
-
Stephen Kelly authored
The old return values mean * implicit conversion * not being able to write sizeOfExpr().bind() for example
-
Stephen Kelly authored
-
Stephen Kelly authored
-
Simon Pilgrim authored
By moving X86Subtarget::isPositionIndependent() into X86Subtarget.cpp we can remove the header dependency and move the few uses into source files.
-
Simon Pilgrim authored
Both paths always create the same DemandedBits mask.
-
Simon Pilgrim authored
For the 'inverse shift', we currently always perform a subtraction of the original (masked) shift amount. But for the case where we are handling power-of-2 type widths, we can replace: (sub bw-1, (and amt, bw-1) ) -> (and (xor amt, bw-1), bw-1) -> (and ~amt, bw-1) This allows x86 shifts to fold away the and-mask. Followup to D77301 + D80466. http://volta.cs.utah.edu:8080/z/Nod0Gr Differential Revision: https://reviews.llvm.org/D80489
-
Simon Pilgrim authored
-
Simon Pilgrim authored
CONCAT_VECTORS/INSERT_SUBVECTOR both are custom on v32i1/v64i1 like the other ops in the loop.
-
Simon Pilgrim authored
We have to include X86Subtarget.h.
-
Tobias Hieta authored
Differential Revision: https://reviews.llvm.org/D80438
-
Simon Pilgrim authored
On X86 (AVX1/AVX2), non-boolean masked loads only demand the sign bit of the mask, we already do the equivalent for masked stores. Annoyingly I can't easily handle this inside TargetLowering::SimplifyDemandedBits as this is an x86 specific case for a generic node. Differential Revision: https://reviews.llvm.org/D80478
-
Craig Topper authored
This adds the family/model returned by CPUID for some Intel Comet Lake CPUs. Instruction set and tuning wise these are the same as "skylake". These are not in the Intel SDM yet, but these should be correct.
-
Craig Topper authored
-
Simon Pilgrim authored
This is a preliminary patch before I deal with the xor+and issue raised in D77301. We get much better code for i8/i16 funnel shifts by concatenating the operands together and performing the shift as a double width type, it avoids repeated use of the shift amount and partial registers. fshl(x,y,z) -> (((zext(x) << bw) | zext(y)) << (z & (bw-1))) >> bw. fshr(x,y,z) -> (((zext(x) << bw) | zext(y)) >> (z & (bw-1))) >> bw. Alive2: http://volta.cs.utah.edu:8080/z/CZx7Cn This doesn't do as well for i32 cases on x86_64 (the xor+and followup patch is much better) so I haven't bothered with that. Cases with constant amounts are more dubious as well so I haven't currently bothered with those - its these kind of 'edge' cases that put me off trying to put this in TargetLowering::expandFunnelShift. Differential Revision: https://reviews.llvm.org/D80466
-
Amara Emerson authored
Although writing to wzr/xzr is correct since we don't care about the result of the sub, only the flags, doing so causes tail merge blocks to fail. Writing to an unused virtual register instead allows the optimization to fire, improving performance significantly on 256.bzip2. Differential Revision: https://reviews.llvm.org/D80460
-
Vitaly Buka authored
Summary: The test demonstrates the current state of the compiler and I am going to resolve FIXME in followup patches. Reviewers: eugenis Reviewed By: eugenis Subscribers: inglorion, hiraditya, steven_wu, dexonsmith, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D80039
-
Eli Friedman authored
This doesn't make a difference for linkers that support the option, but it improves the error message from older linkers that don't support it.
-
Amy Kwan authored
This patch introduces a TargetLowering query, isMulhCheaperThanMulShift. Currently in DAG Combine, it will transform mulhs/mulhu into a wider multiply and a shift if the wide multiply is legal. This TLI function is implemented on 64-bit PowerPC, as it is more desirable to have multiply-high over multiply + shift for words and doublewords. Having multiply-high can also aid in further transformations that can be done. Differential Revision: https://reviews.llvm.org/D78271
-
zoecarver authored
__test_has_construct. In C++17 some tests started failing after a521532a. This fixes those errors by suppressing the deprecation warning when calling `construct` in `__test_has_construct`. This is the same solution as `__has_destroy_test` already uses. Reviewers: ldionne, #libc! Subscribers: dexonsmith, libcxx-commits Tags: #libc Differential Revision: https://reviews.llvm.org/D80481
-
Fangrui Song authored
-
zoecarver authored
Summary: Libcxx only supports compilers with variadics. We can safely remove all "fake" variadic overloads of allocator_traits::construct. This also provides the correct behavior if anything other than exactly one argument is supplied to allocator_traits::construct in C++03 mode. Reviewers: ldionne, #libc! Subscribers: dexonsmith, libcxx-commits Tags: #libc Differential Revision: https://reviews.llvm.org/D80067
-
Jonas Devlieghere authored
This reverts commit f2ffa33c. My local checkout was behind and Eric already took care of it in the meantime.
-
Jonas Devlieghere authored
Fixes warning: enumeration value 'eExpressionThreadVanished' not handled in switch [-Wswitch] in CommandInterpreter.cpp.
-
Jinsong Ji authored
Fixed following trivial issues that caught by warnings by adding indents. clang/docs/ConstantInterpreter.rst:133: WARNING: Bullet list ends without a blank line; unexpected unindent. clang/docs/ConstantInterpreter.rst:136: WARNING: Bullet list ends without a blank line; unexpected unindent. clang/docs/ConstantInterpreter.rst:153: WARNING: Bullet list ends without a blank line; unexpected unindent. clang/docs/ConstantInterpreter.rst:195: WARNING: Bullet list ends without a blank line; unexpected unindent. clang/docs/ConstantInterpreter.rst:225: WARNING: Bullet list ends without a blank line; unexpected unindent. clang/docs/ConstantInterpreter.rst:370: WARNING: Bullet list ends without a blank line; unexpected unindent. clang/docs/ConstantInterpreter.rst:383: WARNING: Bullet list ends without a blank line; unexpected unindent.
-
Florian Hahn authored
This patch updates computeConstantRange to optionally take an assumption cache as argument and use the available assumptions to limit the range of the result. Currently this is limited to assumptions that are comparisons. Reviewers: reames, nikic, spatel, jdoerfert, lebedev.ri Reviewed By: nikic Differential Revision: https://reviews.llvm.org/D76193
-