[PATCH] D12015: [SDAG] Generate FMINNUM/FMAXNUM/FMINNAN/FMAXNAN from SDAGBuilder

James Molloy via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 13 10:25:38 PDT 2015


jmolloy created this revision.
jmolloy added reviewers: majnemer, hfinkel.
jmolloy added a subscriber: llvm-commits.
jmolloy set the repository for this revision to rL LLVM.
Herald added a subscriber: aemerson.

These only get generated if the target supports them. If one of the variants is not legal and the other is, and it is safe to do so, the other variant will be emitted.

For example on AArch32 (V8), we have scalar fminnm but not fmin.

Fix up a couple of tests while we're here - one now produces better code, and the other was just plain wrong to start with.

This is tested by the fact that both ARM and AArch64 mark these nodes as legal.

I know this is basically mechanical, but as it's in the target independent layer I'd appreciate peoples' eyes on it.

Repository:
  rL LLVM

http://reviews.llvm.org/D12015

Files:
  lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
  test/CodeGen/AArch64/arm64-fmax-safe.ll
  test/CodeGen/ARM/vminmaxnm.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D12015.32073.patch
Type: text/x-patch
Size: 3947 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150813/c5bcec77/attachment.bin>


More information about the llvm-commits mailing list