[all-commits] [llvm/llvm-project] b87019: [RISCV] Add patterns for scalable-vector fabs & fc...

Fraser Cormack via All-commits all-commits at lists.llvm.org
Tue Feb 16 02:27:32 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: b8701990202cd305236401f76331d53e65953ef2
      https://github.com/llvm/llvm-project/commit/b8701990202cd305236401f76331d53e65953ef2
  Author: Fraser Cormack <fraser at codeplay.com>
  Date:   2021-02-16 (Tue, 16 Feb 2021)

  Changed paths:
    M llvm/lib/Target/RISCV/RISCVISelLowering.cpp
    M llvm/lib/Target/RISCV/RISCVInstrInfoVSDPatterns.td
    A llvm/test/CodeGen/RISCV/rvv/vfabs-sdnode.ll
    A llvm/test/CodeGen/RISCV/rvv/vfcopysign-sdnode.ll

  Log Message:
  -----------
  [RISCV] Add patterns for scalable-vector fabs & fcopysign

The patterns mostly follow the scalar counterparts, save for some extra
optimizations to match the vector/scalar forms.

The patch adds a DAGCombine for ISD::FCOPYSIGN to try and reorder
ISD::FNEG around any ISD::FP_EXTEND or ISD::FP_TRUNC of the second
operand. This helps us achieve better codegen to match vfsgnjn.

Reviewed By: craig.topper

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




More information about the All-commits mailing list