Skip to content
  1. Oct 14, 2021
    • Brian Cain's avatar
      [hexagon] Add system register, transfer support · 743e263e
      Brian Cain authored
      This commit adds the system reg/regpair definitions and the corresponding
      register transfer instructions.
      743e263e
    • Andrew Savonichev's avatar
      [NVPTX] Add VRFrame and VRFrameLocal to integer register classes · 51eefa81
      Andrew Savonichev authored
      These registers are used as operands for instructions that expect an
      integer register, so they should be added to Int32Regs or Int64Regs
      register classes. Otherwise the machine verifier emits an error for
      the following LIT tests when LLVM_ENABLE_MACHINE_VERIFIER=1
      environment variable is set:
      
      *** Bad machine code: Illegal physical register for instruction ***
      - function:    kernel_func
      - basic block: %bb.0 entry (0x55c8903d5438)
      - instruction: %3:int64regs = LEA_ADDRi64 $vrframelocal, 0
      - operand 1:   $vrframelocal
      $vrframelocal is not a Int64Regs register.
      
          CodeGen/NVPTX/call-with-alloca-buffer.ll
          CodeGen/NVPTX/disable-opt.ll
          CodeGen/NVPTX/lower-alloca.ll
          CodeGen/NVPTX/lower-args.ll
          CodeGen/NVPTX/param-align.ll
          CodeGen/NVPTX/reg-types.ll
          DebugInfo/NVPTX/dbg-declare-alloca.ll
          DebugInfo/NVPTX/dbg-value-const-byref.ll
      
      Differential Revision: https://reviews.llvm.org/D110164
      51eefa81
    • Jonas Paulsson's avatar
    • Andrew Savonichev's avatar
      [ARM] Simplify address calculation for NEON load/store · dc8a41de
      Andrew Savonichev authored
      The patch attempts to optimize a sequence of SIMD loads from the same
      base pointer:
      
          %0 = gep float*, float* base, i32 4
          %1 = bitcast float* %0 to <4 x float>*
          %2 = load <4 x float>, <4 x float>* %1
          ...
          %n1 = gep float*, float* base, i32 N
          %n2 = bitcast float* %n1 to <4 x float>*
          %n3 = load <4 x float>, <4 x float>* %n2
      
      For AArch64 the compiler generates a sequence of LDR Qt, [Xn, #16].
      However, 32-bit NEON VLD1/VST1 lack the [Wn, #imm] addressing mode, so
      the address is computed before every ld/st instruction:
      
          add r2, r0, #32
          add r0, r0, #16
          vld1.32 {d18, d19}, [r2]
          vld1.32 {d22, d23}, [r0]
      
      This can be improved by computing address for the first load, and then
      using a post-indexed form of VLD1/VST1 to load the rest:
      
          add r0, r0, #16
          vld1.32 {d18, d19}, [r0]!
          vld1.32 {d22, d23}, [r0]
      
      In order to do that, the patch adds more patterns to DAGCombine:
      
        - (load (add ptr inc1)) and (add ptr inc2) are now folded if inc1
          and inc2 are constants.
      
        - (or ptr inc) is now recognized as a pointer increment if ptr is
          sufficiently aligned.
      
      In addition to that, we now search for all possible base updates and
      then pick the best one.
      
      Differential Revision: https://reviews.llvm.org/D108988
      dc8a41de
    • Simon Pilgrim's avatar
      [Codegen] TargetLowering::getCanonicalIndexType - early out scaled MVT::i8 indices. NFCI. · 88487662
      Simon Pilgrim authored
      Avoids unused assignment scan-build warning.
      88487662
    • Simon Pilgrim's avatar
      [CostModel][X86] Pre-SSE41 targets can use PMADDWD for sext sub-i16 -> i32 · 77dcdc2f
      Simon Pilgrim authored
      Without SSE41 sext/zext instructions the extensions will be split, meaning that the MUL->PMADDWD fold will split the sext_i32(x) into zext_i32(sext_i16(x))
      77dcdc2f
    • Simon Pilgrim's avatar
      [Orc] ELFNixPlatform::setupJITDylib - remove dead return. NFCI. · 16729d0f
      Simon Pilgrim authored
      2 returns, one after the other - reported by coverity
      16729d0f
    • Jeremy Morse's avatar
      Follow up to a3936a6c, correctly select LiveDebugValues implementation · e3e1da20
      Jeremy Morse authored
      Some functions get opted out of instruction referencing if they're being
      compiled with no optimisations, however the LiveDebugValues pass picks one
      implementation and then sticks with it through the rest of compilation.
      This leads to a segfault if we encounter a function that doesn't use
      instr-ref (because it's optnone, for example), but we've already decided
      to use InstrRefBasedLDV which expects to be passed a DomTree.
      
      Solution: keep both implementations around in the pass, and pick whichever
      one is appropriate to the current function.
      e3e1da20
    • Jonas Paulsson's avatar
      [SystemZ] Reapply memcmp and memcpy patches. · a33e4c8a
      Jonas Paulsson authored
      This reverts 3562076d and includes some refactoring as well.
      
      Review: Ulrich Weigand
      
      Differential Revision: https://reviews.llvm.org/D111733
      a33e4c8a
    • Jonas Paulsson's avatar
      [SystemZ] Bugfix and refactorization of mem-mem operations · 00baad35
      Jonas Paulsson authored
      This patch fixes the bug that consisted of treating variable / immediate
      length mem operations (such as memcpy, memset, ...) differently. The variable
      length case needs to have the length minus 1 passed due to the use of EXRL
      target instructions. However, the DAGCombiner can convert a register length
      argument into a constant one, and whenever that happened one byte too little
      would end up being performed.
      
      This is also a refactorization by reducing the number of opcodes and variants
      involved. For any opcode (variable or constant length), only the length minus
      one is passed on to the ISD node. The rest of the logic is now instead
      handled during isel pseudo expansion.
      
      Review: Ulrich Weigand
      
      Differential Revision: https://reviews.llvm.org/D111729
      00baad35
    • Max Kazantsev's avatar
      [SCEV][NFC] Simplify check with CI->isZero() exit condition · 6e1308bc
      Max Kazantsev authored
      Replace check with
          if ((ExitIfTrue && CI->isZero()) || (!ExitIfTrue && CI->isOne()))
      with equivalent and simpler version
          if (ExitIfTrue == CI->isZero())
      6e1308bc
    • Max Kazantsev's avatar
      [SCEV][NFC] Reorder checks to delay call of all_of · 46a1dd47
      Max Kazantsev authored
      Check lightweight getter condition before calling all_of.
      46a1dd47
    • Ben Shi's avatar
      [RISCV] Optimize immediate materialisation with BSETI/BCLRI · 7e815261
      Ben Shi authored
      Opitimize immediate materialisation in the following way if profitable:
      1. Use BCLRI for upper 32 bits if the lower 32 bits are negative int32.
      2. Use BSETI for upper 32 bits if the lower 32 bits are positive int32.
      
      Reviewed By: craig.topper
      
      Differential Revision: https://reviews.llvm.org/D111508
      7e815261
    • Abinav Puthan Purayil's avatar
      [AMDGPU] Fix 24-bit mul intrinsic generation for > 32-bit result. · b3c9d84e
      Abinav Puthan Purayil authored
      The 24-bit mul intrinsics yields the low-order 32 bits. We should only
      do the transformation if the operands are known to be not wider than 24
      bits and the result is known to be not wider than 32 bits.
      
      Differential Revision: https://reviews.llvm.org/D111523
      b3c9d84e
    • Ben Shi's avatar
      [RISCV] Optimize immediate materialisation with SLLI.UW · 481db13f
      Ben Shi authored
      Use LUI+SLLI.UW to compose the upper bits instead of LUI+SLLI.
      
      Reviewed By: craig.topper
      
      Differential Revision: https://reviews.llvm.org/D111705
      481db13f
    • Lang Hames's avatar
      [ORC] Use a Setup object for SimpleRemoteEPC construction. · 4fcc0ac1
      Lang Hames authored
      SimpleRemoteEPC notionally allowed subclasses to override the
      createMemoryManager and createMemoryAccess methods to use custom objects, but
      could not actually be subclassed in practice (The construction process in
      SimpleRemoteEPC::Create could not be re-used).
      
      Instead of subclassing, this commit adds a SimpleRemoteEPC::Setup class that
      can be used by clients to set up the memory manager and memory access members.
      A default-constructed Setup object results in no change from previous behavior
      (EPCGeneric* memory manager and memory access objects used by default).
      4fcc0ac1
    • Shoaib Meenai's avatar
      [InstCombine] Remove attributes after hoisting free above null check · 6404f4b5
      Shoaib Meenai authored
      If the parameter had been annotated as nonnull because of the null
      check, we want to remove the attribute, since it may no longer apply and
      could result in miscompiles if left. Similarly, we also want to remove
      undef-implying attributes, since they may not apply anymore either.
      
      Fixes PR52110.
      
      Reviewed By: nikic
      
      Differential Revision: https://reviews.llvm.org/D111515
      6404f4b5
  2. Oct 13, 2021
Loading