[all-commits] [llvm/llvm-project] fc1f20: [SLPVectorizer][SVE] Bail out early for scalable v...

huihzhang via All-commits all-commits at lists.llvm.org
Fri Mar 13 11:23:46 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: fc1f205745003eeeabd4ee356dea7e5c7fa4fd64
      https://github.com/llvm/llvm-project/commit/fc1f205745003eeeabd4ee356dea7e5c7fa4fd64
  Author: Huihui Zhang <huihuiz at quicinc.com>
  Date:   2020-03-13 (Fri, 13 Mar 2020)

  Changed paths:
    M llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
    A llvm/test/Transforms/SLPVectorizer/AArch64/invalid_type.ll
    A llvm/test/Transforms/SLPVectorizer/AArch64/scalable-vector.ll

  Log Message:
  -----------
  [SLPVectorizer][SVE] Bail out early for scalable vector.

Summary:
SLPVectorizer try to vectorize list of scalar instructions of the same type,
instructions already vectorized are rejected through isValidElementType().

Without this patch, tryToVectorizeList() will first try to determine vectorization
factor of a list of Instructions before checking whether each instruction has unsupported
type or not. For instructions already vectorized for SVE, it will crash at getVectorElementSize(),
where it try to return a fixed size.

This patch make sure invalid element types are rejected before trying to get vectorization
factor. This make sure we are not trying to vectorize instructions already vectorized.

Reviewers: sdesmalen, efriedma, spatel, RKSimon, ABataev, apazos, rengolin

Reviewed By: efriedma

Subscribers: tschuett, hiraditya, rkruppe, psnobl, llvm-commits

Tags: #llvm

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




More information about the All-commits mailing list