[all-commits] [llvm/llvm-project] 025a2f: [InstCombine] add tests for umax with sub; NFC

RotateRight via All-commits all-commits at lists.llvm.org
Sat Nov 6 05:41:55 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 025a2f73a31955cfd9b1e097533b9c6ef15dc6d3
      https://github.com/llvm/llvm-project/commit/025a2f73a31955cfd9b1e097533b9c6ef15dc6d3
  Author: Sanjay Patel <spatel at rotateright.com>
  Date:   2021-11-06 (Sat, 06 Nov 2021)

  Changed paths:
    M llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
    M llvm/test/Transforms/InstCombine/minmax-intrinsics.ll

  Log Message:
  -----------
  [InstCombine] add tests for umax with sub; NFC


  Commit: 83c2fb9f66be0eab489818ca87027dd2dbfeaa8e
      https://github.com/llvm/llvm-project/commit/83c2fb9f66be0eab489818ca87027dd2dbfeaa8e
  Author: Sanjay Patel <spatel at rotateright.com>
  Date:   2021-11-06 (Sat, 06 Nov 2021)

  Changed paths:
    M llvm/lib/Transforms/InstCombine/InstCombineAddSub.cpp
    M llvm/test/Transforms/InstCombine/minmax-intrinsics.ll

  Log Message:
  -----------
  [InstCombine] match usub.sat from umax intrinsic

umax(X, Op1) - Op1 --> usub.sat(X, Op1)

https://alive2.llvm.org/ce/z/HpcGiJ

This happens in 2 or more steps with an icmp-select idiom
instead of an intrinsic. This is another step towards
canonicalization of the min/max intrinsics. See:
D98152


Compare: https://github.com/llvm/llvm-project/compare/63fff0f5bffe...83c2fb9f66be


More information about the All-commits mailing list