Fix PR9127 by reversing the operands even if they have more then one use.
authorRafael Espindola <rafael.espindola@gmail.com>
Thu, 3 Feb 2011 03:58:05 +0000 (03:58 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Thu, 3 Feb 2011 03:58:05 +0000 (03:58 +0000)
commitf297c931913ec4285395fa278fa9c9898685c469
tree4b66e2485a780b2df350de43629ae3a6a720d7ef
parentb0cfa6cab85ce19c8ecaf9cdd3e34a3593d0b001
Fix PR9127 by reversing the operands even if they have more then one use.
Reversing the operands allows us to fold, but doesn't force us to. Also, at
this point the DAG is still being optimized, so the check for hasOneUse is not
very precise.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@124773 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/X86/X86ISelLowering.cpp
test/CodeGen/X86/pr9127.ll [new file with mode: 0644]