[llvm-commits] CVS: llvm/lib/Target/X86/README.txt

Chris Lattner sabre at nondot.org
Wed Sep 20 23:15:08 PDT 2006



Changes in directory llvm/lib/Target/X86:

README.txt updated: 1.138 -> 1.139
---
Log message:

implemented


---
Diffs of the changes:  (+0 -35)

 README.txt |   35 -----------------------------------
 1 files changed, 35 deletions(-)


Index: llvm/lib/Target/X86/README.txt
diff -u llvm/lib/Target/X86/README.txt:1.138 llvm/lib/Target/X86/README.txt:1.139
--- llvm/lib/Target/X86/README.txt:1.138	Thu Sep 21 00:46:00 2006
+++ llvm/lib/Target/X86/README.txt	Thu Sep 21 01:14:54 2006
@@ -642,41 +642,6 @@
 
 //===---------------------------------------------------------------------===//
 
-Compile:
-int %test(ulong *%tmp) {
-        %tmp = load ulong* %tmp         ; <ulong> [#uses=1]
-        %tmp.mask = shr ulong %tmp, ubyte 50            ; <ulong> [#uses=1]
-        %tmp.mask = cast ulong %tmp.mask to ubyte           
-        %tmp2 = and ubyte %tmp.mask, 3          ; <ubyte> [#uses=1]
-        %tmp2 = cast ubyte %tmp2 to int         ; <int> [#uses=1]
-        ret int %tmp2
-}
-
-to:
-
-_test:
-        movl 4(%esp), %eax
-        movl 4(%eax), %eax
-        shrl $18, %eax
-        andl $3, %eax
-        ret
-
-instead of:
-
-_test:
-        movl 4(%esp), %eax
-        movl 4(%eax), %eax
-        shrl $18, %eax
-        # TRUNCATE movb %al, %al
-        andb $3, %al
-        movzbl %al, %eax
-        ret
-
-This saves a movzbl, and saves a truncate if it doesn't get coallesced right.
-This is a simple DAGCombine to propagate the zext through the and.
-
-//===---------------------------------------------------------------------===//
-
 GCC's ix86_expand_int_movcc function (in i386.c) has a ton of interesting
 simplifications for integer "x cmp y ? a : b".  For example, instead of:
 






More information about the llvm-commits mailing list