From: Benjamin Kramer Date: Wed, 28 Mar 2012 10:50:18 +0000 (+0000) Subject: Add another note about a missed compare with nsw arithmetic instcombine. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=9b58464330f45dcf6fe621a40f4bc8617169586e;p=oota-llvm.git Add another note about a missed compare with nsw arithmetic instcombine. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@153574 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/README.txt b/lib/Target/README.txt index 8929ac4f2a6..3c21ddae80c 100644 --- a/lib/Target/README.txt +++ b/lib/Target/README.txt @@ -973,6 +973,13 @@ optimized with "clang -emit-llvm-bc | opt -std-compile-opts". //===---------------------------------------------------------------------===// +int f(int i, int j) { return i < j + 1; } +int g(int i, int j) { return j > i - 1; } +Should combine to "i <= j" (the add/sub has nsw). Currently not +optimized with "clang -emit-llvm-bc | opt -std-compile-opts". + +//===---------------------------------------------------------------------===// + This was noticed in the entryblock for grokdeclarator in 403.gcc: %tmp = icmp eq i32 %decl_context, 4