summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorNick Lewycky <nicholas@mxc.ca>2011-03-09 06:26:03 +0000
committerNick Lewycky <nicholas@mxc.ca>2011-03-09 06:26:03 +0000
commit84dd4fa2e36f72050f5c46577359f5df0467e3e4 (patch)
tree008880181f1e1077129fe7c5387df067b92df919 /test
parentb2fd770136b92637c5f084b743eab29f910288d5 (diff)
downloadllvm-84dd4fa2e36f72050f5c46577359f5df0467e3e4.tar.gz
llvm-84dd4fa2e36f72050f5c46577359f5df0467e3e4.tar.bz2
llvm-84dd4fa2e36f72050f5c46577359f5df0467e3e4.tar.xz
Add another micro-optimization. Apologies for the lack of refactoring, but I
gave up when I realized I couldn't come up with a good name for what the refactored function would be, to describe what it does. This is PR9343 test12, which is test3 with arguments reordered. Whoops! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@127318 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/Transforms/InstSimplify/compare.ll8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/Transforms/InstSimplify/compare.ll b/test/Transforms/InstSimplify/compare.ll
index 7174e7fc61..00a14cc5cc 100644
--- a/test/Transforms/InstSimplify/compare.ll
+++ b/test/Transforms/InstSimplify/compare.ll
@@ -245,6 +245,14 @@ define i1 @urem5(i16 %X, i32 %Y) {
; CHECK: ret i1 true
}
+define i1 @urem6(i32 %X, i32 %Y) {
+; CHECK: @urem6
+ %A = urem i32 %X, %Y
+ %B = icmp ugt i32 %Y, %A
+ ret i1 %B
+; CHECK: ret i1 true
+}
+
define i1 @srem1(i32 %X) {
; CHECK: @srem1
%A = srem i32 %X, -5