[all-commits] [llvm/llvm-project] f7a46a: [RISCV] Fold vector binary operatrion into select ...

Jianjian Guan via All-commits all-commits at lists.llvm.org
Mon Dec 5 19:19:46 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: f7a46aa8fbc261f2c399f192902bfccce57f35e7
      https://github.com/llvm/llvm-project/commit/f7a46aa8fbc261f2c399f192902bfccce57f35e7
  Author: jacquesguan <Jianjian.Guan at streamcomputing.com>
  Date:   2022-12-06 (Tue, 06 Dec 2022)

  Changed paths:
    M llvm/lib/Target/RISCV/RISCVISelLowering.cpp
    M llvm/lib/Target/RISCV/RISCVISelLowering.h
    M llvm/test/CodeGen/RISCV/rvv/vadd-sdnode.ll
    M llvm/test/CodeGen/RISCV/rvv/vand-sdnode.ll
    M llvm/test/CodeGen/RISCV/rvv/vfadd-sdnode.ll
    M llvm/test/CodeGen/RISCV/rvv/vfsub-sdnode.ll
    M llvm/test/CodeGen/RISCV/rvv/vmul-sdnode.ll
    M llvm/test/CodeGen/RISCV/rvv/vor-sdnode.ll
    M llvm/test/CodeGen/RISCV/rvv/vshl-sdnode.ll
    M llvm/test/CodeGen/RISCV/rvv/vsra-sdnode.ll
    M llvm/test/CodeGen/RISCV/rvv/vsrl-sdnode.ll
    M llvm/test/CodeGen/RISCV/rvv/vsub-sdnode.ll
    M llvm/test/CodeGen/RISCV/rvv/vxor-sdnode.ll

  Log Message:
  -----------
  [RISCV] Fold vector binary operatrion into select with identity constant.

This patch implements shouldFoldSelectWithIdentityConstant for RISCV. It would try to generate vmerge after the binary instruction and let them folded to maksed instruction later.

Reviewed By: craig.topper

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




More information about the All-commits mailing list