[all-commits] [llvm/llvm-project] 961ab7: [SDAG][X86] Uplift pseudo fmin/fmax from X86 (#188...

Nikita Popov via All-commits all-commits at lists.llvm.org
Wed Jul 8 05:49:55 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 961ab7a3696701f9cc0c82a4cde7fc9937141b01
      https://github.com/llvm/llvm-project/commit/961ab7a3696701f9cc0c82a4cde7fc9937141b01
  Author: Nikita Popov <npopov at redhat.com>
  Date:   2026-07-08 (Wed, 08 Jul 2026)

  Changed paths:
    M llvm/include/llvm/CodeGen/ISDOpcodes.h
    M llvm/include/llvm/CodeGen/TargetLowering.h
    M llvm/include/llvm/Target/TargetSelectionDAG.td
    M llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
    M llvm/lib/CodeGen/SelectionDAG/SelectionDAGDumper.cpp
    M llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
    M llvm/lib/CodeGen/TargetLoweringBase.cpp
    M llvm/lib/Target/X86/X86ISelLowering.cpp
    M llvm/lib/Target/X86/X86InstrAVX10.td
    M llvm/lib/Target/X86/X86InstrAVX512.td
    M llvm/lib/Target/X86/X86InstrFragmentsSIMD.td
    M llvm/lib/Target/X86/X86IntrinsicsInfo.h
    M llvm/test/CodeGen/X86/fminimum-fmaximum.ll
    M llvm/test/CodeGen/X86/vec-strict-cmp-128.ll

  Log Message:
  -----------
  [SDAG][X86] Uplift pseudo fmin/fmax from X86 (#188489)

X86 has pseudo fmin/fmax operations that implement `x olt y ? x : y` and
`x ogt y ? x : y` respectively. There are other targets that also
support these operations, including wasm and s390x.

On wasm (where I've adopted the "pseudo" terminology from), we currently
create these ops, but incorrectly (wrt signed zero handling). On s390x
we don't, but should to avoid regressions from fixing incorrect
minnum/maxnum formation.

I figured it would make sense to uplift the existing support form X86,
so other targets can benefit from it by just marking the operations
legal.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list