[all-commits] [llvm/llvm-project] 9fc1a0: [AArch64] Alter mull shuffle(ext(..)) combine to w...

David Green via All-commits all-commits at lists.llvm.org
Mon Feb 21 07:44:43 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 9fc1a0dcb79afb31470751651c30e843c12e9ca5
      https://github.com/llvm/llvm-project/commit/9fc1a0dcb79afb31470751651c30e843c12e9ca5
  Author: David Green <david.green at arm.com>
  Date:   2022-02-21 (Mon, 21 Feb 2022)

  Changed paths:
    M llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
    M llvm/test/CodeGen/AArch64/aarch64-dup-ext.ll
    M llvm/test/CodeGen/AArch64/aarch64-matrix-umull-smull.ll

  Log Message:
  -----------
  [AArch64] Alter mull shuffle(ext(..)) combine to work on buildvectors

We have a combine for converting mul(dup(ext(..)), ...) into
mul(ext(dup(..)), ..), for allowing more uses of smull and umull
instructions. Currently it looks for vector insert and shuffle vectors
to detect the element that we can convert to a vector extend. Not all
cases will have a shufflevector/insert element though.

This started by extending the recognition to buildvectors (with elements
that may be individually extended). The new method seems to cover all
the cases that the old method captured though, as the shuffle will
eventually be lowered to buildvectors, so the old method has been
removed to keep the code a little simpler. The new code detects legal
build_vector(ext(a), ext(b), ..), converting them to ext(build_vector(a,
b, ..)) providing all the extends/types match up.

Differential Revision: https://reviews.llvm.org/D120018




More information about the All-commits mailing list