summaryrefslogtreecommitdiffstats
path: root/llvm
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2008-09-25 17:22:52 +0000
committerDan Gohman <gohman@apple.com>2008-09-25 17:22:52 +0000
commit5e490a75672d442ab1c7ae800d3819eef66716c7 (patch)
treedb651f96c6aacf7da830e88b226d8798f7644635 /llvm
parent6975c36c431473a6822687727eae8aebe5650383 (diff)
downloadbcm5719-llvm-5e490a75672d442ab1c7ae800d3819eef66716c7.tar.gz
bcm5719-llvm-5e490a75672d442ab1c7ae800d3819eef66716c7.zip
Support for i1 XOR in FastISel. It is actually safe because
i1 operands are assumed to already by zero-extended. llvm-svn: 56615
Diffstat (limited to 'llvm')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/FastISel.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp b/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp
index 254b1fe42cc..dcb30ad1882 100644
--- a/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/FastISel.cpp
@@ -135,10 +135,11 @@ bool FastISel::SelectBinaryOp(User *I, ISD::NodeType ISDOpcode) {
// under the assumption that i64 won't be used if the target doesn't
// support it.
if (!TLI.isTypeLegal(VT)) {
- // MVT::i1 is special. Allow AND and OR (but not XOR) because they
+ // MVT::i1 is special. Allow AND, OR, or XOR because they
// don't require additional zeroing, which makes them easy.
if (VT == MVT::i1 &&
- (ISDOpcode == ISD::AND || ISDOpcode == ISD::OR))
+ (ISDOpcode == ISD::AND || ISDOpcode == ISD::OR ||
+ ISDOpcode == ISD::XOR))
VT = TLI.getTypeToTransformTo(VT);
else
return false;
OpenPOWER on IntegriCloud