[all-commits] [llvm/llvm-project] f26987: [X86] canonicalizeShuffleMaskWithHorizOp - fold pe...

Simon Pilgrim via All-commits all-commits at lists.llvm.org
Thu Jul 13 02:37:31 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: f269877dc30777354be8a512e871aba1b1f9fd7a
      https://github.com/llvm/llvm-project/commit/f269877dc30777354be8a512e871aba1b1f9fd7a
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2023-07-13 (Thu, 13 Jul 2023)

  Changed paths:
    M llvm/lib/Target/X86/X86ISelLowering.cpp
    M llvm/test/CodeGen/X86/vector-interleaved-load-i8-stride-4.ll
    M llvm/test/CodeGen/X86/vector-interleaved-load-i8-stride-7.ll
    M llvm/test/CodeGen/X86/vector-interleaved-load-i8-stride-8.ll
    M llvm/test/CodeGen/X86/vector-interleaved-store-i8-stride-6.ll
    M llvm/test/CodeGen/X86/vector-interleaved-store-i8-stride-8.ll

  Log Message:
  -----------
  [X86] canonicalizeShuffleMaskWithHorizOp - fold permute(pack(x,y)) -> pack(shuffle(x,y),undef) iff we only demand the lower elements

Help expose undef elements for further shuffle combines

Noticed while trying to improve truncation packss/packus patterns for sub-128-bit results.


  Commit: 228442a14ceb804d74416a7701b012ffeb759aff
      https://github.com/llvm/llvm-project/commit/228442a14ceb804d74416a7701b012ffeb759aff
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2023-07-13 (Thu, 13 Jul 2023)

  Changed paths:
    M llvm/lib/Target/X86/X86ISelLowering.cpp
    M llvm/test/CodeGen/X86/vector-shuffle-combining-avx2.ll

  Log Message:
  -----------
  [X86] canonicalizeShuffleMaskWithHorizOp - fold 256-bit permute(hop(x,y)) -> hop(extract(x),extract(x)) iff we only demand the lower elements

Attempt to recognise when we can narrow a 256-bit hop to a lower 128-bit hop by extracting the requested subvectors (and then widening back)


Compare: https://github.com/llvm/llvm-project/compare/c3339bd2fd65...228442a14ceb


More information about the All-commits mailing list