[PATCH] D25221: [PPC][DAGCombine] Convert SETCC to subtract when the result is zero extended

Ehsan Amiri via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 2 13:16:56 PDT 2016


amehsan updated this revision to Diff 76772.
amehsan added a comment.

Completed the unit test and code. I decided that extending this for signed comparison is not necessary good, because two zero extends that we generate for unsigned comparison, will be sign extension for signed comparison. That means the signed version will have two more instructions. There might be still more useful cases, but I think they are different enough and we don't need to make them part of this patch.


https://reviews.llvm.org/D25221

Files:
  lib/Target/PowerPC/PPCISelLowering.cpp
  lib/Target/PowerPC/PPCISelLowering.h
  pzero-fp-xored.ll
  test/CodeGen/PowerPC/setcc-to-sub.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D25221.76772.patch
Type: text/x-patch
Size: 10680 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161102/43f26ecf/attachment.bin>


More information about the llvm-commits mailing list