summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-04-04 22:28:35 +0000
committerChris Lattner <sabre@nondot.org>2006-04-04 22:28:35 +0000
commit4a744e5c9d989c75fc51b91d34d97edebd495086 (patch)
tree3274900bdab7fe61538794b4f485421f2407f4a2 /llvm/lib/Target/PowerPC/PPCISelLowering.cpp
parent011c23d9d3d7eff6a122f6eecbc860879585dfd1 (diff)
downloadbcm5719-llvm-4a744e5c9d989c75fc51b91d34d97edebd495086.tar.gz
bcm5719-llvm-4a744e5c9d989c75fc51b91d34d97edebd495086.zip
Fix some broken logic that would cause us to codegen {2147483647,2147483647,2147483647,2147483647} as 'vspltisb v0, -1'.
llvm-svn: 27413
Diffstat (limited to 'llvm/lib/Target/PowerPC/PPCISelLowering.cpp')
-rw-r--r--llvm/lib/Target/PowerPC/PPCISelLowering.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCISelLowering.cpp b/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
index b27f5959db3..f1325e8387c 100644
--- a/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
+++ b/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
@@ -353,8 +353,8 @@ bool PPC::isVecSplatImm(SDNode *N, unsigned ByteSize, char *Val) {
ValSizeInBytes >>= 1;
// If the top half equals the bottom half, we're still ok.
- if (((Value >> (ValSizeInBytes*8)) & ((8 << ValSizeInBytes)-1)) !=
- (Value & ((8 << ValSizeInBytes)-1)))
+ if (((Value >> (ValSizeInBytes*8)) & (1 << (8*ValSizeInBytes)-1)) !=
+ (Value & (1 << (8*ValSizeInBytes)-1)))
return false;
}
OpenPOWER on IntegriCloud