[all-commits] [llvm/llvm-project] 05edfc: [SVE][CodeGen] Add DAG combines for s/zext_masked_...

kmclaughlin-arm via All-commits all-commits at lists.llvm.org
Wed Dec 9 03:54:50 PST 2020


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 05edfc54750bd539f5caa30b0cd4344f68677b00
      https://github.com/llvm/llvm-project/commit/05edfc54750bd539f5caa30b0cd4344f68677b00
  Author: Kerry McLaughlin <kerry.mclaughlin at arm.com>
  Date:   2020-12-09 (Wed, 09 Dec 2020)

  Changed paths:
    M llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
    M llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
    M llvm/test/CodeGen/AArch64/sve-masked-gather-32b-signed-scaled.ll
    M llvm/test/CodeGen/AArch64/sve-masked-gather-32b-signed-unscaled.ll
    M llvm/test/CodeGen/AArch64/sve-masked-gather-32b-unsigned-scaled.ll
    M llvm/test/CodeGen/AArch64/sve-masked-gather-32b-unsigned-unscaled.ll
    M llvm/test/CodeGen/AArch64/sve-masked-gather-64b-scaled.ll
    M llvm/test/CodeGen/AArch64/sve-masked-gather-64b-unscaled.ll
    M llvm/test/CodeGen/AArch64/sve-masked-gather-legalize.ll

  Log Message:
  -----------
  [SVE][CodeGen] Add DAG combines for s/zext_masked_gather

This patch adds the following DAGCombines, which apply if isVectorLoadExtDesirable() returns true:
 - fold (and (masked_gather x)) -> (zext_masked_gather x)
 - fold (sext_inreg (masked_gather x)) -> (sext_masked_gather x)

LowerMGATHER has also been updated to fetch the LoadExtType associated with the
gather and also use this value to determine the correct masked gather opcode to use.

Reviewed By: sdesmalen

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




More information about the All-commits mailing list