[all-commits] [llvm/llvm-project] d87621: [RISCV] Begin to support more subvector inserts/ex...

Fraser Cormack via All-commits all-commits at lists.llvm.org
Thu Feb 18 02:24:50 PST 2021


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

  Changed paths:
    M llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp
    A llvm/test/CodeGen/RISCV/rvv/extract-subvector.ll
    A llvm/test/CodeGen/RISCV/rvv/insert-subvector.ll

  Log Message:
  -----------
  [RISCV] Begin to support more subvector inserts/extracts

This patch adds support for INSERT_SUBVECTOR and EXTRACT_SUBVECTOR
(nominally where both operands are scalable vector types) where the
vector, subvector, and index align sufficiently to allow decomposition
to subregister manipulation:

* For extracts, the extracted subvector must correctly align with the
lower elements of a vector register.
* For inserts, the inserted subvector must be at least one full vector
register, and correctly align as above.

This approach should work for fixed-length vector insertion/extraction
too, but that will come later.

Reviewed By: craig.topper, khchen, arcbbb

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




More information about the All-commits mailing list