From: Chris Lattner Date: Fri, 2 Mar 2007 05:04:52 +0000 (+0000) Subject: add a note X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=9b6f57c303c2aa2e2509fd663216e4e53edd9dc4;p=oota-llvm.git add a note git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34837 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/X86/README.txt b/lib/Target/X86/README.txt index 554c49beba1..1c067f53717 100644 --- a/lib/Target/X86/README.txt +++ b/lib/Target/X86/README.txt @@ -920,3 +920,25 @@ LBB1_1: Though this probably isn't worth it. //===---------------------------------------------------------------------===// + +We need to teach the codegen to convert two-address INC instructions to LEA +when the flags are dead. For example, on X86-64, compile: + +int foo(int A, int B) { + return A+1; +} + +to: + +_foo: + leal 1(%edi), %eax + ret + +instead of: + +_foo: + incl %edi + movl %edi, %eax + ret + +//===---------------------------------------------------------------------===//