From bb38d79ad6718ca71fdc0808048d525b041515b9 Mon Sep 17 00:00:00 2001 From: Reid Spencer Date: Fri, 2 Mar 2007 23:01:14 +0000 Subject: Make sorting of ConstantInt be APInt clean through use of ult function. llvm-svn: 34853 --- llvm/lib/Transforms/Utils/SimplifyCFG.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'llvm/lib/Transforms/Utils') diff --git a/llvm/lib/Transforms/Utils/SimplifyCFG.cpp b/llvm/lib/Transforms/Utils/SimplifyCFG.cpp index 92b0a9d5cda..91664bf2d9d 100644 --- a/llvm/lib/Transforms/Utils/SimplifyCFG.cpp +++ b/llvm/lib/Transforms/Utils/SimplifyCFG.cpp @@ -1167,7 +1167,7 @@ namespace { /// applications that sort ConstantInt's to ensure uniqueness. struct ConstantIntOrdering { bool operator()(const ConstantInt *LHS, const ConstantInt *RHS) const { - return LHS->getZExtValue() < RHS->getZExtValue(); + return LHS->getValue().ult(RHS->getValue()); } }; } -- cgit v1.2.3