diff options
author | Eli Friedman <eli.friedman@gmail.com> | 2011-04-10 04:44:11 +0000 |
---|---|---|
committer | Eli Friedman <eli.friedman@gmail.com> | 2011-04-10 04:44:11 +0000 |
commit | 52d6874271829c4f5bb70121fb678c27780ce65a (patch) | |
tree | b5fb249613ded28d5a65ba8c8f416a3ad221db37 /lib/CodeGen/CGExprScalar.cpp | |
parent | 8d051e00ad674754d476cc1fa0442da0bc47b2c8 (diff) |
PR9580: Handle vectors correctly in ScalarExprEmitter::EmitRem.
While I'm here, FileCheck-ize the ext-vector test, so we actually check
what it is generating.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@129241 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGExprScalar.cpp')
-rw-r--r-- | lib/CodeGen/CGExprScalar.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/CodeGen/CGExprScalar.cpp b/lib/CodeGen/CGExprScalar.cpp index a3c765e352..65aa46fff0 100644 --- a/lib/CodeGen/CGExprScalar.cpp +++ b/lib/CodeGen/CGExprScalar.cpp @@ -1734,7 +1734,7 @@ Value *ScalarExprEmitter::EmitRem(const BinOpInfo &Ops) { EmitUndefinedBehaviorIntegerDivAndRemCheck(Ops, Zero, false); } - if (Ops.Ty->isUnsignedIntegerType()) + if (Ops.Ty->hasUnsignedIntegerRepresentation()) return Builder.CreateURem(Ops.LHS, Ops.RHS, "rem"); else return Builder.CreateSRem(Ops.LHS, Ops.RHS, "rem"); |