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

Dan Gohman gohman at apple.com
Wed Jan 13 15:45:44 PST 2010


On Jan 13, 2010, at 3:28 PM, Chris Lattner wrote:

> Author: lattner
> Date: Wed Jan 13 17:28:40 2010
> New Revision: 93372
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=93372&view=rev
> Log:
> X86 if conversion + tail merging issues from PR6032.
> 
> Modified:
>    llvm/trunk/lib/Target/X86/README.txt
> 
> Modified: llvm/trunk/lib/Target/X86/README.txt
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/README.txt?rev=93372&r1=93371&r2=93372&view=diff
> 
> ==============================================================================
> --- llvm/trunk/lib/Target/X86/README.txt (original)
> +++ llvm/trunk/lib/Target/X86/README.txt Wed Jan 13 17:28:40 2010
> @@ -1868,3 +1868,23 @@
> information to add the "lock" prefix.
> 
> //===---------------------------------------------------------------------===//
> +
> +The X86 backend should be able to if-convert SSE comparisons like "ucomisd" to
> +"cmpsd".  For example, this code:
> +
> +double d1(double x) { return x == x ? x : x + x; }
> +
> +Compiles into:
> +
> +_d1:
> +	ucomisd	%xmm0, %xmm0
> +	jnp	LBB1_2
> +	addsd	%xmm0, %xmm0

Is cmpsd actually faster? With the cmpsd approach, the
addsd must be executed unconditionally.

Dan





More information about the llvm-commits mailing list