diff options
author | Benjamin Kramer <benny.kra@googlemail.com> | 2012-06-23 15:19:31 +0000 |
---|---|---|
committer | Benjamin Kramer <benny.kra@googlemail.com> | 2012-06-23 15:19:31 +0000 |
commit | d52998a8155e2c45d131e2dbfb97c3fdcbb57435 (patch) | |
tree | 402cf128d76844f703209e9907d4810049193ea5 /lib | |
parent | 50b4c52633b0c933aabcd0741d1dae751ba339dd (diff) |
Add a microoptimization note.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159082 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Target/README.txt | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/Target/README.txt b/lib/Target/README.txt index 093255e6af..cbfa4cf35b 100644 --- a/lib/Target/README.txt +++ b/lib/Target/README.txt @@ -964,6 +964,12 @@ optimized with "clang -emit-llvm-bc | opt -std-compile-opts". //===---------------------------------------------------------------------===// +unsigned f(unsigned x) { return ((x & 7) + 1) & 15; } +The & 15 part should be optimized away, it doesn't change the result. 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 |