From 52d6874271829c4f5bb70121fb678c27780ce65a Mon Sep 17 00:00:00 2001 From: Eli Friedman Date: Sun, 10 Apr 2011 04:44:11 +0000 Subject: 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 --- lib/CodeGen/CGExprScalar.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/CodeGen/CGExprScalar.cpp') 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"); -- cgit v1.2.3