[llvm-commits] [llvm] r57586 - /llvm/trunk/lib/Target/README.txt

Chris Lattner sabre at nondot.org
Wed Oct 15 09:33:52 PDT 2008


Author: lattner
Date: Wed Oct 15 11:33:52 2008
New Revision: 57586

URL: http://llvm.org/viewvc/llvm-project?rev=57586&view=rev
Log:
move PR1941 here.

Modified:
    llvm/trunk/lib/Target/README.txt

Modified: llvm/trunk/lib/Target/README.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/README.txt?rev=57586&r1=57585&r2=57586&view=diff

==============================================================================
--- llvm/trunk/lib/Target/README.txt (original)
+++ llvm/trunk/lib/Target/README.txt Wed Oct 15 11:33:52 2008
@@ -971,3 +971,17 @@
 
 //===---------------------------------------------------------------------===//
 
+Instcombine will merge comparisons like (x >= 10) && (x < 20) by producing (x -
+10) u< 10, but only when the comparisons have matching sign.
+
+This could be converted with a similiar technique. (PR1941)
+
+define i1 @test(i8 %x) {
+  %A = icmp uge i8 %x, 5
+  %B = icmp slt i8 %x, 20
+  %C = and i1 %A, %B
+  ret i1 %C
+}
+
+//===---------------------------------------------------------------------===//
+





More information about the llvm-commits mailing list