[all-commits] [llvm/llvm-project] 5b77ac: [SLP] match maxnum/minnum intrinsics as FP reducti...

RotateRight via All-commits all-commits at lists.llvm.org
Mon Jan 18 14:37:41 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 5b77ac32b1150d066b35b45d6d982f4b4a1f62ff
      https://github.com/llvm/llvm-project/commit/5b77ac32b1150d066b35b45d6d982f4b4a1f62ff
  Author: Sanjay Patel <spatel at rotateright.com>
  Date:   2021-01-18 (Mon, 18 Jan 2021)

  Changed paths:
    M llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
    M llvm/test/Transforms/PhaseOrdering/X86/vector-reductions-expanded.ll
    M llvm/test/Transforms/SLPVectorizer/X86/fmaxnum.ll
    M llvm/test/Transforms/SLPVectorizer/X86/fminnum.ll

  Log Message:
  -----------
  [SLP] match maxnum/minnum intrinsics as FP reduction ops

After much refactoring over the last 2 weeks to the reduction
matching code, I think this change is finally ready.

We effectively broke fmax/fmin vector reduction optimization
when we started canonicalizing to intrinsics in instcombine,
so this should restore that functionality for SLP.

There are still FMF problems here as noted in the code comments,
but we should be avoiding miscompiles on those for fmax/fmin by
restricting to full 'fast' ops (negative tests are included).

Fixing FMF propagation is a planned follow-up.

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




More information about the All-commits mailing list